Have two conflictual points as below:
1. Can setting
The /Qftz- option used to disable FTZ mode.
It is descripts as these sentence "The -ftz and /Qftz options, when applied to the main program, set the FTZ and the DAZ hardware flags. The -no-ftz and /Qftz- options leave the flags as they are". Reference following link:https://software.intel.com/sites/products/documentation/doclib/iss/2013/compiler/cpp-lin/GUID-1659EA...
2. Can’t setting
Can’t set FTZ mode by using Intel Compiler Option.
It is descripts as these sentence "I've said that IPP is built without this switch and FTZ bit is set to 1 in the IPP dllMailn() function - this behavior can't be changed in your app.". Reference following link: https://software.intel.com/en-us/forums/topic/542786
So, can set FTZ mode using Intel Compiler Option or can’t?
If can set, why I doesn’t used /Qftz- option? The reason is version of IPP, isn’t it?
(I use: Visual Studio 2008 SP1, Intel Parallel Studio 2011)
all above - #1 and #2 are correct. Statement #2 is related to a case when IPP is dynamically linked to your application: the setting of FTZ bit to "off" state in your application will be affected by IPP dll load procedure - at dll load stage IPP dllmain() procedure will be called, that sets FTZ to "on" state. And this behavior - behavior of IPP dllmain() - can't be changed by compiler switches during your application building. If you need/want FTZ=0 in your app - you should manually change its state after IPP dllmain() - using specific functions from run-time libraries or via explicit call to IPPAPI( IppStatus, ippSetFlushToZero, ( int value, unsigned int* pUMask ))
I understood statement #2.
I don't understand about statement #1. And how to use /Qftz- option?
Could you tell me more details?
I do the following steps:
- Open Configuration Properties > C/C++ > Command Line
- Add "/Qftz-" to field "Additional Options". Click OK
But when I rebuild the project, the output is
"1>icl: command line remark #10148: option '/Qftz-' not supported"
in the past, for rather old Intel Composer/Compiler versions, there was a differentiation between XE and non-XE versions: the next switches were not supported by the non-XE version:
For the recent versions there is no such differentiation anymore - therefore /Qftz- will work for you if you upgrade your tool set.
Hi Ha Duy,
I guess, you have know that the Floating-point computations using these Intel® SSE and Intel® AVX instructions are accelerated when the FTZ and DAZ flags are enabled and thus the performance of the application improves. Why did you expect to disable it /Qftz-?
Regarding the can and can't , the first can is supposed to you set the flag.. but when call IPP dll, it will do second setting . or we said, the flag is reset, thus your first option don't effect. that is why cant' . Unless as igor mentioned, you call runtime function or ippSetFlushToZero explicitly again, so confirm what you hope to set.