Page 1 of 1

Memory leak? Need some help -_-

Posted: Thu Apr 20, 2017 7:44 pm
by Montserrat
Hi, im doing some basic tests, using guides from Bigevilcorp, and other sources.

My test is doing well both in the emulator and real hardware (using sega nomad and UMDK to test), but the ram keeps geting filled until it runs out of space, i've tried to find the cause with REGEN debugger, but i dont get it, I thinks its something with Vint countercan someone take a look? I've attached rom and source. Also a screen:

Image

Thanks in advance.

Re: Memory leak? Need some help -_-

Posted: Thu Apr 20, 2017 7:53 pm
by BigEvilCorporation
You're using BSR for an infinite loop with no RTS - BSR will push the return address to the stack, and since you never return, it'll fill memory up with these addresses forever:

Code: Select all

 bsr		@Loopie
Use BRA if you never intend to return from the subroutine.

Re: Memory leak? Need some help -_-

Posted: Thu Apr 20, 2017 8:00 pm
by Montserrat
Wow that was fast, and yes, solved!

Definetly i have to learn much more about OPCODES, :oops: