Announcement

Collapse
No announcement yet.

Clang-Based Tool Makes It Easy To Show Inefficient Qt Coding Mistakes

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

  • #11
    do KDE Qt guys prefer GCC or Clang? (n.b. this is a fact question, not an opinion question. i used to use GCC for a cxx project that was incompatible with Clang and presumably if the lead developer had chosen Clang first we would have used that)

    Comment


    • #12
      Originally posted by mmstick View Post
      LLVM compiler plugins are a huge incentive for language tool authors to use LLVM. GCC has always been hostile towards compiler plugins due to fears over the possibility of proprietary compiler plugins.
      GCC has supported plugins since version 4.5. Most of the hostility is on the part of potential contributors because GCC is GPL-licensed software, and LLVM is BSD-licensed software. Also LLVM gets Big Money support from the likes of Apple and Google, and that kind of lubricant makes buying the opinions of significant portions of the open source community easier.

      I'd also like to point out that LLVM has a slightly easier API to work with for plugins, but not significantly better enough to account for the difference in developer choice.

      Comment


      • #13
        Originally posted by tildearrow View Post
        I never catch number typos. Though I was kind of confused after reading "2017".

        Also, why is GCC unsuitable for this kind of projects? Why Clang? (If it causes havoc, I'm sorry)
        Clang/LLVM is much more than a compiler, it's a framework for creating compilers and similar tools. The API is very good and most internals you'll need are exposed.

        Can GCC's infrastructure be used to create static-analysis tooling that easily ? I don't know, and honestly I didn't even investigate. When I started developing clazy the clang-based tooling apps were popping up like mushrooms, there were many tutorials and I got running in no time.

        It wasn't a religious decision, whatever got the job done was fine. I don't have a grudge against GNU.

        Btw, clazy can run on Windows against msvc runtime, I don't think gcc can do that. And on macOS Clang is more popular too.


        Originally posted by eigenlambda View Post
        do KDE Qt guys prefer GCC or Clang? (n.b. this is a fact question, not an opinion question. i used to use GCC for a cxx project that was incompatible with Clang and presumably if the lead developer had chosen Clang first we would have used that)
        I don't think there's a precise answer to your question.

        I would say most people don't care and just use the system's default (gcc on Linux / Clang on macOS). However, the people who do care about compilers are usually fans of Clang, I've haven't seen many people passionate about gcc.


        Comment


        • #14
          Originally posted by cj.wijtmans View Post

          i was wonderin the same thing why cant it be done with gcc. GCC doesnt have the infra probably?
          GCC was designed on purpise to minimize possible uses like this. The thing people dont get with GPL and the Free Software Foundation is that your software isnt actually free.

          LLVM/CLang was designed from the beginning to be a suite of tools essily incorporated into other software. Much of the tech is exposed in libraries easily integrated into other software. If you spend some time on the various LLVM related sites you will get an idea as to how successful this has made the world of CLang and LLVM. Parts of the core project are used by hundreds of sub projects, reseach efforts and the like.

          Basically GCC was screwed up by extremely short sighted, anti business people at the Free Software Foundation. They have a very perplexing definition of "FREE". GCC was in effect designed to be something other than Free. It is or certainly was a monolithic piece of trash that defied modern software development practices.

          Comment


          • #15

            I don't think there's a precise answer to your question.
            There are lots of opinions but in the end it comes down to GCC not being designed from the start to do what the suite of tools developed under the LLVM banner do. The reason GCC was in this state was mangerial and certainly doesnt reflect upon GCC's development team.
            I would say most people don't care and just use the system's default (gcc on Linux / Clang on macOS). However, the people who do care about compilers are usually fans of Clang, I've haven't seen many people passionate about gcc.

            While im not sure about the above, im pretty sure interest in LLVM is driven by technical values and freedom one doesnt get in GCC / GPL land.

            The problem i see with GCC is that you have a very talented compiler development team with one hand tied behind their backs by the FSF. That dynamic stunted GCC's development for years. Parallel to this GPL evolved from something companies could live with to something absolutely horrible with GPL3. Actually GPL3 turned off a lot of freelance open source developers working on their own dime.

            In the end im not sure people get passionate about a developers tool. Im not even sure id want to be around such people if they existed. What people see in LLVM is a large collection of very nice tools that are easy to use and easy to integrate. There really is nothing like it these days.

            Comment


            • #16
              Originally posted by wizard69 View Post
              There are lots of opinions but in the end it comes down to GCC not being designed from the start to do what the suite of tools developed under the LLVM banner do. The reason GCC was in this state was mangerial and certainly doesnt reflect upon GCC's development team.


              While im not sure about the above, im pretty sure interest in LLVM is driven by technical values and freedom one doesnt get in GCC / GPL land.

              The problem i see with GCC is that you have a very talented compiler development team with one hand tied behind their backs by the FSF. That dynamic stunted GCC's development for years. Parallel to this GPL evolved from something companies could live with to something absolutely horrible with GPL3. Actually GPL3 turned off a lot of freelance open source developers working on their own dime.
              Bullshit. The only ones objecting to GPLv3 a freeloaders and parasites. There's a reason all the big healthy long lives projects are GPL, and the only ones that survive as BSD are either entirely sponsored by one big parasite, or are just fringe tech.

              Comment


              • #17
                Originally posted by wizard69 View Post
                There are lots of opinions but in the end it comes down to GCC not being designed from the start to do what the suite of tools developed under the LLVM banner do. The reason GCC was in this state was mangerial and certainly doesnt reflect upon GCC's development team.


                While im not sure about the above, im pretty sure interest in LLVM is driven by technical values and freedom one doesnt get in GCC / GPL land.
                It is driven by a cleaner better structure, and a large wealthy company. Don't put all the other politically loaded nonsense into it.

                Comment


                • #18
                  Looks like someone is on a rampage against copyleft... good to know that it isn't Clazy dev but some random forum troll.

                  Comment


                  • #19
                    Originally posted by bregma View Post

                    GCC has supported plugins since version 4.5. Most of the hostility is on the part of potential contributors because GCC is GPL-licensed software, and LLVM is BSD-licensed software. Also LLVM gets Big Money support from the likes of Apple and Google, and that kind of lubricant makes buying the opinions of significant portions of the open source community easier.

                    I'd also like to point out that LLVM has a slightly easier API to work with for plugins, but not significantly better enough to account for the difference in developer choice.
                    I honestly doubt that it's as easy as outlined in this blog post : http://bbannier.github.io/blog/2015/...sis-check.html

                    to create a plugin that does static analysis with GCC.

                    Comment


                    • #20
                      Originally posted by carewolf View Post
                      It is driven by a cleaner better structure, and a large wealthy company. Don't put all the other politically loaded nonsense into it.
                      I didn't put any politically load nonsense in my statements. The statements reflect the fact that many find GPL3 appalling. Beyond that there is little doubt that GCC's problems are management related and are a direct result of policy. Why anyone would debate this is beyond me.

                      Comment

                      Working...
                      X