Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #15972
| From | Mikael Nordman <oh2aun@invalid.com> |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: GA144 polyForth |
| Date | 2012-10-06 16:08 +0300 |
| Organization | A noiseless patient Spider |
| Message-ID | <k4pafs$igl$1@dont-email.me> (permalink) |
| References | <k4oq5o$vbr$1@dont-email.me> <70899297938435@frunobulax.edu> |
On 6.10.2012 12:14, Marcel Hendrix wrote:
>> Out of curiosity I ran the same speed test with FlashForth on PIC18,
>> PIC24 and AVR Atmega.
>
>> 181 ms on PIC24 @ 54 MHz
>> 750 ms on PIC18 @ 48 MHz
>> 4154 ms on Atmega 328 @ 8 Mhz
>
> That's remarkably good. On a 2.667 GHz i7 desktop machine, iForth (64bit)
> takes 2.22 ms. Adjusting for clockspeed, 2.22 ms * 2667 / 54 = 110 ms, as
> compared to PIC24's 181 ms.
>
> The speed difference between PIC24 and PIC18 is much higher than the
> expected factor of 2. I guess FlashForth for PIC24 is radically different
> and uses more of the available registers?
>
> -marcel
>
>
The 16-bit PIC24 has much better adressing modes than the
8-bit processors. This is partly due to that the PIC24
has a 24-bit instruction word so it can fit more data
in one instruction.
Normalized for 8 MHz Fosc the comparative figures are
PIC24: 1221 ms
PIC18: 4500 ms
Amega: 4154 ms
Normalized for 8 MIPS peak instruction rate:
PIC24: 610 ms (16 Mhz Fosc)
PIC18: 1125 ms (32 MHz Fosc)
Amega: 4154 ms (8 Mhz Fosc)
The decrement of TOR in NEXT is just one instruction.
PIC24: dec [--W15], [W15++] ; XNEXT
bra c, back
Here it is 3 instructions.
PIC18: decf TOSL, F, A ; XNEXT
movlw 0
subwfb TOSH, F, A
bc back
And for the Atmega its 12 instruction cycles.
It would be only 5 cycles if the
NEXT code is inlined. But I decided
to save space instead of making it fast.
Atmega: call XNEXT
brcc back
; (next) decrement top of return stack
XNEXT:
pop zh
pop zl
pop xh
pop xl
sbiw xl, 1
push xl
push xh
ijmp
Mike
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-09-27 14:16 -0700
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-09-29 01:20 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-09-30 11:05 -0400
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-09-30 09:06 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-09-30 14:29 -0400
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-09-30 19:56 -0700
Re: GA144 polyForth Coos Haak <chforth@hccnet.nl> - 2012-09-30 21:54 +0200
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-01 11:18 -0700
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-10-01 23:40 -0700
Re: GA144 polyForth "Elizabeth D. Rather" <erather@forth.com> - 2012-10-01 21:23 -1000
Re: GA144 polyForth albert@spenarnc.xs4all.nl (Albert van der Horst) - 2012-10-05 19:19 +0000
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-04 23:04 -0700
Re: GA144 polyForth Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-10-01 10:28 -0500
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-01 11:19 -0700
Re: GA144 polyForth Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-10-03 10:46 -0500
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-04 13:46 -0700
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-05 22:10 -0700
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-10-05 23:17 -0700
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-06 05:47 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-07 19:31 -0400
Re: GA144 polyForth Bernd Paysan <bernd.paysan@gmx.de> - 2012-10-08 20:10 +0200
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-08 16:36 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-08 13:31 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-09 13:48 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-09 13:21 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-09 17:08 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-13 07:39 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-13 14:28 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-13 13:37 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-13 16:54 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-13 14:14 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-13 17:30 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-14 02:00 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-14 19:54 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-15 11:03 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-15 16:38 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-16 04:12 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-16 15:46 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-16 23:05 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-17 13:40 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-17 22:54 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-18 14:53 -0400
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-18 15:06 -0400
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-18 15:09 -0400
Re: GA144 polyForth Howerd <howerdo@yahoo.co.uk> - 2012-10-19 10:43 -0700
Re: GA144 polyForth rickman <gnuarm@gmail.com> - 2012-10-19 17:43 -0400
Re: GA144 polyForth Mikael Nordman <oh2aun@invalid.com> - 2012-10-06 11:29 +0300
Re: GA144 polyForth mhx@iae.nl (Marcel Hendrix) - 2012-10-06 11:14 +0200
Re: GA144 polyForth Mikael Nordman <oh2aun@invalid.com> - 2012-10-06 16:08 +0300
Re: GA144 polyForth Paul Rubin <no.email@nospam.invalid> - 2012-10-07 10:57 -0700
csiph-web