You are not logged in -
nap
CSDb User Forums
Forums
>
C64 Coding
>
Reverse debugging in emulator?
2012-09-15
13:41
Paulko64
Registered: Jul 2010
Posts: 24
Reverse debugging in emulator?
Hi all,
I'm currently working on a game-project that has high irregular CPU load during each frame. I've coded everything in such a way that all this irregular code is ran during a mainloop and starting of the routines is regulated during raster-irqs (besides the multiplexor and music calls).
Now this all works perfectly except for once in a few minutes my game crashes (CPU-jam), because it apparently jumped to a strange adres (ZP in my case). I'm not sure what happened but maybe I didn't end the irqs well enough, or perhaps I used the same ZP-adres for indirect adressing in both main and irq-code, which then screws up code if an irq fires at exactly the right (wrong!) moment...
Anyhow, this proves to be very hard to troubleshoot. So I thought, isn't there an emulater that supports some kind of "reverse debugging"? I.e. when I get a CPU-jam can I trace back what instructions were used just before? Or maybe an emulator that supports writing all instructions executed to a textfile which I can then trace back? Although this last option will probably generate a HUGE trace-file.
Does anybody know how to accomplish something like this?
Thanks,
PaulKo64
... 20 posts hidden. Click
here
to view all posts....
2012-09-26
20:00
Paulko64
Registered: Jul 2010
Posts: 24
Yeah, finally solved the bug! I couldn't have done it without the "chis" command.
What happened was that due to a negative offset an unrelated routine corrupted the hi-byte in one of my jump-tables. Now minutes later when actually using this particular jump-adres I ended up in zero-page where after some random instructions it encounterd a BRK instruction and crashed soon thereafter!
So luckily I can now continue with the rest of the game.
Thanks all!
Previous
-
1
|
2
| 3 - Next
Refresh
Subscribe to this thread:
You need to be logged in to post in the forum.
Search the forum:
Search
All forums
C64 Coding
C64 Composing
C64 Pixeling
C64 Productions
CSDb Bug Reports
CSDb Development
CSDb Discussions
CSDb Entries
CSDb Feedback
CSDb Info
CSDb moderators
CSDb Questions
Messages to moderators
Requests
for
in
Writer & text
Text
Writer
All times are CET.
Search CSDb
All
Releases
Groups
Sceners
Events
BBS
SIDs
-------
Forum
Comments
Advanced
Users Online
icon/The Silents, Sp..
Mike
Peacemaker/CENSOR/Hi..
MWR/Visdom
DeMOSic/MS^LSD^ONS
Magic/Nah-Kolor
rambo/Therapy/ Resou..
Raf/Vulture Design
Ax!s/Onslaught - TND
Guests online: 89
Top Demos
1
Next Level
(9.7)
2
13:37
(9.7)
3
Mojo
(9.7)
4
Coma Light 13
(9.6)
5
Edge of Disgrace
(9.6)
6
What Is The Matrix 2
(9.6)
7
The Demo Coder
(9.6)
8
Uncensored
(9.6)
9
Comaland 100%
(9.6)
10
Wonderland XIV
(9.6)
Top onefile Demos
1
No Listen
(9.6)
2
Layers
(9.6)
3
Cubic Dream
(9.6)
4
Party Elk 2
(9.6)
5
Copper Booze
(9.6)
6
Dawnfall V1.1
(9.5)
7
Rainbow Connection
(9.5)
8
Onscreen 5k
(9.5)
9
Morph
(9.5)
10
Libertongo
(9.5)
Top Groups
1
Performers
(9.3)
2
Booze Design
(9.3)
3
Oxyron
(9.3)
4
Censor Design
(9.3)
5
Triad
(9.3)
Top Fullscreen Graphicians
1
Joe
(9.7)
2
Sulevi
(9.6)
3
The Sarge
(9.6)
4
Veto
(9.6)
5
Facet
(9.6)
Home
-
Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.032 sec.