[OpenBIOS] Defining ." and "
Stefan Reinauer
stepan at suse.de
Fri Jun 7 18:04:14 CEST 2002
* Stefan Reinauer <stepan at suse.de> [020607 16:11]:
> HEX
> 0 > : " 22 PARSE ; IMMEDIATE
> ok
> 0 > : ." 22 PARSE TYPE ; IMMEDIATE
> ok
I got a bit further - Tried something like
: ALLOT HERE+ ;
: " 22 PARSE HERE C@ 1+ ALLOT ;
HERE+ seems to do what ALLOT is supposed to do, is that right?
I looked into the code and it seems a bit unclear to me. HERE
should be like : HERE DP @ ;
As HERE is a prim word, and DP is not visible from outside, I looked
into the code and found:
code_HERE:
{
(++dp)->a = interpreter->here;
NEXT;
}
code_HERE_X2b:
{
interpreter->here += (dp--)->n;
NEXT;
}
Looks like "dp" what is called SP/TOS, whereas &(interpreter->here) is
DP. Is this right? We should comment this or rename to a more intuitive
name scheming...
Using HERE+ for ALLOT did not solve the problem overwriting the text.
Any ideas?
Stefan
--
The x86 isn't all that complex - it just doesn't make a lot of
sense. -- Mike Johnson, Leader of 80x86 Design at AMD
Microprocessor Report (1994)
-
To unsubscribe: send mail to majordomo at freiburg.linux.de
with 'unsubscribe openbios' in the body of the message
http://www.freiburg.linux.de/OpenBIOS/ - free your system..
More information about the openbios
mailing list