- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm using CVF 5.0 (OK, I know it's time to upgrade, I'm pressing my boss for last 6 months, but he's pretty resistant...).
1) Is there a predefined preprocessor constant to determine whether the current project configuration is "DEBUG" or "RELEASE",
named, say, "_DEBUG" (to be examined with !DEC$IF DEFINED)? OK, I know I can (un)define one for each configuration, but I'm a bit lazy to do a "rebuild all" on 200 source files for FOUR configurations
(two languages * debug/release).
2) Is it possible to insert debug information into "Release" configuration with CVF 5.0? I turned "Full debugging" on
in ...Settings/Fortran/Debug and rebuilt, but I still get "...does
not contain debug information" message. You guess, my release
version somewhere crashes while debug doesn't and I don't have
a mild idea where. I know it's I that screwed something somewhere, just if I could easily know where...
Jugoslav
1) Is there a predefined preprocessor constant to determine whether the current project configuration is "DEBUG" or "RELEASE",
named, say, "_DEBUG" (to be examined with !DEC$IF DEFINED)? OK, I know I can (un)define one for each configuration, but I'm a bit lazy to do a "rebuild all" on 200 source files for FOUR configurations
(two languages * debug/release).
2) Is it possible to insert debug information into "Release" configuration with CVF 5.0? I turned "Full debugging" on
in ...Settings/Fortran/Debug and rebuilt, but I still get "...does
not contain debug information" message. You guess, my release
version somewhere crashes while debug doesn't and I don't have
a mild idea where. I know it's I that screwed something somewhere, just if I could easily know where...
Jugoslav
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jugoslav, this happens to me when I try to debug a Fortran DLL in the CVF, AND the caller is a VB-program. Then it is the VB-program that "?dose not contain debug information". You write about many subroutines coded in 2 different languages. Could it be some of your callers that are written in a language other than Fortran, which dose not contains debug information?
Regards,
Sabalan.
Regards,
Sabalan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
To get debug info in a Release configuration, you also need to check a box under the Link settings to include debug info.
There is no predefined symbol for a debug configuration.
Steve
There is no predefined symbol for a debug configuration.
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, it works now.
The problem was in the folowing piece of code (I removed optimisation from that source file):
The problem was that the code was "optimised" so that "intermediate" results MaxObjX and MaxObjY were skipped by optimizer and directly mWidth and mHeight were calculated. Only... those "intermediate" variables were global (module) variables whose value was used later... and the program crashed at that later instance, since MaxObjX and MaxObjY were zero.
Just curious... was it a known compiler bug fixed at a later CVF release or did I dig out something that survived up to the present days? I'm 99% sure it wasn't a "subtle programming error" by me, just compiler bug?
Jugoslav
The problem was in the folowing piece of code (I removed optimisation from that source file):
MinObjX=MIN(MinXTSV,MinXCv)-10 MinObjY=MIN(MinYTSV,MinYCv)-10 MaxObjX=MAX(MaxXTSV,MaxXCv)+10 MaxObjY=MAX(MaxYTSV,MaxYCv)+10 mWidth=MaxObjX mHeight=MaxObjY
The problem was that the code was "optimised" so that "intermediate" results MaxObjX and MaxObjY were skipped by optimizer and directly mWidth and mHeight were calculated. Only... those "intermediate" variables were global (module) variables whose value was used later... and the program crashed at that later instance, since MaxObjX and MaxObjY were zero.
Just curious... was it a known compiler bug fixed at a later CVF release or did I dig out something that survived up to the present days? I'm 99% sure it wasn't a "subtle programming error" by me, just compiler bug?
Jugoslav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Without seeing a complete example, I couldn't say one way or another.
Steve
Steve
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page