Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Comunicados
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
29285 Discussões

IVF results differ from results from CVF compiler

Antoon
Principiante
448 Visualizações

Hi,

At this moment I am testingsimulation software solving lot of equations. These equations are solved whiletime-stepping thru the simulation time with a fixed time-step. Whencomparing the results with my previous compiler, i.e.CVFcompiler of Compaq, I notice that even after 50 time stepsonly 3 of the 6 decimal digits (single precision)are identical. Maybe the round-off algorithm (IEEE) differs between both compilers, but you would expect that these random errors are averaged out during the simulation. But comparing the results it looks as if there is a sort of bias.

Anyone same experience of maybe a proper explanation for these results.

Thxs.

0 Kudos
2 Respostas
TimP
Colaborador honorário III
448 Visualizações

There's been plenty on this topic in earlier forum posts; granted, the search function appears to have degraded. You don't indicate whether you tried the options to attempt closer results between the compilers (CVF fltconsistency, ifort /assume:protect_parens, double evaluation of single precision expressions). If your results are good only to 3 significant figures, which is quite likely in single precision with no special precautions, any change of compiler will produce results such as you report.

Antoon
Principiante
448 Visualizações

If you used CVF, it's impossible to have used single precision only. All expressions are evaluated in double precision; with optimization, the double precision promotion frequently carries past assignment to local single precision scalar variables. If you don't set the fltconsistency option, parentheses may not be observed during evaluation of expressions, so the degree of effective extra precision varies. The promotion of intermediates to double may improve significantly on the growth of errors in some sequences. You could write your source code with explicit promotions so that the numerical behaviort doesn't vary between compilations with and without implicit promotion.

ifort 32-bit has options which present similar considerations as you had with CVF. The normal mode of operation, with SSE options, does not involve double precision intermediates, but parentheses may be ignored if you don't set protect_parens. So, your statements are of no value if you won't discuss compile options.

Responder