tron@uni-paderborn.de (Matthias Scheler) (06/25/91)
ATTENTION!ATTENTION!ATTENTION!ATTENTION!ATTENTION!ATTENTION!ATTENTION!
Commodore changes the Task-Switch Stackframe format for 6888x since
KickV37.175(I think so).
So,for all guys writing a Debugger,like me,it's not practible to add
a new version check every KICKV2.x release.
SO I PREFER A NEW EXECFUNCTION:
NAME
GetStackFrameOffset -Get Registeroffset for Stackframe
SYNOPSIS
RegOffset=GetStackFrameOffset(RegName,Task)
D0.w D0.w A1
FUNCTION
This Function should return the offset of the specified
Register,so you can find the Register value independent
from the KICK Version.
INPUTS
RegName - ID-Number of the Register Offset you want
Task
RESULT
RegOffset - Stackoffset of the Register you want
-1=False
EXAMPLE
move.l 4.w,a6
jsr Forbid
move.l #REG_SR,d0
jsr GetStackFrameOffset(a6)
move.l 276(a6),a1
move.l TC_SPREG(a1),a1
add.w d0,a1
;a1 is a pointer on the Registervalue sr
or.w #$8000,(a1)
;Turn on Trace Mode
;Stop the Task next Run(You must have an Exeptionhandler for the Task).
.
.
.
jsr Permit(a6)
INCLUDES
ENUM
EITEM REG_D0
EITEM REG_A0
EITEM REG_FP0
EITEM REG_SR
EITEM REG_PC
EITEM REG_FPCR
EITEM REG_FPUSTACKFRAME
I think it's important to add a new function like that!
What do you think?
--
0OOOO OOOO OOO O O
O O O O O OO O
O OOOO O O O O O
O O O O O O OO
O O O OOO O O
(Matthias Scheler, tron@uni-paderborn.de)