Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

How to inspect which flags are used

Karl_Yngve_L_
Beginner
616 Views

I am working on a Makefile where I am trying to find which flags to use. The current list of flags is (for some historical reason):

-r8 -fpe0 -g -debug all -traceback -fp-model source -warn all -warn unused -check all,noarg_temp_created

From searching, I believe this may be reduced to

-r8 -fpe0 -g -traceback -fp-model source -warn all -check all,noarg_temp_created

However, I was thinking that there might be an option that would list the options that were passed to `ifort`.

0 Kudos
5 Replies
Steven_L_Intel1
Employee
616 Views

If you generate a listing file (-list), all of the flags used will be shown at the end.

0 Kudos
Karl_Yngve_L_
Beginner
616 Views

Thanks, Steve! That works perfectly!

0 Kudos
Matt_Thompson
Novice
616 Views

Indeed! I never knew about this functionality. I think I might try and get a script using this for when I'm debugging a code and trying to clean up the flags.

Steve, is there any place in the Docs or on the Intel site that can help decipher some of the more obscure bits of the listing, e.g.,

       -fp_modbits nofp_contract             -fp_modbits nono_fp_contract

I figure most are only useful to your engineers, and for my purposes a "no-diff" means I got the same flags, I'm guessing.

 

0 Kudos
Lorri_M_Intel
Employee
616 Views

OK, this is one of our internal secrets, but "fp_modbits" is an extended list of fp-model bits, and yes, you're right, it's only interesting internally.

We'll look at fixing the output so that it says "fp_model" instead of "fp_modbits", to avoid the confusion.

        thanks --

                         --Lorri

 

0 Kudos
Adel_S_
Beginner
616 Views

Thanks, Steve! That works perfectly!

0 Kudos
Reply