Call stack from package with line numbers

delphi package - automated exception handling

Call stack from package with line numbers

Postby StephaneGrobety » Thu Jul 26, 2018 9:12 am

Hello,

I'm wondering how I can get the detailed line number for the stack trace items concerning functions in packages.

I have an application that uses runtime packages. These packages are built as part of the overall build process and they are then processed with madExceptPatch.exe to integrate their map file. The do NOT include the mad* units, though, that is reserved for the main applications.

When I receive a bug report, only the items located in the main application module (not the package) have line numbers attached.

I understand why I don't get these numbers for the standard packages (RTL, VCL, etc.) but shouldn't I have the line numbers for these packages as well?
StephaneGrobety
 
Posts: 5
Joined: Tue Jul 17, 2018 9:21 am

Re: Call stack from package with line numbers

Postby madshi » Thu Jul 26, 2018 10:40 am

Did you compile your packages with a detailed map file? Please check the contents of the map file to see if line numbers are actually included.
madshi
Site Admin
 
Posts: 9826
Joined: Sun Mar 21, 2004 5:25 pm

Re: Call stack from package with line numbers

Postby StephaneGrobety » Tue Jul 31, 2018 8:25 am

Hello,

The packages are all compiled with the detailed map files (-qd). The line numbers are included but only for a limited number of units. I have no idea why, really.

BTW, something similar happen if I compile without packages, from the IDE: I only get line numbers for a limited number of files.

The command line for the packages is the following:

"C:\Borland\RADStudio\19.0\bin\dcc32.exe" w:\wineur\lib\GITpackages\GITpkgLib.dpk -B -Q -gd /DmadExcept

And for the programs:

"C:\Borland\RADStudio\19.0\bin\dcc32.exe" W:\WINEUR\src\gad\wgamain.dpr -B -Q -LUGITPkgLib -LUGITPkg -LUGITPkg2 /DCRM -gd /DmadExcept

Followed by

w:\wineur\bat\madExceptPatch.exe w:\wineur\bin\wgamain.exe w:\wineur\bat\madExcept\wineur.mes
StephaneGrobety
 
Posts: 5
Joined: Tue Jul 17, 2018 9:21 am

Re: Call stack from package with line numbers

Postby madshi » Tue Jul 31, 2018 8:35 am

So is the issue that the map file doesn't contain the information? Or does the map file contain the information but madExcept doesn't show it?
madshi
Site Admin
 
Posts: 9826
Joined: Sun Mar 21, 2004 5:25 pm

Re: Call stack from package with line numbers

Postby StephaneGrobety » Tue Jul 31, 2018 9:56 am

The map file doesn't contains the information (I would say)
StephaneGrobety
 
Posts: 5
Joined: Tue Jul 17, 2018 9:21 am

Re: Call stack from package with line numbers

Postby madshi » Tue Jul 31, 2018 10:10 am

There are some compiler options which define if line numbers are included or not. Try {$D+}{$L+}.
madshi
Site Admin
 
Posts: 9826
Joined: Sun Mar 21, 2004 5:25 pm

Re: Call stack from package with line numbers

Postby StephaneGrobety » Tue Jul 31, 2018 4:12 pm

These are on by default and we don't disable them in our projects but I'll add them to the command-line nevertheless
StephaneGrobety
 
Posts: 5
Joined: Tue Jul 17, 2018 9:21 am

Re: Call stack from package with line numbers

Postby madshi » Tue Jul 31, 2018 4:42 pm

To sum this up: madExcept can't magically invent line numbers out of thin air. So if the map files are missing the line number information then it's definitely not madExcept's fault. I'm not sure exactly *why* the line number information is missing. If adding {$D+}{$L+} doesn't help, it might be something to ask Embarcadero?
madshi
Site Admin
 
Posts: 9826
Joined: Sun Mar 21, 2004 5:25 pm


Return to madExcept

Who is online

Users browsing this forum: No registered users and 6 guests