Arithmetic overflow except in debugger disassembler
Original Reporter info from Mantis: Martin @martin_frb
-
Reporter name: Martin Friebe
Original Reporter info from Mantis: Martin @martin_frb
- Reporter name: Martin Friebe
Description:
You need to run Lazarus as debugged application (and then start another debugging session, inside the debugged Lazarus)
Set a breakpoint on SourceEditor.SetExecutionLine.
Get the debugged lazarus to stop at this line
Open assembler window
=> boom
Additional information:
the last bits from the debug output:
=thread-exited,id="2",group-id="4992"
~"[Switching to Thread 4992.0x1608]\n"
*stopped,reason="breakpoint-hit",disp="keep",bkptno="6",frame={addr="0x00956a3f",func="SETEXECUTIONLINE",args=[{name="this",value="0xb3ebab8"},{name="NEWLINE",value="-1"}],file="sourceeditor.pp",fullname="C:/lazarus_latest/ide/sourceeditor.pp",line="3573"},thread-id="1",stopped-threads="all"
=thread-selected,id="1"
(gdb)
<-data-disassemble -s 9792063 -e 9792094 -- 1>
^done,asm_insns=[src_and_asm_line={line="3573",file="sourceeditor.pp",line_asm_insn=[{address="0x00956a3f",func-name="SETEXECUTIONLINE",offset="15",inst="mov
-0x8(%ebp),%eax"},{address="0x00956a42",func-name="SETEXECUTIONLINE",offset="18",inst="call
0x959280
&LtPos;GETEXECUTIONLINE>"},{address="0x00956a47",func-name="SETEXECUTIONLINE",offset="23",inst="mov
-0x4(%ebp),%edx"},{address="0x00956a4a",func-name="SETEXECUTIONLINE",offset="26",inst="cmp
%edx,%eax"},{address="0x00956a4c",func-name="SETEXECUTIONLINE",offset="28",inst="je
0x956ab8
&LtPos;SETEXECUTIONLINE+136>"}]},src_and_asm_line={line="3574",file="sourceeditor.pp",line_asm_insn=[{address="0x00956a4e",func-name="SETEXECUTIONLINE",offset="30",inst="mov
-0x8(%ebp),%eax"},{address="0x00956a51",func-name="SETEXECUTIONLINE",offset="33",inst="mov
0xc(%eax),%eax"},{address="0x00956a54",func-name="SETEXECUTIONLINE",offset="36",inst="mov
0x8(%eax),%eax"},{address="0x00956a57",func-name="SETEXECUTIONLINE",offset="39",inst="test
%eax,%eax"},{address="0x00956a59",func-name="SETEXECUTIONLINE",offset="41",inst="jne
0x956a70
&LtPos;SETEXECUTIONLINE+64>"}]},src_and_asm_line={line="3575",file="sourceeditor.pp",line_asm_insn=[{address="0x00956a5b",func-name="SETEXECUTIONLINE",offset="43",inst="mov
-0x4(%ebp),%eax"},{address="0x00956a5e",func-name="SETEXECUTIONLINE",offset="46",inst="cmp
$0xffffffff,%eax"},{address="0x00956a61",func-name="SETEXECUTIONLINE",offset="49",inst="je
0x956ab8 &LtPos;SETEXECUTIONLINE+136>"}]}]
(gdb)
TApplication.HandleException Arithmetic overflow
Stack trace:
$00BB524C line 1539 of ../debugger/gdbmidebugger.pp
$004A72AE line 286 of ../objpas/classes/lists.inc
$004A7343 line 306 of ../objpas/classes/lists.inc
$004A8068 line 714 of ../objpas/classes/lists.inc
$00BBF82B line 4003 of ../debugger/gdbmidebugger.pp
$00925006 line 1818 of ../debugger/debugger.pp
$009243C8 line 1639 of ../debugger/debugger.pp
$00BAE244 line 546 of ../debugger/assemblerdlg.pp
$00BAD155 line 309 of ../debugger/assemblerdlg.pp
$0091EE96 line 1679 of debugmanager.pas
$0092449C line 1651 of ../debugger/debugger.pp
$00BBD846 line 3505 of ../debugger/gdbmidebugger.pp
$00BBE95A line 3955 of ../debugger/gdbmidebugger.pp
$00BB4790 line 1378 of ../debugger/gdbmidebugger.pp
$00BB4185 line 1274 of ../debugger/gdbmidebugger.pp
$00BC0223 line 4391 of ../debugger/gdbmidebugger.pp
$00BBAC63 line 2847 of ../debugger/gdbmidebugger.pp
Mantis conversion info:
- Mantis ID: 16318
- Version: 0.9.29 (SVN)
- Fixed in version: 0.9.29 (SVN)
- Fixed in revision: 27569 (#ea59a61d)
- Target version: 0.9.30