Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!
26730 Discussions

Visual Studio macerating /Fd compiler option?

Norman_K_
New Contributor I
133 Views

Dear All

I am using Visual Studio Enterprise 2017 v15.5.4 with Intel(R) Visual Fortran Compiler 17.0.7.272 [Intel(R) 64]

And debugging is not working - not stopping at break points, and when the first fatal error is encountered I am not getting a line number.

I currently compile with the following, as copied from the VS project|properties|command line

/nologo /debug:full /Od /fpp /recursive /standard-semantics /Qdiag-error-limit:50 /stand:f15 /warn:declarations /warn:unused /warn:ignore_loc /warn:truncated_source /warn:interfaces /module:"x64\Debug\\" /object:"x64\Debug\\" /Fd"x64\Debug\vc150.pdb" /traceback /check:bounds /check:stack /libs:dll /threads /dbglibs /c

I checked each of these against the documentation and noticed:

1) The documentation says /Fd[:filename] but there is no : between the /Fd and the filename on the command line shown above.

2) There is no file x64\Debug\vc150.pdb (so I guess this is why I get no line numbers?), and,

3) I am not sure which option or options in VS generate this option on the command line but when I try to add the "correct" version in the additional options box, I get shouted at along the lines of:

ifort: command line warning #10122: overriding '/Fdx64\Debug\vc150.pdb' with '/Fdx64\Debug\vc150.pdb'

So what do I do next? Is the /Fd thing a bug or irrelevant? How do I get the debugger back working?

Thanks

Norman

0 Kudos
1 Solution
Norman_K_
New Contributor I
133 Views

OK scap this post

1) The /Fd:filename thing was a red herring

2) The Intel documentation is wrong and looks like it should read /Fd[:][filename]

3) In order to generate the .pdb file the /Fd option is not enough, "project|linker|debugging|Generate debug info" must also be set to "Yes (/DEBUG)"

4) The debugger now works again

5) It would be really useful if the Intel documentation stated clearly that the compiler switch /Fd may be necessary but is not sufficient to generate the .pdb file and that there is a linker switch  which must be set as well.

Case closed

View solution in original post

1 Reply
Norman_K_
New Contributor I
134 Views

OK scap this post

1) The /Fd:filename thing was a red herring

2) The Intel documentation is wrong and looks like it should read /Fd[:][filename]

3) In order to generate the .pdb file the /Fd option is not enough, "project|linker|debugging|Generate debug info" must also be set to "Yes (/DEBUG)"

4) The debugger now works again

5) It would be really useful if the Intel documentation stated clearly that the compiler switch /Fd may be necessary but is not sufficient to generate the .pdb file and that there is a linker switch  which must be set as well.

Case closed

View solution in original post

Reply