[A83] Re: program pointers


[Prev][Next][Index][Thread]

[A83] Re: program pointers




if you're gonna do it the hard way, couldn't you just do a
bcall(_chkfindsym) with your programs name in op1 and get a pointer to the
data?  The first two bytes of your program are it's size. so all you would
have to do is take that and add $9d95 to get it's offset when it is running.
btw why aren't you using TASM? 
----------------------------------------------
Original Message
From: "Henk Poley"<HPoley@DDS.nl>
Subject: [A83] program pointers
Date: Sat, 3 Mar 2001 16:05:23 +0100

>
>I need to know the end of the program (that's running). If I'm right I can
>find this by reading the first pointer to a file from the VAT:
>
>	ld	hl,(PROGPTR - 2)	;HL = end_of_program
>
>Am I right? Or can there be other variables (like reals, GDBs, pictures,
>etc.) directly after the executing program? If so, how should I
>get a pointer to the end of my program?
>
>And NO, it can't be done via a simple "end_of_program:" at the end of my
>assembly file. Because I'm using a different assembler (one with a linker)
>and files get linked after the main routine).
>
>	Henk Poley
>
>
>

_____________________________________________
Free email with personality! Over 200 domains!
http://www.MyOwnEmail.com