Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • New issue created to track trying to prevent constant folding in C and Fortran without reducing the optimization level: github.com/JuliaLang/julia/issues/4821. Commented Nov 15, 2013 at 18:31
  • 2
    In checking the optimized assembler output (-S flag), C's function takes up about 70 lines while gfortran's uses 115 (I'm using 4.4.7, so maybe some differences)? Seems like the ichar function is an expensive call. Commented Nov 15, 2013 at 18:43
  • Everything you say also holds true for the micro-benchmarks in Julia, i.e. the JIT LLVM compiled Julia code, don't they? Esp. in the case of mandel, I don't see how the Julia JIT LLVM compiler could do anything more clever than a C compiler. Commented Nov 15, 2013 at 20:06
  • Btw., I always have that constant-folding case for fib in C, compiled with Clang. I have even asked about that here. Commented Nov 15, 2013 at 20:08