Forum > Debugger

view argc and argv in FpDebug

<< < (2/3) > >>

TRon:

--- Quote from: 440bx on February 23, 2024, 03:22:31 am ---Good idea and it works.

--- End quote ---
Thank you for the confirmation.


--- Quote ---I still think the debugger should be able to watch argc and argv without having to "absolute" variables on top of them because their addresses are in the COFF symbol table but, I'm pleased to have a way to inspect the values.

--- End quote ---
coff is able to tell the symbol name and most probably the size of these symbols but details about the type of these symbols is something that is part of (actual) debug information. Also reason why disassemblers can't really do anything useful without debug information in a format that they can understand. Ofc some symbol names used, and startup code sequences are generic to certain compilers and can be used to make an educated guess but they also often go wrong on (guessing) the format of the actual contents of a symbol. As far as my understanding goes fpDebug does not understand coff debug information.

440bx:

--- Quote from: TRon on February 23, 2024, 03:53:06 am ---Thank you for the confirmation.

--- End quote ---
My pleasure and thank you for your help.

ccrause:

--- Quote from: TRon on February 23, 2024, 03:53:06 am ---
--- Quote from: 440bx on February 23, 2024, 03:22:31 am ---I still think the debugger should be able to watch argc and argv without having to "absolute" variables on top of them because their addresses are in the COFF symbol table but, I'm pleased to have a way to inspect the values.

--- End quote ---
coff is able to tell the symbol name and most probably the size of these symbols but details about the type of these symbols is something that is part of (actual) debug information. Also reason why disassemblers can't really do anything useful without debug information in a format that they can understand. Ofc some symbol names used, and startup code sequences are generic to certain compilers and can be used to make an educated guess but they also often go wrong on (guessing) the format of the actual contents of a symbol. As far as my understanding goes fpDebug does not understand coff debug information.

--- End quote ---
Yes, fpdebug only understands DWARF.

440bx:

--- Quote from: ccrause on February 23, 2024, 06:28:11 am ---Yes, fpdebug only understands DWARF.

--- End quote ---
I wasn't sure if it used the COFF information or not.  Good to have confirmation that it doesn't.

It's a bit unfortunate it doesn't because the COFF symbol table includes information not found in the dwarf sections and, parsing the COFF symbol table is relatively easy.  OTH, no big deal and the solution in this case is quite simple.

ETA:

I just realized that even if FpDebug parsed the COFF symbol table, it wouldn't obtain the variables' size.  IDA Pro figures them out from how they are used in the code, a debugger-only cannot be expected to do that much analysis.

Thaddy:
Just curious: why argc and argv instead of ParamCount and ParamStr? Afaik they are direct mappings on Windows. (Except shortstring vs AnsiString which is in Objpas)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version