• Carsten Gräser's avatar
    [!115] Disable floating point exceptions for clang · 9c04ebe1
    Carsten Gräser authored
    Merge branch 'feature/disable-fp-exception-with-clang' into 'master'
    
    ref:core/dune-localfunctions When compiling with -O3 clang versions \>= 5.0
    may generate code containing auxiliary operations dividing by zero altough the
    result is not used. Specifically code like this
    
        for (int i=0; i<=3; i++)
          for (int j=0; j<=3; j++)
            for (int k=0; k<=3; k++)
              if ((m!=i) && (m!=j) && (m!=k))
                z += x*(1.0/(m-k))*(1.0/(m-j))*(1.0/(m-i));
    
    should never devide by zero. While the result of the code is correct with
    clang, it seems to produce additional operations for the ruled out cases where
    we would devide by zero. For more details see the clang bug:
    [https://bugs.llvm.org/show_bug.cgi?id=40280]
    
    The only possible solution on our side is to turn of FP exceptions for clang.
    This hoefully fixes [#13].
    
    See merge request [!115]
    
      [https://bugs.llvm.org/show_bug.cgi?id=40280]: https://bugs.llvm.org/show_bug.cgi?id=40280
      [#13]: gitlab.dune-project.org/NoneNone/issues/13
      [!115]: gitlab.dune-project.org/core/dune-localfunctions/merge_requests/115
    
    
    Closes #13
    9c04ebe1
Name
Last commit
Last update
doc Loading commit data...
dune Loading commit data...
.gitignore Loading commit data...
.gitlab-ci.yml Loading commit data...
CHANGELOG.md Loading commit data...
CMakeLists.txt Loading commit data...
COPYING Loading commit data...
INSTALL Loading commit data...
LICENSE.md Loading commit data...
README.md Loading commit data...
config.h.cmake Loading commit data...
dune-localfunctions.pc.in Loading commit data...
dune.module Loading commit data...