Use the CBLOCK statement in MPASM. Hope this helps, Alan G. smith +--------------- | Alan G. Smith | ags@poboxes.com | http://www.innovatus.com/ags On Wed, 6 Aug 1997, Shane Nelson wrote: > Hi, > > I'm trying to create a nice library of subroutines, > but when reusing them I find it a pain to have to > go through all the EQU's, to make sure I'm not already > using those locations in another part of my program. > > My question: is it possible to have the compiler > dynamically allocate memory in some way? > > ie) > Instead of having to do this: > > COUNT equ h'7' > ACCA equ h'8' > ;16bit > ACCB equ h'9' > ACCD equ h'a' > > I want to be able to get away with something more like this: > > db = define byte > dw = define word > > db COUNT > dw ACCA > db ACCB > db ACCD > > ----- > > Then, instead of hard coding variables it could just use the > next available space. > > > Thanks in advance. > -Shane. >