[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: Memory problems--Carl?



How large are we talking about?

I think it's the number of macros, because I'm getting a warning PRompt message about that, telling me to "clear some macros." The pgm occupies 12k of disk space and uses about 60 different save/gets. I know that's too many, so I want a tool that will help me decide which can be re-used. Would RENUMBER be useful?

 That could be your problem right
there. If your code is very long, try breaking the routine into
smaller discrete operations -- separate PMs that can be RUN one at a
time.

Yeah, that's what I have done already--what should be 1 pgm is now 5. But some of those 5 are getting too long! The length has come because I'm using these programs to convert plain-text emails into precisely controlled HTML emails, with tables galore. Took me 7 solid months to figure out how to make HTML work in all the different, and noncompliant, email clients. A nightmare. Now I'm just tweaking, almost for fun.


If the routine really has to work as an integral PM, issue
KILLMEM, to free up available S/G memory, before you RUN
the PM.

I already had JM 2. CLEARSGTSQ2 at the start. Just added a call to KILLMEM, but no improvement. What happens is that s/g 02 gets overwritten in the HIDE routine (ironic, huh?). After the "clear some macros" message, I got a message involving s/g 741. So I think what was supposed to go into 741 couldn't and got put into 02 instead. The context is:

JM 2.HIDE:01-49,51-89Q2 ;*;
JM 2.DAYSQ2 ;*;
JM 2.UNHIDEQ2 ;*;

I use that to subtract 21 days from the current date. So the content of 50 right now is:
9/22/2011,-21
and that does function correctly, but going into that call, 02 was "m" and coming out 02 is "4".

I


Hard to say more without seeing the code. There may be one flawed
operation that's causing the whole thing to tank. Or you may have to
rethink the design from scratch. I assume you're routinely using
frames IFEI, SYNTAX and RELABEL to check for rudimentary errors.

Nope, but I will now. Results: all passed, except if I try to do
RELABEL/NR
I get: Bad Path|File


XRAY and XPOLL will display Save/Get contents while the PM is
RUNning and immediately after it EXits. Viewing the contents of S/Gs
can help to visualize errors that are hard to catch just by
inspecting the code.


I'd like to use XPOLL, but I'm unclear how to. I tried running the pgm then doing XPOLL but that didn't show anything (except the small $X stuff I used instead of literal ). I tried putting a JM 2.XPOLLQ2 just before the pgm exits, and that produced nothing.


And believe me, you don't want to see this code.

Thanks for your hand-holding.



Hope this helps.

--
Carl Distefano
cld@xxxxxxxx


Harry Binswanger
hb@xxxxxxxx