Hi
I am trying to compile a piece of software with the flags
FFLAGS = -Wall -O2 -fopenmp -nofor-main
CC=icc
FC=ifort
But the compilation yelds a lot of warnings and the binary cannot take advantage of Openmpi parallelization in the thread count
ifort -Wall -O2 -fopenmp -nofor-main -c addimdnodecload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addimdnodedload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addizdofcload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addizdofdload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c add_bo_st.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c add_pr.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort:
-------------------------------------------------------------------------------------------
and it goes like that till the end of compilation.
Which flags should i use with ifort compiler to acheive the same results obtained with the gfortran compiler...?
Best regards
Alex
I am trying to compile a piece of software with the flags
FFLAGS = -Wall -O2 -fopenmp -nofor-main
CC=icc
FC=ifort
But the compilation yelds a lot of warnings and the binary cannot take advantage of Openmpi parallelization in the thread count
ifort -Wall -O2 -fopenmp -nofor-main -c addimdnodecload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addimdnodedload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addizdofcload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c addizdofdload.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c add_bo_st.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort: command line warning #10006: ignoring unknown option '-fopenmp'
ifort -Wall -O2 -fopenmp -nofor-main -c add_pr.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong
type
ifort:
-------------------------------------------------------------------------------------------
and it goes like that till the end of compilation.
Which flags should i use with ifort compiler to acheive the same results obtained with the gfortran compiler...?
Best regards
Alex
链接已复制
2 回复数
I dunno what gfortran's -Wall does, is this to get all compiler warnings? If so then
-warn all -O2 -openmp -nofor-main
You should consider reading the friendly manual on both compilers to confirm this selection.
ron
-warn all -O2 -openmp -nofor-main
You should consider reading the friendly manual on both compilers to confirm this selection.
ron
