Hi everyone! :)
I want know how detect a memory leak/overflow from my dos executable compiled wih freebasic ? (eventually with -g)
GDB tool for DOS does not this :(
Regards!
How detect memory leak / overflow
-
- Posts: 862
- Joined: May 05, 2015 5:35
- Location: Germany
Re: How detect memory leak / overflow
Hello Cpcdos!
Put the statement FRE into your program at an appropriate place, let the program run and watch the value. If it becomes less and less and less... you probably got a memory leak.
Put the statement FRE into your program at an appropriate place, let the program run and watch the value. If it becomes less and less and less... you probably got a memory leak.
Re: How detect memory leak / overflow
Hello grindstone!
Thank you for your reply, under freedos, the FRE value never goes back, like if FRE can't see the "deallocated memory" :(
I can block any irq, and use malloc in loop until saturation, and get number bytes used and freeing this.
So apparently, he does not exist a tool for FreeBasic (DOS) ?
Regards
Thank you for your reply, under freedos, the FRE value never goes back, like if FRE can't see the "deallocated memory" :(
I can block any irq, and use malloc in loop until saturation, and get number bytes used and freeing this.
So apparently, he does not exist a tool for FreeBasic (DOS) ?
Regards
-
- Posts: 862
- Joined: May 05, 2015 5:35
- Location: Germany
Re: How detect memory leak / overflow
Hm... Maybe you could try to call the freedos - statement MEM via the FB - SHELL - command? Only a suggestion. No clue if it works.
Re: How detect memory leak / overflow
Hmm.. MEM He can't detect DPMI memory :/ Never mind
But thank you for your help :)
But thank you for your help :)