On Mon, 30 Mar 1998 22:43:54 -0500 Chris Eddy writes: > But I can add a cool feature that fits in >with >your idea like a glove. A dead RAM register finder. I regularly jam >the RAM full, and hunt for unused RAM, to find out later that there >were >a few two or three that I wasn't using and didn't see. Shaa. The >problem with my idea is that many RAM variables are simply equates, >and >not oficially allocated until used in a piece of code, and only then >after first being loaded as a movlw. (sometimes, IE FSR operations). >So the use of the RAM can be hidden down in the code a few steps. I notice Microchip uses equ to allocate RAM, which seems very inflexible to me. I use cblocks and have them typically inside the subroutine that uses them. I can add stuff easily without having to search through some list of addresses. The assembler handles it for me. As to unused RAM, it does seem that the assembler could catch any labels (whether code or data) that are not referenced and flag them with warnings. It might also be kinda neat to put conditionals around data or code to include them only if they are referenced somewhere. Of course, this would not catch code that is referenced but by a call or goto that is impossible to get to... Do we write code like that? Finally, the endless search for ram could be resolved to a large extent, I believe, by keeping local (automatic, non-static) variables on a stack (if we had access to one). Harold _____________________________________________________________________ You don't need to buy Internet access to use free Internet e-mail. Get completely free e-mail from Juno at http://www.juno.com Or call Juno at (800) 654-JUNO [654-5866]