Announcement

Collapse
No announcement yet.

GCC vs. LLVM-GCC Benchmarks

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Originally posted by EnderWiggin View Post
    When building these tests, is there a way to also build and affect the C runtime library.
    Hum, probably you can manage to override the system library with LD_PRELOAD (or LD_LIBRARY_PATH).

    Originally posted by EnderWiggin View Post
    While I can appreciate that many of these tests have "hard stuff" in their code, the performance of an app is always so dependent on the performance of it's underlying runtime library (for things like memcpy, strcmp, etc.) that I think it's worth a look.
    For critical paths (like memcpy, strcmp, ...) the library is probably picking up the most appropriate hand-coded ASM version of the function

    Comment


    • #17
      I think the description of llvm-gcc is incorrect. llvm-gcc back end is not a modified version of gcc, it's llvm. llvm-gcc front end is a modified version of gcc front end. Please confirm.

      And the results were really insightful.

      Comment


      • #18
        Do a test of GCC vs Intel compiler and/or any other compiler. Compile time speed, run time speed, code size ... hmm..

        Comment


        • #19
          I wonder how long it takes until Gentoo migrates to clang... Faster compile speed should be crucial there.

          Comment


          • #20
            Can you guys do a comparison of modern gcc and llvm with Visual Studio and Intel's compiler? It would be interesting to see where the open source compilers are against the proprietary

            Comment


            • #21
              Originally posted by nanonyme View Post
              I wonder how long it takes until Gentoo migrates to clang... Faster compile speed should be crucial there.
              Gentoo maybe, but not Linux kernel. At least not now and probably not in the near future (if ever):

              http://lkml.org/lkml/2009/5/8/388

              the most interesting response IMO:

              http://lkml.org/lkml/2009/5/9/59
              Last edited by kraftman; 09-04-2009, 03:39 PM.

              Comment


              • #22
                It's a long, long way away from being supported on Gentoo. They are actually quite conservative when it comes to changing compilers, which makes sense when you think about it. They have to support all that code being compiled by users with different flags, and switching to a new compiler means going through every single emerge script and fixing every possible combination. Not an easy task to do, even for a gcc upgrade.

                Also, clang itself doesn't support tons of code (think the entire KDE desktop) that's not written in C. They'd almost certainly have to start out using the GCC front-end to get most things working.

                And judging by the benchmarks here, there might be a revolt among those "elite" users who stick on 50 different optimization flags to their CFLAGS in an effort to get any extra performance possible. I think the majority of Gentoo users are quite comfortable with letting the compiler work in the background for half an hour while they surf the web. Cutting that time to 20 minutes in exchange for reducing performance might not make much sense to a lot of them.
                Last edited by smitty3268; 09-04-2009, 05:54 PM.

                Comment


                • #23
                  Originally posted by smitty3268 View Post
                  lso, clang itself doesn't support tons of code (think the entire KDE desktop) that's not written in C. They'd almost certainly have to start out using the GCC front-end to get most things working.
                  Errr, what on Earth does that have to do with anything? That's just like complaining Sun's Java compiler doesn't compile C. :P

                  Comment


                  • #24
                    Originally posted by nanonyme View Post
                    Errr, what on Earth does that have to do with anything? That's just like complaining Sun's Java compiler doesn't compile C. :P
                    Gentoo is hardly going to switch to a compiler that 95% of it's users can't use. That's all I meant. (95% because there are a lot of C++ packages most people use, even in GNOME).

                    Comment


                    • #25
                      Originally posted by nanonyme View Post
                      I wonder how long it takes until Gentoo migrates to clang... Faster compile speed should be crucial there.
                      I think most of the other Gentoo users agree that the speed (and correctness) of the final code counts more than the time it needs for compilation

                      for me it's a bonus if it compiles faster than gcc or {insert other preferred compiler}

                      if e.g. llvm-gcc was 4 times faster during compilation of code but the final code/compiled binary with gcc (without llvm) was 3 times faster during execution than llvm-gcc I'd prefer gcc over llvm-gcc any time

                      Comment


                      • #26
                        Nope, Gentoo users aren't interested in giving up runtime performance for build speed. Who wants software that runs slower? Only developers might find it useful.

                        Comment


                        • #27
                          Originally posted by nanonyme View Post
                          Errr, what on Earth does that have to do with anything? That's just like complaining Sun's Java compiler doesn't compile C. :P
                          GCC is not just a C-compiler...

                          Comment


                          • #28
                            Originally posted by yesterday View Post
                            GCC is not just a C-compiler...
                            This also has no relevance to anything whatsoever. I didn't say anyone would be giving up GCC. Mostly whether they'll set CC="clang" or whatever the binary is.

                            Comment


                            • #29
                              Full comparison.

                              I would love to see LLVM, GCC, and the Intel compiler go head to head. It is an interesting discussion as to what optimization is more important to an end users.
                              My opinion is that for many applications code size is more important than code speed. If the program is faster than the user then the code size will come into play. Quicker to load, uses less ram and so on. For other applications it is code speed.
                              That is one of the reasons I am not all that fond of 100% 64bit environments. ls does not need to use 64 bit pointers!

                              Comment


                              • #30
                                Originally posted by lwatcdr View Post
                                I would love to see LLVM, GCC, and the Intel compiler go head to head. It is an interesting discussion as to what optimization is more important to an end users.
                                My opinion is that for many applications code size is more important than code speed. If the program is faster than the user then the code size will come into play. Quicker to load, uses less ram and so on. For other applications it is code speed.
                                That is one of the reasons I am not all that fond of 100% 64bit environments. ls does not need to use 64 bit pointers!
                                code size!=less resources

                                Comment

                                Working...
                                X