Slashdot Mirror


Speed Test: Comparing Intel C++, GNU C++, and LLVM Clang Compilers

Nerval's Lobster writes "Benchmarking is a tricky business: a valid benchmarking tries to remove all extraneous variables in order to get an accurate measurement, a process that's often problematic: sometimes it's nearly impossible to remove all outside influences, and often the process of taking the measurement can skew the results. In deciding to compare three compilers (the Intel C++ compiler, the GNU C++ compiler (g++), and the LLVM clang compiler), developer and editor Jeff Cogswell takes a number of 'real world' factors into account, such as how each compiler deals with templates, and comes to certain conclusions. 'It's interesting that the code built with the g++ compiler performed the best in most cases, although the clang compiler proved to be the fastest in terms of compilation time,' he writes. 'But I wasn't able to test much regarding the parallel processing with clang, since its Cilk Plus extension aren't quite ready, and the Threading Building Blocks team hasn't ported it yet.' Follow his work and see if you agree, and suggest where he can go from here."

5 of 196 comments (clear)

  1. Re:first post by Anonymous Coward · · Score: 5, Funny

    compiled with clang

  2. Re:first post by Anonymous Coward · · Score: 2, Funny

    man, it took a long time to read it.

  3. Re:first post by neokushan · · Score: 3, Funny

    first ++pre

    --
    +1 IDisagreeSoHeMustBeATrollOrAnAstroturferOrAShill
  4. Re:first post by TheNastyInThePasty · · Score: 4, Funny

    int FirstPost(int a, int b)
    {
       if(a < b)
           printf("I got first post!");
       else
          printf("No, I got first post!");
    }

    int main(int argc, const char** argv)
    {
       int i = 0;

       // What prints out here?
       FirstPost(i++, i++);
    }

    --
    The best thing about UDP jokes is I don't care if you get them or not
  5. Re:Compile time is irrelevant. by F.Ultra · · Score: 2, Funny

    A week? Try Gentoo.