View Issue Details

IDProjectCategoryView StatusLast Update
0032654LazarusIDEpublic2020-01-26 21:18
ReporterJ. Gareth MoretonAssigned ToMartin Friebe 
Status resolvedResolutionfixed 
PlatformWin64OSWindows 7 (64-bit)OS VersionEnterprise
Product Version1.6.4Product Buildr54278, x86_64-win64-win32/win64 
Target VersionFixed in Version2.2 
Summary0032654: Register Debug Window keeps recreating the list upon Step Over / Step Into
DescriptionThere is a very annoying issue with Lazarus in that the Debug Window that displays Registers (Ctrl+Alt+R) under Windows 64-bit (and 32-bit too, I believe). When you step through your program, the list is refreshed every time. The problem with this is that it scrolls the window back to the top, which is irritating if you want to only look at, say, AX instead of the full 64-bit RAX (of which the upper bits may contain garbage data) and also reverts the display format for a register back to Default, which is awkward when you want to evaluate the integer or raw memory on an XMM register.
Steps To ReproduceCompile and run any program, and place a breakpoint anywhere in the source code that the execution will reach (it can either be Pascal or Assembler code) - when the debugger breaks out, view the Registers window, scroll down and/or change the Format of fields of your choice, then press F7 or F8 to step once through the program. Observe the Register window completely clear and re-create the list items, with the scrolling right back at the top and all the value fields reverting to the default format.
Additional InformationIdeally, the Lazarus IDE should only change the Value fields, not re-create the entire list, because the actual registers present should never change.
TagsNo tags attached.
Fixed in Revision62591
Attached Files


Martin Friebe

2019-01-10 01:04

manager   ~0113296

The scroll part is solved in revision 60049.

Normally the display is cleared while the debugger is running (that includes stepping, as step-over could step over a long running procedure).

Note, that (in future / depending on the backend) the list of shown registers can change.
If the stackframe is changed, not all registers' values can be retrieved for calling frames. GDB shows (probably) valued of the top frame for those. Lldb does omit them from the list.

The display format (hex/dec/oct) is still reset on each step.
This requires rework in the backend code.

Christo Crause

2020-01-26 20:52

reporter   ~0120772

This issue is annoying me too. I've started working on this, as a start not freeing the register list whenever the state changes (changes can be viewed here: This seem to work OK for my relatively simple test cases.

Martin, can you give me a description or test case of how the list of registers can change during a debug session so that I can ensure my modification handles that properly?

Martin Friebe

2020-01-26 21:17

manager   ~0120773

I am not aware of the name-list of registers changing. That would be GDB internals, if it exists....

Applied the patch / Thanks

Martin Friebe

2020-01-26 21:18

manager   ~0120774

Please test and close if ok

Issue History

Date Modified Username Field Change
2017-11-07 04:50 J. Gareth Moreton New Issue
2019-01-08 14:11 Martin Friebe Assigned To => Martin Friebe
2019-01-08 14:11 Martin Friebe Status new => assigned
2019-01-10 01:04 Martin Friebe Note Added: 0113296
2020-01-26 20:52 Christo Crause Note Added: 0120772
2020-01-26 21:17 Martin Friebe Note Added: 0120773
2020-01-26 21:18 Martin Friebe Status assigned => resolved
2020-01-26 21:18 Martin Friebe Resolution open => fixed
2020-01-26 21:18 Martin Friebe Fixed in Version => 2.2
2020-01-26 21:18 Martin Friebe Fixed in Revision => 62591
2020-01-26 21:18 Martin Friebe LazTarget => 2.2
2020-01-26 21:18 Martin Friebe Widgetset Win32/Win64 =>
2020-01-26 21:18 Martin Friebe Note Added: 0120774