Ok, now I can finish. I know I should have not sent that but it was late and
I didn't think it at the time :^). I must get more sleep.

The only use I found for self modifying code was speed. example in basic:

do
a=key
if a=27 then beep:end
If a=64 then beep:beep:end
if a=65 then beep:beep:beep:end
loop

change to:

11 change_next_line_to "goto "+key+1
goto 11
28 beep:end
65 beep:end
66 beep:end

If you can understand my improvised basic-like language, you can see the
improvement.

----- Original Message -----
From: "Goldenpi" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, October 01, 2000 10:29 PM
Subject: Re: OT [newbie] Antique systems [was: Off-topic posts.]


> Self modifying code. The only use I found for this on a z80 was speed. It
> DAD nagging me yto go to bed
> ----- Original Message -----
> From: "Austin L. Denyer" <[EMAIL PROTECTED]>
> To: "List Linux-Mandrake" <[EMAIL PROTECTED]>
> Sent: Sunday, October 01, 2000 8:25 PM
> Subject: Re: OT [newbie] Antique systems [was: Off-topic posts.]
>
>
> >
> >
> > > Ha! I know tricks like that one too! I had a machine like that, and
> wrote
> > > a simple but functioning accounting system in it :)
> >
> > One of my colleagues once tried to write a program to calculate the
> > performance characteristics of large-bore oil hoses, and ran out of
memory
> > on a 16k machine.  I then wrote the thing myself in ... wait for it ...
> 450
> > BYTES!!!!!  Needless to say, it was completely devoid of any eye candy,
> but
> > it worked (well, I wrote it in an evening...)
> >
> > Out of interest, what machines were you using?  How long ago?
> >
> > > Hahahaha!! Memories are coming back indeed... And even where you
needed
> > > more speed than the machine could actually deliver, you'd have to fool
> the
> > > processor, or invent strange code to steal a cycle here or there...
> >
> > Oh yes.  Some of the memory saving tricks were neat too.  I used to use
> > existing constants to save precious register space (pi/pi for 1, pi-pi
for
> > 0, etc.).  Another advantage to programming at that level was this:
> >
> > You knew the value of each op. code.
> >
> > You knew the location in which you stored it in memory.
> >
> > Therefore, you could use these codes for constants too.
> >
> > For example, if the instruction LDA (LoaD Accumulator) was 0fh (15
> decimal)
> > and you had stored that instruction in memory location 02ff, then you
> could
> > call the value 15 by pointing to 02ff.
> >
> > Self-modifying code was fun too, especially when someone else tried to
> parse
> > it #;-D
> >
> > > I agree. People that learn to program these days, on visual such and
so,
> > > can't understand that you can write a complete program in less than
> > > 500Kbytes.
> >
> > I can't wait to get back into it with Linux.
> >
> > One of these days....
> >
> > Regards,
> > Ozz.
> >
> >
> >
> >
>
>


Reply via email to