Yo!
So I'm working on a sprite rout. All working fine - lovely.
I made some additions/revisions - suddenly my "dirty" background redraw goes wrong, even though I made no changes to it. Looks like the redraw is somehow screwing up by a few bytes, so is misaligned.
So I went back to an older version of the source without my changes. Assembled it - even though the changes are rolled back, the above bug is still there!!
So I compared the binaries between my working version, and the non-working version (remember, these should be identical).
There are only two words that are different. These both relate to a point in the code where I flip between two buffers that store the relevant bit of background prior to sprite draw.
In the working binary, these dissemble as:
lea $c(a1),a2
lea $10(a1),a3
... where a1 is a pointer to structure containing, amongst other things, pointers to the two buffers as above. (I then swap these round in following instructions). This is consistent with my source.
But in the non-working binary (with identical source), these disassemble as:
movea.l $c(a1),a2
movea.l $10(a1),a3
Now, my understanding is that the operation of these should essentially be the same (bar affecting flags). But this is the ONLY difference between the buggy binary and the working binary.
1) WTF? Does this make any fornicating sense to anyone?!
2) If this is the problem, how can I make Devpac go back to assembling these as lea again?!
3) If this isn't the problem, what the hell am I missing here??!
THANKS!