Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #48655 > unrolled thread

Mandelbrot Set

Started byhughaguilar96@gmail.com
First post2016-07-01 11:52 -0700
Last post2016-07-21 09:04 -0700
Articles 20 on this page of 44 — 15 participants

Back to article view | Back to comp.lang.forth


Contents

  Mandelbrot Set hughaguilar96@gmail.com - 2016-07-01 11:52 -0700
    Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-01 12:35 -0700
      Re: Mandelbrot Set Pablo Hugo Reda <pabloreda@gmail.com> - 2016-07-01 12:40 -0700
        Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-01 12:57 -0700
          Re: Mandelbrot Set Pablo Hugo Reda <pabloreda@gmail.com> - 2016-07-01 13:22 -0700
        Re: Mandelbrot Set josv@planet.nl - 2016-07-01 23:58 -0700
      Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-03 10:17 -0700
        bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-04 17:51 -0700
          Re: bug in VFX disassembler? Cecil Bayona <cbayona@cbayona.com> - 2016-07-04 23:25 -0500
            Re: bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-04 22:48 -0700
              Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-05 02:02 -0400
                Re: bug in VFX disassembler? lawrencedo99@gmail.com - 2016-07-06 00:46 -0700
                  Re: bug in VFX disassembler? Ron Aaron <rambamist@gmail.com> - 2016-07-06 10:48 +0300
                    Re: bug in VFX disassembler? lawrencedo99@gmail.com - 2016-07-06 19:56 -0700
                  Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-06 11:33 -0400
                    Re: bug in VFX disassembler? lawrencedo99@gmail.com - 2016-07-06 19:57 -0700
                      Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-07 00:45 -0400
                        Re: bug in VFX disassembler? lawrencedo99@gmail.com - 2016-07-06 23:42 -0700
                          Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-07 03:14 -0400
                    Re: bug in VFX disassembler? Cecil Bayona <cbayona@cbayona.com> - 2016-07-06 22:32 -0500
                      Re: bug in VFX disassembler? lawrencedo99@gmail.com - 2016-07-06 21:08 -0700
                        Re: bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-07 00:22 -0700
                          Re: bug in VFX disassembler? Cecil Bayona <cbayona@cbayona.com> - 2016-07-07 02:34 -0500
                            Re: bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-07 00:40 -0700
                            Re: bug in VFX disassembler? Julian Fondren <julian.fondren@gmail.com> - 2016-07-07 01:23 -0700
                          Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-07 03:39 -0400
                            Re: bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-07 00:50 -0700
                              Re: bug in VFX disassembler? rickman <gnuarm@gmail.com> - 2016-07-07 10:27 -0400
            Re: bug in VFX disassembler? "HAA" <someone@microsoft.com> - 2016-07-07 14:38 +1000
          Re: bug in VFX disassembler? "HAA" <someone@microsoft.com> - 2016-07-07 17:01 +1000
            Re: bug in VFX disassembler? hughaguilar96@gmail.com - 2016-07-07 00:04 -0700
              Re: bug in VFX disassembler? "HAA" <someone@microsoft.com> - 2016-07-07 17:39 +1000
    Re: Mandelbrot Set "WJ" <w_a_x_man@yahoo.com> - 2016-07-02 06:07 +0000
      Re: Mandelbrot Set mhx@iae.nl - 2016-07-02 00:12 -0700
      Re: Mandelbrot Set Paul Rubin <no.email@nospam.invalid> - 2016-07-02 00:58 -0700
    Re: Mandelbrot Set humptydumpty <ouatubi@gmail.com> - 2016-07-20 03:46 -0700
      Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-20 07:22 -0700
        Re: Mandelbrot Set Coos Haak <chforth@hccnet.nl> - 2016-07-20 17:02 +0200
          Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-20 08:20 -0700
            Re: Mandelbrot Set humptydumpty <ouatubi@gmail.com> - 2016-07-20 08:58 -0700
              Re: Mandelbrot Set humptydumpty <ouatubi@gmail.com> - 2016-07-20 09:02 -0700
              Re: Mandelbrot Set hughaguilar96@gmail.com - 2016-07-20 09:35 -0700
              Re: Mandelbrot Set anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-07-21 13:18 +0000
                Re: Mandelbrot Set humptydumpty <ouatubi@gmail.com> - 2016-07-21 09:04 -0700

Page 1 of 3  [1] 2 3  Next page →


#48655 — Mandelbrot Set

Fromhughaguilar96@gmail.com
Date2016-07-01 11:52 -0700
SubjectMandelbrot Set
Message-ID<4fcaecbc-53bc-4c5b-8d12-f24b0755a557@googlegroups.com>
Over on comp.lang.lisp we had this thread:
https://groups.google.com/forum/#!topic/comp.lang.lisp/8XigMh1ujjM

Those guys want to use the Mandelbrot Set program as a bench-mark. This is a very bad idea because the Mandelbrot Set involves chaos --- it doesn't take long before that sequence of numbers becomes chaotic --- every program ends up with a different number of iterations because of tiny differences in the fuzziness of the least-significant digits that pretty soon end up fuzzing out the most-significant digits.

Anyway, I was asked to write a Mandelbrot Set program in Forth for comparison, so I did:



\ Mandelbrot Set --- ANS-Forth --- written by Hugh Aguilar
\ from Paul Rubin's C code in this thread: 
\ https://groups.google.com/forum/#!topic/comp.lang.lisp/8XigMh1ujjM

\ ANS-Forth fails to support locals, so I had to use global variables.
\ ANS-Forth also fails to provide F>R FR@ FR> which could have also helped.

marker Mandelbrot.4th

: f+! ( adr -- )                            \ float: n --
    dup f@ f+  f! ;
    
: csqr ( -- )                               \ float: a ai -- product producti
    fover fdup f*  fover fdup f*  f-        \ float: -- a ai a*a-ai*ai
    frot frot                               \ float: -- a*a-ai*ai a ai
    f*  fdup f+ ;                           \ float: -- a*a-ai*ai a*ai+a*ai
    
: cabs ( -- )                               \ float: a ai -- distance
    fdup f*  fswap 
    fdup f*  f+
    fsqrt ;
    
: s>f ( n -- )                              \ float: -- n
    s>d  d>f ;
    
fvariable cc
fvariable cci
: <mandelbrot-iteration> ( -- count )       \ float: c cci -- z zi
    fover cc f!  fdup cci f!                \ float: -- z zi    \ Z starts as C not as origin
    1 begin
        csqr 
        fswap cc f@ f+  fswap cci f@ f+
        1+
        dup 1000 >= if                      exit then
        fover fover cabs  100.0e f> if      exit then
        again ;
        
: mandelbrot-iteration ( -- count )
    <mandelbrot-iteration>
    fdrop fdrop ;                           \ discard z zi
    
fvariable dx    
fvariable dy
fvariable x
fvariable y
fvariable x1
fvariable y1
variable nx
variable ny 
variable sum   
: mandelbrot-box ( nx ny -- sum )           \ float: x1 x2 y1 y2 -- 
    ny !  nx !  0 sum !
    fover f-  ny @ s>f f/  dy f!            \ float: -- x1 x2 y1 
    y1 f!                                   \ float: -- x1 x2
    fover f-  nx @ s>f f/  dx f!            \ float: -- x1
    x1 f!                                   \ float: --
    x1 f@ x f!  0 begin  y1 f@ y f!  0 begin
        x f@ y f@  mandelbrot-iteration sum +!
        dup ny @ < while  1+  dy f@ y f+!  repeat drop 
        dup nx @ < while  1+  dx f@ x f+!  repeat drop
    sum @ ;
    
: test ( -- )    
    256 256  0.0e 1.0e 0.0e 1.0e  mandelbrot-box
    \ 2 2  -2.0e 1.0e -1.0e 1.0e  mandelbrot-box
    cr ." sum = "  u. ;

\ The TIME-TEST function is VFX only --- comment this out if you are using any other ANS-Forth compiler.
: time-test ( -- )  ticks  test  ticks swap -  cr ." milliseconds: " . ;

[toc] | [next] | [standalone]


#48658

Fromhughaguilar96@gmail.com
Date2016-07-01 12:35 -0700
Message-ID<da5b4d91-4dd9-4bd8-844b-0d04a1ece8da@googlegroups.com>
In reply to#48655
On Friday, July 1, 2016 at 11:52:05 AM UTC-7, hughag...@gmail.com wrote:
> Over on comp.lang.lisp we had this thread:
> https://groups.google.com/forum/#!topic/comp.lang.lisp/8XigMh1ujjM
> 
> Those guys want to use the Mandelbrot Set program as a bench-mark. 

Here is a slightly more efficient version:


: f+! ( adr -- )                            \ float: n --
    dup f@ f+  f! ;
    
: csqr ( -- )                               \ float: a ai -- product producti
    fover fdup f*  fover fdup f*  f-        \ float: -- a ai a*a-ai*ai
    frot frot                               \ float: -- a*a-ai*ai a ai
    f*  fdup f+ ;                           \ float: -- a*a-ai*ai a*ai+a*ai
    
: cabs ( -- )                               \ float: a ai -- distance
    fdup f*  fswap 
    fdup f*  f+
    fsqrt ;
    
: s>f ( n -- )                              \ float: -- n
    s>d  d>f ;
    
fvariable cc
fvariable cci
: <mandelbrot-iteration> ( -- count )       \ float: c cci -- z zi
    fover cc f!  fdup cci f!                \ float: -- z zi    \ Z starts as C not as origin
    1 begin
        csqr 
        fswap cc f@ f+  fswap cci f@ f+
        1+
        dup 1000 >= if                                      exit then
\       fover fover cabs  100.0e f> if                      exit then
        fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   \ replaces last line
        again ;
        
: mandelbrot-iteration ( -- count )
    <mandelbrot-iteration>
    fdrop fdrop ;                           \ discard z zi
    
fvariable dx    
fvariable dy
fvariable x
fvariable y
fvariable x1
fvariable y1
variable nx
variable ny 
variable sum   
: mandelbrot-box ( nx ny -- sum )           \ float: x1 x2 y1 y2 -- 
    ny !  nx !  0 sum !
    fover f-  ny @ s>f f/  dy f!            \ float: -- x1 x2 y1 
    y1 f!                                   \ float: -- x1 x2
    fover f-  nx @ s>f f/  dx f!            \ float: -- x1
    x1 f!                                   \ float: --
    x1 f@ x f!  0 begin  y1 f@ y f!  0 begin
        x f@ y f@  mandelbrot-iteration sum +!
        dup ny @ < while  1+  dy f@ y f+!  repeat drop 
        dup nx @ < while  1+  dx f@ x f+!  repeat drop
    sum @ ;
    
: test ( -- )    
    256 256  0.0e 1.0e 0.0e 1.0e  mandelbrot-box
    \ 2 2  -2.0e 1.0e -1.0e 1.0e  mandelbrot-box
    cr ." sum = "  u. ;

\ The TIME-TEST function is VFX only --- comment this out if you are using any other ANS-Forth compiler.
: time-test ( -- )  ticks  test  ticks swap -  cr ." milliseconds: " . ;

[toc] | [prev] | [next] | [standalone]


#48659

FromPablo Hugo Reda <pabloreda@gmail.com>
Date2016-07-01 12:40 -0700
Message-ID<f5fc11d1-f2bb-4283-b52c-1eafcd4e20c7@googlegroups.com>
In reply to#48658
El viernes, 1 de julio de 2016, 16:35:24 (UTC-3), hughag...@gmail.com  escribió:
> On Friday, July 1, 2016 at 11:52:05 AM UTC-7, hughag...@gmail.com wrote:
> > Over on comp.lang.lisp we had this thread:
> > https://groups.google.com/forum/#!topic/comp.lang.lisp/8XigMh1ujjM
> > 
> > Those guys want to use the Mandelbrot Set program as a bench-mark. 
> 
> Here is a slightly more efficient version:
> 
> 
> : f+! ( adr -- )                            \ float: n --
>     dup f@ f+  f! ;
>     
> : csqr ( -- )                               \ float: a ai -- product producti
>     fover fdup f*  fover fdup f*  f-        \ float: -- a ai a*a-ai*ai
>     frot frot                               \ float: -- a*a-ai*ai a ai
>     f*  fdup f+ ;                           \ float: -- a*a-ai*ai a*ai+a*ai
>     
> : cabs ( -- )                               \ float: a ai -- distance
>     fdup f*  fswap 
>     fdup f*  f+
>     fsqrt ;
>     
> : s>f ( n -- )                              \ float: -- n
>     s>d  d>f ;
>     
> fvariable cc
> fvariable cci
> : <mandelbrot-iteration> ( -- count )       \ float: c cci -- z zi
>     fover cc f!  fdup cci f!                \ float: -- z zi    \ Z starts as C not as origin
>     1 begin
>         csqr 
>         fswap cc f@ f+  fswap cci f@ f+
>         1+
>         dup 1000 >= if                                      exit then
> \       fover fover cabs  100.0e f> if                      exit then
>         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   \ replaces last line
>         again ;
>         
> : mandelbrot-iteration ( -- count )
>     <mandelbrot-iteration>
>     fdrop fdrop ;                           \ discard z zi
>     
> fvariable dx    
> fvariable dy
> fvariable x
> fvariable y
> fvariable x1
> fvariable y1
> variable nx
> variable ny 
> variable sum   
> : mandelbrot-box ( nx ny -- sum )           \ float: x1 x2 y1 y2 -- 
>     ny !  nx !  0 sum !
>     fover f-  ny @ s>f f/  dy f!            \ float: -- x1 x2 y1 
>     y1 f!                                   \ float: -- x1 x2
>     fover f-  nx @ s>f f/  dx f!            \ float: -- x1
>     x1 f!                                   \ float: --
>     x1 f@ x f!  0 begin  y1 f@ y f!  0 begin
>         x f@ y f@  mandelbrot-iteration sum +!
>         dup ny @ < while  1+  dy f@ y f+!  repeat drop 
>         dup nx @ < while  1+  dx f@ x f+!  repeat drop
>     sum @ ;
>     
> : test ( -- )    
>     256 256  0.0e 1.0e 0.0e 1.0e  mandelbrot-box
>     \ 2 2  -2.0e 1.0e -1.0e 1.0e  mandelbrot-box
>     cr ." sum = "  u. ;
> 
> \ The TIME-TEST function is VFX only --- comment this out if you are using any other ANS-Forth compiler.
> : time-test ( -- )  ticks  test  ticks swap -  cr ." milliseconds: " . ;

Here is a fixed point version in :r4

---------------------------------------------------
#xmax #ymax #xmin #ymin

:calc | p q cx cy -- p q cx cy xn yn r
	over dup *. over dup *. - pick4 + | xn
	pick2 pick2 *. 2* pick4 +	| xn yn
	over dup *. over dup *. +	| xn yn r
	;

:mandel | x y -- x y v
	over xmax xmin - sw */ xmin +	| x y p
	over ymax ymin - sh */ ymin +	| x y p q
	0 0 0 | cx cy it
	( 255 <? )( >r 	| x y p q cx cy
		calc		| x y p q cx cy xn yn r
		4.0 >? ( 4drop 3drop r> ; )
		drop rot drop rot drop
		r> 1+ )
	nip nip nip nip
	;

:scrman
	0 ( sh <? )(
		0 over setxy
		0 ( sw <? )(
			swap
			mandel dup 8 << or dup 8 << or px!+
			swap
			1+ ) drop
		1+ ) drop
	;

:main
	2.0 'xmax ! 2.0 'ymax !
	-3.0 'xmin ! -2.0 'ymin !
	scrman
	blanco scr home " Mandelbrot" print
	show
		'exit >esc<
		;

: main ;

[toc] | [prev] | [next] | [standalone]


#48662

Fromhughaguilar96@gmail.com
Date2016-07-01 12:57 -0700
Message-ID<f613ee88-f688-4b6a-9b36-5445fde67e9d@googlegroups.com>
In reply to#48659
On Friday, July 1, 2016 at 12:40:50 PM UTC-7, Pablo Hugo Reda wrote:
> Here is a fixed point version in :r4

What is :r4 ? Can I download this somewhere?

[toc] | [prev] | [next] | [standalone]


#48664

FromPablo Hugo Reda <pabloreda@gmail.com>
Date2016-07-01 13:22 -0700
Message-ID<fdd4ef4a-b50d-4f72-82a2-6a9b6baa8e6b@googlegroups.com>
In reply to#48662
El viernes, 1 de julio de 2016, 16:57:15 (UTC-3), hughag...@gmail.com  escribió:
> On Friday, July 1, 2016 at 12:40:50 PM UTC-7, Pablo Hugo Reda wrote:
> > Here is a fixed point version in :r4
> 
> What is :r4 ? Can I download this somewhere?

https://github.com/phreda4/reda4

[toc] | [prev] | [next] | [standalone]


#48683

Fromjosv@planet.nl
Date2016-07-01 23:58 -0700
Message-ID<9d97a17f-9a2b-4d01-84fa-83a1937739a1@googlegroups.com>
In reply to#48659
Julia442 at:
https://sites.google.com/site/win324th/sources
will use all the hardware threads of a CPU on your PC
to calculate and plot a mandelbrot.

Jos

On july 1, 2016 21:40:50 UTC+2 Pablo Hugo Reda wrote:
> El viernes, 1 de julio de 2016, 16:35:24 (UTC-3), hughag...@gmail.com  escribió:
> > On Friday, July 1, 2016 at 11:52:05 AM UTC-7, hughag...@gmail.com wrote:
> > > Over on comp.lang.lisp we had this thread:
> > > https://groups.google.com/forum/#!topic/comp.lang.lisp/8XigMh1ujjM
> > > 
> > > Those guys want to use the Mandelbrot Set program as a bench-mark. 
> > 
> > Here is a slightly more efficient version:
> > 
> > 
> > : f+! ( adr -- )                            \ float: n --
> >     dup f@ f+  f! ;
> >     
> > : csqr ( -- )                               \ float: a ai -- product producti
> >     fover fdup f*  fover fdup f*  f-        \ float: -- a ai a*a-ai*ai
> >     frot frot                               \ float: -- a*a-ai*ai a ai
> >     f*  fdup f+ ;                           \ float: -- a*a-ai*ai a*ai+a*ai
> >     
> > : cabs ( -- )                               \ float: a ai -- distance
> >     fdup f*  fswap 
> >     fdup f*  f+
> >     fsqrt ;
> >     
> > : s>f ( n -- )                              \ float: -- n
> >     s>d  d>f ;
> >     
> > fvariable cc
> > fvariable cci
> > : <mandelbrot-iteration> ( -- count )       \ float: c cci -- z zi
> >     fover cc f!  fdup cci f!                \ float: -- z zi    \ Z starts as C not as origin
> >     1 begin
> >         csqr 
> >         fswap cc f@ f+  fswap cci f@ f+
> >         1+
> >         dup 1000 >= if                                      exit then
> > \       fover fover cabs  100.0e f> if                      exit then
> >         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   \ replaces last line
> >         again ;
> >         
> > : mandelbrot-iteration ( -- count )
> >     <mandelbrot-iteration>
> >     fdrop fdrop ;                           \ discard z zi
> >     
> > fvariable dx    
> > fvariable dy
> > fvariable x
> > fvariable y
> > fvariable x1
> > fvariable y1
> > variable nx
> > variable ny 
> > variable sum   
> > : mandelbrot-box ( nx ny -- sum )           \ float: x1 x2 y1 y2 -- 
> >     ny !  nx !  0 sum !
> >     fover f-  ny @ s>f f/  dy f!            \ float: -- x1 x2 y1 
> >     y1 f!                                   \ float: -- x1 x2
> >     fover f-  nx @ s>f f/  dx f!            \ float: -- x1
> >     x1 f!                                   \ float: --
> >     x1 f@ x f!  0 begin  y1 f@ y f!  0 begin
> >         x f@ y f@  mandelbrot-iteration sum +!
> >         dup ny @ < while  1+  dy f@ y f+!  repeat drop 
> >         dup nx @ < while  1+  dx f@ x f+!  repeat drop
> >     sum @ ;
> >     
> > : test ( -- )    
> >     256 256  0.0e 1.0e 0.0e 1.0e  mandelbrot-box
> >     \ 2 2  -2.0e 1.0e -1.0e 1.0e  mandelbrot-box
> >     cr ." sum = "  u. ;
> > 
> > \ The TIME-TEST function is VFX only --- comment this out if you are using any other ANS-Forth compiler.
> > : time-test ( -- )  ticks  test  ticks swap -  cr ." milliseconds: " . ;
> 
> Here is a fixed point version in :r4
> 
> ---------------------------------------------------
> #xmax #ymax #xmin #ymin
> 
> :calc | p q cx cy -- p q cx cy xn yn r
> 	over dup *. over dup *. - pick4 + | xn
> 	pick2 pick2 *. 2* pick4 +	| xn yn
> 	over dup *. over dup *. +	| xn yn r
> 	;
> 
> :mandel | x y -- x y v
> 	over xmax xmin - sw */ xmin +	| x y p
> 	over ymax ymin - sh */ ymin +	| x y p q
> 	0 0 0 | cx cy it
> 	( 255 <? )( >r 	| x y p q cx cy
> 		calc		| x y p q cx cy xn yn r
> 		4.0 >? ( 4drop 3drop r> ; )
> 		drop rot drop rot drop
> 		r> 1+ )
> 	nip nip nip nip
> 	;
> 
> :scrman
> 	0 ( sh <? )(
> 		0 over setxy
> 		0 ( sw <? )(
> 			swap
> 			mandel dup 8 << or dup 8 << or px!+
> 			swap
> 			1+ ) drop
> 		1+ ) drop
> 	;
> 
> :main
> 	2.0 'xmax ! 2.0 'ymax !
> 	-3.0 'xmin ! -2.0 'ymin !
> 	scrman
> 	blanco scr home " Mandelbrot" print
> 	show
> 		'exit >esc<
> 		;
> 
> : main ;

[toc] | [prev] | [next] | [standalone]


#48760

Fromhughaguilar96@gmail.com
Date2016-07-03 10:17 -0700
Message-ID<08a78469-c70f-4c2f-b2a0-101628a2a77a@googlegroups.com>
In reply to#48658
On Friday, July 1, 2016 at 12:35:24 PM UTC-7, hughag...@gmail.com wrote:
> : csqr ( -- )                               \ float: a ai -- product producti
>     fover fdup f*  fover fdup f*  f-        \ float: -- a ai a*a-ai*ai
>     frot frot                               \ float: -- a*a-ai*ai a ai
>     f*  fdup f+ ;                           \ float: -- a*a-ai*ai a*ai+a*ai
> ...
> fvariable cc
> fvariable cci
> : <mandelbrot-iteration> ( -- count )       \ float: c cci -- z zi
>     fover cc f!  fdup cci f!                \ float: -- z zi    \ Z starts as C not as origin
>     1 begin
>         csqr 
>         fswap cc f@ f+  fswap cci f@ f+
>         1+
>         dup 1000 >= if                                      exit then
> \       fover fover cabs  100.0e f> if                      exit then
>         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   \ replaces last line
>         again ;

I did a disassembly of these two words in VFX. The disassembly of FLIT seems to be incorrect. Why does it say 989.68? The number is supposed to be 10000.

see csqr 
CSQR 
( 004DFBB0    D9C1 )                  FLD       ST(1)
( 004DFBB2    D9C0 )                  FLD       ST
( 004DFBB4    DEC9 )                  FMULP     ST(1), ST
( 004DFBB6    D9C1 )                  FLD       ST(1)
( 004DFBB8    D9C0 )                  FLD       ST
( 004DFBBA    DEC9 )                  FMULP     ST(1), ST
( 004DFBBC    DEE9 )                  FSUBP     ST(1), ST
( 004DFBBE    D9C9 )                  FXCH      ST(1)
( 004DFBC0    D9CA )                  FXCH      ST(2)
( 004DFBC2    D9C9 )                  FXCH      ST(1)
( 004DFBC4    D9CA )                  FXCH      ST(2)
( 004DFBC6    DEC9 )                  FMULP     ST(1), ST
( 004DFBC8    D9C0 )                  FLD       ST
( 004DFBCA    DEC1 )                  FADDP     ST(1), ST
( 004DFBCC    C3 )                    NEXT,
( 29 bytes, 15 instructions )
 ok
see <mandelbrot-iteration> 
<MANDELBROT-ITERATION> 
( 004DFCD0    D9C1 )                  FLD       ST(1)
( 004DFCD2    DB3D200C4600 )          FSTP      TBYTE [00460C20]
( 004DFCD8    D9C0 )                  FLD       ST
( 004DFCDA    DB3D300C4600 )          FSTP      TBYTE [00460C30]
( 004DFCE0    8D6DFC )                LEA       EBP, [EBP+-04]
( 004DFCE3    895D00 )                MOV       [EBP], EBX
( 004DFCE6    BB01000000 )            MOV       EBX, 00000001
( 004DFCEB    90 )                    NOP
( 004DFCEC    90 )                    NOP
( 004DFCED    90 )                    NOP
( 004DFCEE    90 )                    NOP
( 004DFCEF    90 )                    NOP
( 004DFCF0    E8BBFEFFFF )            CALL      004DFBB0        CSQR
( 004DFCF5    D9C9 )                  FXCH      ST(1)
( 004DFCF7    DB2D200C4600 )          FLD       TBYTE [00460C20]
( 004DFCFD    DEC1 )                  FADDP     ST(1), ST
( 004DFCFF    D9C9 )                  FXCH      ST(1)
( 004DFD01    DB2D300C4600 )          FLD       TBYTE [00460C30]
( 004DFD07    DEC1 )                  FADDP     ST(1), ST
( 004DFD09    43 )                    INC       EBX
( 004DFD0A    81FBE8030000 )          CMP       EBX, 000003E8
( 004DFD10    0F8C01000000 )          JL/NGE    004DFD17
( 004DFD16    C3 )                    NEXT,
( 004DFD17    D9C1 )                  FLD       ST(1)
( 004DFD19    D9C0 )                  FLD       ST
( 004DFD1B    DEC9 )                  FMULP     ST(1), ST
( 004DFD1D    D9C1 )                  FLD       ST(1)
( 004DFD1F    D9C0 )                  FLD       ST
( 004DFD21    DEC9 )                  FMULP     ST(1), ST
( 004DFD23    DEC1 )                  FADDP     ST(1), ST
( FPlit: 989.68 )
( 004DFD25    E8D6B5FEFF )            CALL      004CB300        FLIT
( 004DFD34    E877ACFEFF )            CALL      004CA9B0        FCMP2
( 004DFD39    85DB )                  TEST      EBX, EBX
( 004DFD3B    8B5D00 )                MOV       EBX, [EBP]
( 004DFD3E    8D6D04 )                LEA       EBP, [EBP+04]
( 004DFD41    0F8501000000 )          JNZ/NE    004DFD48
( 004DFD47    C3 )                    NEXT,
( 004DFD48    EBA6 )                  JMP       004DFCF0
( 004DFD4A    C3 )                    NEXT,
( 123 bytes, 39 instructions )
 ok
see flit 
FLIT 
( 004CB300    5A )                    POP       EDX
( 004CB301    DB2A )                  FLD       TBYTE 0 [EDX]
( 004CB303    83C20A )                ADD       EDX, 0A
( 004CB306    FFE2 )                  JMP       EDX
...
 ok
see fcmp2 
FCMP2 
( 004CA9B0    83ED04 )                SUB       EBP, 04
( 004CA9B3    895D00 )                MOV       [EBP], EBX
( 004CA9B6    D9C9 )                  FXCH      ST(1)
( 004CA9B8    DED9 )                  FCOMPP
( 004CA9BA    9B )                    FWAIT
( 004CA9BB    DFE0 )                  FSTSW     AX
( 004CA9BD    66250041 )              AND       AX, 4100
( 004CA9C1    0FB7D8 )                MOVZX     EBX, AX
( 004CA9C4    C3 )                    NEXT,
( 21 bytes, 9 instructions )
 ok

[toc] | [prev] | [next] | [standalone]


#48784 — bug in VFX disassembler?

Fromhughaguilar96@gmail.com
Date2016-07-04 17:51 -0700
Subjectbug in VFX disassembler?
Message-ID<84896d24-02f5-4ea7-b4b3-2ff973e88797@googlegroups.com>
In reply to#48760
On Sunday, July 3, 2016 at 10:17:44 AM UTC-7, hughag...@gmail.com wrote:
> On Friday, July 1, 2016 at 12:35:24 PM UTC-7, hughag...@gmail.com wrote:
> >         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   > 
> I did a disassembly of these two words in VFX. The disassembly of FLIT seems to be incorrect. Why does it say 989.68? The number is supposed to be 10000.
> ( FPlit: 989.68 )
> ( 004DFD25    E8D6B5FEFF )            CALL      004CB300        FLIT

Is this a bug in the VFX disassembler?

[toc] | [prev] | [next] | [standalone]


#48793 — Re: bug in VFX disassembler?

FromCecil Bayona <cbayona@cbayona.com>
Date2016-07-04 23:25 -0500
SubjectRe: bug in VFX disassembler?
Message-ID<nlfcru$rja$1@dont-email.me>
In reply to#48784
On 7/4/2016 7:51 PM, hughaguilar96@gmail.com wrote:
> On Sunday, July 3, 2016 at 10:17:44 AM UTC-7, hughag...@gmail.com wrote:
>> On Friday, July 1, 2016 at 12:35:24 PM UTC-7, hughag...@gmail.com wrote:
>>>         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   >
>> I did a disassembly of these two words in VFX. The disassembly of FLIT seems to be incorrect. Why does it say 989.68? The number is supposed to be 10000.
>> ( FPlit: 989.68 )
>> ( 004DFD25    E8D6B5FEFF )            CALL      004CB300        FLIT
>
> Is this a bug in the VFX disassembler?
>
Might be a bug, in the "see" code on VFX 4.71 Standard compiler.

Ran a simple test, added two float numbers, the result was correct. but 
it still shows the funny representation for 10000.0e

: testf 1.0e 10000.0e f+ f. ;  ok
testf 10001.  ok
see testf
TESTF
( 004D13A0    D9E8 )                  FLD1
( FPlit: 989.68 )
( 004D13A2    E839D1FFFF )            CALL      004CE4E0        FLIT
( 004D13B1    DEC1 )                  FADDP     ST(1), ST
( 004D13B3    6A00 )                  PUSH      00
( 004D13B5    8D6DFC )                LEA       EBP, [EBP+-04]
( 004D13B8    895D00 )                MOV       [EBP], EBX
( 004D13BB    BBFFFFFFFF )            MOV       EBX, FFFFFFFF
( 004D13C0    E8DBEDFFFF )            CALL      004D01A0        (F.)
( 004D13C5    5A )                    POP       EDX
( 004D13C6    2BD3 )                  SUB       EDX, EBX
( 004D13C8    8D6DFC )                LEA       EBP, [EBP+-04]
( 004D13CB    895D00 )                MOV       [EBP], EBX
( 004D13CE    8BDA )                  MOV       EBX, EDX
( 004D13D0    E8E7A8F3FF )            CALL      0040BCBC        SPACES
( 004D13D5    FF1545704000 )          CALL      [00407045]      TYPE
( 004D13DB    E898A8F3FF )            CALL      0040BC78        SPACE
( 004D13E0    C3 )                    NEXT,
( 65 bytes, 17 instructions )

Second test with similar wacky results in the disassembly;

: testf 10001.0e 1.0e f- f. ;  ok
   ok
   ok
testf 10000.  ok
see testf
TESTF
( FPlit: 989.A68 )
( 004D13A0    E83BD1FFFF )            CALL      004CE4E0        FLIT
( 004D13AF    D9E8 )                  FLD1
( 004D13B1    DEE9 )                  FSUBP     ST(1), ST
( 004D13B3    6A00 )                  PUSH      00
( 004D13B5    8D6DFC )                LEA       EBP, [EBP+-04]
( 004D13B8    895D00 )                MOV       [EBP], EBX
( 004D13BB    BBFFFFFFFF )            MOV       EBX, FFFFFFFF
( 004D13C0    E8DBEDFFFF )            CALL      004D01A0        (F.)
( 004D13C5    5A )                    POP       EDX
( 004D13C6    2BD3 )                  SUB       EDX, EBX
( 004D13C8    8D6DFC )                LEA       EBP, [EBP+-04]
( 004D13CB    895D00 )                MOV       [EBP], EBX
( 004D13CE    8BDA )                  MOV       EBX, EDX
( 004D13D0    E8E7A8F3FF )            CALL      0040BCBC        SPACES
( 004D13D5    FF1545704000 )          CALL      [00407045]      TYPE
( 004D13DB    E898A8F3FF )            CALL      0040BC78        SPACE
( 004D13E0    C3 )                    NEXT,
( 65 bytes, 17 instructions )
  ok

-- 
Cecil - k5nwa

[toc] | [prev] | [next] | [standalone]


#48795 — Re: bug in VFX disassembler?

Fromhughaguilar96@gmail.com
Date2016-07-04 22:48 -0700
SubjectRe: bug in VFX disassembler?
Message-ID<6a8d2a34-a9cf-4556-b7d0-34f6889369de@googlegroups.com>
In reply to#48793
On Monday, July 4, 2016 at 9:25:36 PM UTC-7, Cecil - k5nwa wrote:
> On 7/4/2016 7:51 PM, hughaguilar96@gmail.com wrote:
> > On Sunday, July 3, 2016 at 10:17:44 AM UTC-7, hughag...@gmail.com wrote:
> >> On Friday, July 1, 2016 at 12:35:24 PM UTC-7, hughag...@gmail.com wrote:
> >>>         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   >
> >> I did a disassembly of these two words in VFX. The disassembly of FLIT seems to be incorrect. Why does it say 989.68? The number is supposed to be 10000.
> >> ( FPlit: 989.68 )
> >> ( 004DFD25    E8D6B5FEFF )            CALL      004CB300        FLIT
> >
> > Is this a bug in the VFX disassembler?
> >
> Might be a bug, in the "see" code on VFX 4.71 Standard compiler.
> 
> Ran a simple test, added two float numbers, the result was correct. but 
> it still shows the funny representation for 10000.0e

This is the second time that I've found a bug in VFX --- the first time Stephen Pelc only grudgingly fixed it and said that doing so was a waste of his time --- I remember that well because I was writing a VFX program for money at the time and the bug was a big stumbling block for me.

He brought out this version 4.71.3523 of VFX (Oct.8,2014) with the bug fixed --- also in the new version was a new license agreement that stated that MPE doesn't allow anybody to use the evaluation version of VFX for commercial software --- that was obviously aimed directly at me, because I was the only one doing that.

[toc] | [prev] | [next] | [standalone]


#48796 — Re: bug in VFX disassembler?

Fromrickman <gnuarm@gmail.com>
Date2016-07-05 02:02 -0400
SubjectRe: bug in VFX disassembler?
Message-ID<nlfiht$b64$1@dont-email.me>
In reply to#48795
On 7/5/2016 1:48 AM, hughaguilar96@gmail.com wrote:
> On Monday, July 4, 2016 at 9:25:36 PM UTC-7, Cecil - k5nwa wrote:
>> On 7/4/2016 7:51 PM, hughaguilar96@gmail.com wrote:
>>> On Sunday, July 3, 2016 at 10:17:44 AM UTC-7, hughag...@gmail.com wrote:
>>>> On Friday, July 1, 2016 at 12:35:24 PM UTC-7, hughag...@gmail.com wrote:
>>>>>         fover fdup f*  fover fdup f*  f+  10000.0e f> if    exit then   >
>>>> I did a disassembly of these two words in VFX. The disassembly of FLIT seems to be incorrect. Why does it say 989.68? The number is supposed to be 10000.
>>>> ( FPlit: 989.68 )
>>>> ( 004DFD25    E8D6B5FEFF )            CALL      004CB300        FLIT
>>>
>>> Is this a bug in the VFX disassembler?
>>>
>> Might be a bug, in the "see" code on VFX 4.71 Standard compiler.
>>
>> Ran a simple test, added two float numbers, the result was correct. but
>> it still shows the funny representation for 10000.0e
>
> This is the second time that I've found a bug in VFX --- the first time Stephen Pelc only grudgingly fixed it and said that doing so was a waste of his time --- I remember that well because I was writing a VFX program for money at the time and the bug was a big stumbling block for me.
>
> He brought out this version 4.71.3523 of VFX (Oct.8,2014) with the bug fixed --- also in the new version was a new license agreement that stated that MPE doesn't allow anybody to use the evaluation version of VFX for commercial software --- that was obviously aimed directly at me, because I was the only one doing that.

That is a very common stipulation of evaluation software.

If you aren't paying someone for their work, do you really expect them 
to let you use their work for your own profit?

Likely you were the first case they knew of who had intent to do this 
and it made them realize this might be a problem they should deal with.

-- 

Rick C

[toc] | [prev] | [next] | [standalone]


#48823 — Re: bug in VFX disassembler?

Fromlawrencedo99@gmail.com
Date2016-07-06 00:46 -0700
SubjectRe: bug in VFX disassembler?
Message-ID<860fc7c0-1e35-4be0-824c-d28fe02a9b6d@googlegroups.com>
In reply to#48796
On Tuesday, July 5, 2016 at 6:02:38 PM UTC+12, rickman wrote:

> If you aren't paying someone for their work, do you really expect them 
> to let you use their work for your own profit?

That’s how all Free Software works.

[toc] | [prev] | [next] | [standalone]


#48824 — Re: bug in VFX disassembler?

FromRon Aaron <rambamist@gmail.com>
Date2016-07-06 10:48 +0300
SubjectRe: bug in VFX disassembler?
Message-ID<nlid4d$9dc$1@dont-email.me>
In reply to#48823

On 06/07/2016 10:46, lawrencedo99@gmail.com wrote:
> On Tuesday, July 5, 2016 at 6:02:38 PM UTC+12, rickman wrote:
> 
>> If you aren't paying someone for their work, do you really expect them 
>> to let you use their work for your own profit?
> 
> That’s how all Free Software works.

First of all, no: VFX isn't "Free Software".  Secondly, see the GPL.

[toc] | [prev] | [next] | [standalone]


#48854 — Re: bug in VFX disassembler?

Fromlawrencedo99@gmail.com
Date2016-07-06 19:56 -0700
SubjectRe: bug in VFX disassembler?
Message-ID<ad34c21e-0d1c-484a-9c34-ca93f2bf012e@googlegroups.com>
In reply to#48824
On Wednesday, July 6, 2016 at 7:48:31 PM UTC+12, Ron Aaron wrote:
>
> On 06/07/2016 10:46, Lawrence D’Oliveiro wrote:
>>
>> On Tuesday, July 5, 2016 at 6:02:38 PM UTC+12, rickman wrote:
>> 
>>> If you aren't paying someone for their work, do you really expect them 
>>> to let you use their work for your own profit?
>> 
>> That’s how all Free Software works.
> 
> First of all, no: VFX isn't "Free Software".

Was the question specific to this piece of non-Free Software, then?

>  Secondly, see the GPL.

Where in the GPL does it say I cannot profit from it?

[toc] | [prev] | [next] | [standalone]


#48837 — Re: bug in VFX disassembler?

Fromrickman <gnuarm@gmail.com>
Date2016-07-06 11:33 -0400
SubjectRe: bug in VFX disassembler?
Message-ID<nlj8c8$6vr$1@dont-email.me>
In reply to#48823
On 7/6/2016 3:46 AM, lawrencedo99@gmail.com wrote:
> On Tuesday, July 5, 2016 at 6:02:38 PM UTC+12, rickman wrote:
>
>> If you aren't paying someone for their work, do you really expect them
>> to let you use their work for your own profit?
>
> That’s how all Free Software works.

That may be how some open source software works, but MPE eval software 
is not "open source".  It is licensed which is how Hugh knows the terms 
changed, he read the license.

-- 

Rick C

[toc] | [prev] | [next] | [standalone]


#48856 — Re: bug in VFX disassembler?

Fromlawrencedo99@gmail.com
Date2016-07-06 19:57 -0700
SubjectRe: bug in VFX disassembler?
Message-ID<0cee6aeb-6ac8-4e05-a77b-14fe2f487e6a@googlegroups.com>
In reply to#48837
On Thursday, July 7, 2016 at 3:33:29 AM UTC+12, rickman wrote:
> That may be how some open source software works ...

That is how ALL Open Source software works <https://opensource.org/osd-annotated>.

[toc] | [prev] | [next] | [standalone]


#48866 — Re: bug in VFX disassembler?

Fromrickman <gnuarm@gmail.com>
Date2016-07-07 00:45 -0400
SubjectRe: bug in VFX disassembler?
Message-ID<nlkmoe$6p7$1@dont-email.me>
In reply to#48856
On 7/6/2016 10:57 PM, lawrencedo99@gmail.com wrote:
> On Thursday, July 7, 2016 at 3:33:29 AM UTC+12, rickman wrote:
>> That may be how some open source software works ...
>
> That is how ALL Open Source software works <https://opensource.org/osd-annotated>.

That is how "Open Source" software works, not open source software.

-- 

Rick C

[toc] | [prev] | [next] | [standalone]


#48871 — Re: bug in VFX disassembler?

Fromlawrencedo99@gmail.com
Date2016-07-06 23:42 -0700
SubjectRe: bug in VFX disassembler?
Message-ID<b058da51-d271-4901-acac-ba62c864ac78@googlegroups.com>
In reply to#48866
On Thursday, July 7, 2016 at 4:45:03 PM UTC+12, rickman wrote:
> On 7/6/2016 10:57 PM, Lawrence D’Oliveiro wrote:
>> On Thursday, July 7, 2016 at 3:33:29 AM UTC+12, rickman wrote:
>>> That may be how some open source software works ...
>>
>> That is how ALL Open Source software works
>> <https://opensource.org/osd-annotated>.
> 
> That is how "Open Source" software works, not open source software.

You can call your proprietary stuff “freeware” or “Shared Source” (Microsoft likes that one), but don’t call it “open source”.

[toc] | [prev] | [next] | [standalone]


#48879 — Re: bug in VFX disassembler?

Fromrickman <gnuarm@gmail.com>
Date2016-07-07 03:14 -0400
SubjectRe: bug in VFX disassembler?
Message-ID<nlkvfr$st3$1@dont-email.me>
In reply to#48871
On 7/7/2016 2:42 AM, lawrencedo99@gmail.com wrote:
> On Thursday, July 7, 2016 at 4:45:03 PM UTC+12, rickman wrote:
>> On 7/6/2016 10:57 PM, Lawrence D’Oliveiro wrote:
>>> On Thursday, July 7, 2016 at 3:33:29 AM UTC+12, rickman wrote:
>>>> That may be how some open source software works ...
>>>
>>> That is how ALL Open Source software works
>>> <https://opensource.org/osd-annotated>.
>>
>> That is how "Open Source" software works, not open source software.
>
> You can call your proprietary stuff “freeware” or “Shared Source” (Microsoft likes that one), but don’t call it “open source”.

No one is doing that.  I believe you brought up open source software. 
No, I see you said, "Free Software" (not sure just what that is since 
you used capitals as if it's a proper noun).  So I suppose we are off on 
a tangent.  Good you brought it back to proprietary software.

-- 

Rick C

[toc] | [prev] | [next] | [standalone]


#48861 — Re: bug in VFX disassembler?

FromCecil Bayona <cbayona@cbayona.com>
Date2016-07-06 22:32 -0500
SubjectRe: bug in VFX disassembler?
Message-ID<nlkih6$tn1$1@dont-email.me>
In reply to#48837
On 7/6/2016 10:33 AM, rickman wrote:
> On 7/6/2016 3:46 AM, lawrencedo99@gmail.com wrote:
>> On Tuesday, July 5, 2016 at 6:02:38 PM UTC+12, rickman wrote:
>>
>>> If you aren't paying someone for their work, do you really expect them
>>> to let you use their work for your own profit?
>>
>> That’s how all Free Software works.
>
> That may be how some open source software works, but MPE eval software
> is not "open source".  It is licensed which is how Hugh knows the terms
> changed, he read the license.
>
I do believe it's referred to as evaluation software, and therefore 
subject to limits and not "open source". Stephen is free to set whatever 
limits he chooses since it's his software, and once he realizes that 
people are trying to use it for commercial endeavors then he might have 
been moved to change the license to make it perfectly clear.

I used his software for a while before I bought a copy, and I recall 
that limit being there, for evaluation and hobby use only, commercial 
applications were not allowed.

-- 
Cecil - k5nwa

[toc] | [prev] | [next] | [standalone]


Page 1 of 3  [1] 2 3  Next page →

Back to top | Article view | comp.lang.forth


csiph-web