#define (from C) in Python
garabik-news-2005-05 at kassiopeia.juls.savba.sk
garabik-news-2005-05 at kassiopeia.juls.savba.sk
Fri Nov 13 08:44:13 EST 2009
Santiago Romero <sromero at gmail.com> wrote:
>
>> > #define STORE_nn_rr(dreg) \
>> > r_opl = Z80ReadMem(r_PC); r_PC++;\
>> > r_oph = Z80ReadMem(r_PC); r_PC++; \
>> > r_tmp = dreg; \
>> > Z80WriteMem((r_op),r_tmpl, regs); \
>> > Z80WriteMem((r_op+1),r_tmph, regs)
>>
>> Someone writing such code and calling it C should be taken
>> behind the barn and shot.
>
> That code is mine and maybe you should look the context
> before doing such kind of affirmations.
>
> In the Intel Pentium and P-II ages, I started to wrote the
> very first Spectrum emulator in C. With that "cpu power", emulators
> had to be written in ASM to be capable to emulate the destination
> machines at 100% full speed in multitasking systems.
>
Hey, I got 100% with ASM ZX Spectrum emulator on a low end 386 :-) (I do
not remember the CPU freqeuncy anymore, maybe 25MHz). First emulator in
C that appeared on the emu-scene (I guess it was x128) needed 486
(~80MHz?) to run at realtime. Pentium and Pentium II was A LOT of
power :-)
...
>
> Now I'm porting the emulator to a scripted language, so I need
> even more previous design ideas before starting to code, so that
> I can achieve (I hope I'll be able to do it with this group's help)
> 100% cpu speed in an standard desktop PC.
>
>> > But it seems that is not possible :-(
http://perl-spectrum.sourceforge.net/
It is quite fast IMHO.
Just remember to use psyco...
--
-----------------------------------------------------------
| Radovan GarabĂk http://kassiopeia.juls.savba.sk/~garabik/ |
| __..--^^^--..__ garabik @ kassiopeia.juls.savba.sk |
-----------------------------------------------------------
Antivirus alert: file .signature infected by signature virus.
Hi! I'm a signature virus! Copy me into your signature file to help me spread!
More information about the Python-list
mailing list