Add an option to change the complex return type.#434
Conversation
ifort apparently does not return complex numbers in registers as in C/C++ (or gfortran), but instead creates a "hidden" first parameter for the return value. The option --complex-return=gnu|intel has been added, as well as a guess based on a provided FC if not specified (otherwise default to gnu). This option affects the signatures of cdotc, cdotu, zdotc, and zdotu, and a single library cannot be used with both GNU and Intel Fortran compilers. Fixes #433.
|
@fgvanzee this one too. |
| elif [ "x${complex_return}" = "xintel" ]; then | ||
| complex_return_intel01='1' | ||
| else | ||
| echo "${script_name}: unknown complex return type \"${complex_return}\"! Cannot continue." |
There was a problem hiding this comment.
Can we make this default to gnu if not given to not break scripts building BLIS?
There was a problem hiding this comment.
@isuruf it does default to gnu if FC isn't specified explicitly. Do you mean to use gnu even if FC is set?
There was a problem hiding this comment.
Ah, you are right. Didn't read the code correctly. Sorry
There was a problem hiding this comment.
No prob, thanks for the extra set of eyes.
|
Reviewing... |
fgvanzee
left a comment
There was a problem hiding this comment.
Looks good to me. Both Travis CI and AppVeyor seem to be taking Labor Day off, so I'll leave it up to you whether you want to wait for them to wake up before merging.
|
All tests passed before the last commit which is just whitespace stuff, so I'll merge. |
ifort apparently does not return complex numbers in registers as in C/C++ (or gfortran), but instead creates a "hidden" first parameter for the return value. The option --complex-return=gnu|intel has been added, as well as a guess based on a provided FC if not specified (otherwise default to gnu). This option affects the signatures of cdotc, cdotu, zdotc, and zdotu, and a single library cannot be used with both GNU and Intel Fortran compilers. Fixes #433.