Slashdot Mirror


Compiz Project Releases C++ Based v0.9.0

werfu writes "Compiz 0.9.0, the first release of Compiz rewritten in C++, has been announced on the Compiz mailing list. See the announcement for more info." Compiz has for years been one of my favorite ways to make Windows users envious, despite my (Linux) systems' otherwise low-end graphics capabilities. Besides the switch to C++ from C, this release "brings a whole new developer API, splits rendering into plugins, switches the buildsystem from automake to cmake and brings minor functionality improvements."

237 comments

  1. Wow! by Jugalator · · Score: 5, Funny

    I'm excited to learn about more software using this new programming language of the future!

    --
    Beware: In C++, your friends can see your privates!
    1. Re:Wow! by Anonymous Coward · · Score: 0, Funny

      troll or idiot?

    2. Re:Wow! by McGiraf · · Score: 1

      Jealous of first poster or what?

    3. Re:Wow! by AnonymousClown · · Score: 4, Funny

      troll or idiot?

      People with preternatural foresight will often look like the idiot or a fool.

      I think the grand parent sees the potential of C++ and a bright future for this new and advanced language!

      --
      RIP America

      July 4, 1776 - September 11, 2001

    4. Re:Wow! by Jugalator · · Score: 1

      Truer words haven't been spoken! I am filled with jubilant delight to hear that the Compiz team could exploit the wildly successful merge of the object-oriented and functional programming paradigms of C++!

      --
      Beware: In C++, your friends can see your privates!
    5. Re:Wow! by Anonymous Coward · · Score: 0

      Aargh! you buncha bloody saddas :D (ow sorry... this isn't the bbc nor facebook? )
      anyhoo....
      nice to hear compiz is getting updated in c++..
      and stop pestering Bjarne... C++ is great, but not new....

      sincerely,
      the anonymous coward
      (still having the most posts on slashdot :-) muhahahahah! )

  2. Objects... by David+W.+White · · Score: 0

    This is a good move. I found it surprising that C was still more popular than C++, given C++ benefits. See http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html.

    1. Re:Objects... by daid303 · · Score: 2, Interesting

      I think it's because if you want all the shiny bits of objects and encapsulation then you use Java. If you want raw speed & dirty tricks then you use C.

      I favor C++ myself, but I'm a huge fan of breaking encapsulation.

    2. Re:Objects... by Anonymous Coward · · Score: 3, Funny

      Fun fact: I knew somebody who added a preprocessor step to his compile process to make every class as a friend of every other class, because he was tired with "not being able to use the pesky private stuff in coworker's cold".

    3. Re:Objects... by David+W.+White · · Score: 1

      I understand, but for speed I expect that C++ still outperforms Java, and while C should outperform both of them, C doesn't feature encapsulation, polymorphism and all the other goodies that OOP provides. Why would you want to break encapsulation? Apart from one article I saw in the ACM journal about a year or so ago, every other paper I have read showed that OOP programming was more effective that programming without it (except for those few highly specialized areas where you have to use specialized languages).

    4. Re:Objects... by Shados · · Score: 2, Interesting

      The point is that its niche. The range of situations where you need raw speed, yet by-the-book OOP doesn't slow you down too much is very very small. Games and large commercial desktop apps are basically it. Line of business apps will usually go .NET or Java, web apps will go PHP, .NET, Java, PERL, Python, whatever. Drivers will go C/Assembly, specialized backend systems will go C/Assembly, etc.

      There's exceptions to everything and i realize this is a gross generalization, but overall it stands, leaving C++ in a pretty small (but significant nevertheless) niche as opposed to C. You need too much speed to use the more high level solutions, but not enough speed to require C or assembly...

    5. Re:Objects... by chocapix · · Score: 1

      There's more to C++ than Object Oriented Programing.

      For instance templates are great for generic programing, and they don't carry any runtime speed penalty (they can cost quite a lot at compile time though...). You can even go faster than C in some cases (try std::sort versus libc's qsort on an array of integers, std::sort is more generic and faster because it allows the compiler to easily inline the comparison function). And there's more to C++ than OOP and templates.

      I really like C++ and it's great to see it used in more and more big open source projects, like GCC recently and now, well, Compiz.

      I predict Linux will be ready for the desktop exactly one year after Linus sees the light and rewrites the kernel in C++. :-)

    6. Re:Objects... by js_sebastian · · Score: 5, Insightful

      I understand, but for speed I expect that C++ still outperforms Java, and while C should outperform both of them, C doesn't feature encapsulation, polymorphism and all the other goodies that OOP provides.

      No, C is exactly as fast as C++. C++ only becomes slower if you use certain features that have a performance impact. Example: if you use exceptions, there is a performance penalty. If you don't, you don't get the performance penalty. That is one of the design principles of C++: nothing can be included into the language that slows down code that does not use/need it. The main slow downs you will see in your average C++ program, over the corresponding C, is the use of the string class as opposed to the nasty but fast strcpy and friends, and the extra indirect function calls due to virtual functions (which causes a branch misprediction and hence a pipeline flush on modern cpus, costing you a bunch of clock cycles). Still, you only pay for virtual if you choose to use it, and manually implemented virtual function calls are used all over the place in good old C, with the same effect. Furthermore, C++ templates allow code re-use with exactly 0 performance loss and while the error messages are ugly, they're still a whole load prettier than doing the same thing the C way with recursive includes and lots of preprocessor madness. And you can link to existing C code/libraries without any problems. Frankly, there is no valid reason for starting a new program in C in this day and age.

    7. Re:Objects... by tepples · · Score: 1

      Why would you want to break encapsulation?

      Because perhaps one is trying to work around poor design of a class where useful functionality has not been exposed to the public:. Using the class as intended would result in an abstraction inversion.

    8. Re:Objects... by neonsignal · · Score: 2, Insightful

      I suspect the efficiency gap between C and C++ is smaller than you think. Even if you are very strict about encapsulation of objects, you'd be very unlikely to add more than 10% to the run time. And as others have pointed out, making use of features such as templating can actually help the compiler generate more efficient code.

      C++ was designed so that it adds no overheads to imperative code, while the OOP constructs such as member functions have only one extra parameter (and one level of indirection for virtual functions). Often the extra parameter would have been passed in C anyway, as a pointer to some data structure.

      There are more prosaic reasons why C has persisted. There is the inertia of a large group of programmers who have grown up on procedural languages, with a significant learning curve to switch from this to object oriented programming (even in the scripting world, one sees the still widespread use of imperative paradigms such as in PHP). There is the widespread availability of good C compilers. There are the improvements in the C language, including some features adopted back from C++. There is the existing body of code. There is the historical lack of support for objects in operating systems and associated libraries, so that link formats are oriented towards C procedure calls rather than C++ objects. But these reasons have nothing to do with raw speed.

      Where scalability is less important, I can see why Java (in a web context) or languages based on .NET (in a Windows context) might be seen as alternatives. But I would suggest that this is because they integrate better into their context, rather than because speed doesn't matter.

    9. Re:Objects... by Anonymous Coward · · Score: 0

      Example: if you use exceptions, there is a performance penalty.

      Kind of: some compilers (LLVM for one, I believe) have "cost-free" exceptions, where the runtime performance cost in non-exceptional circumstances (i.e. the vast majority of the time spent executing the program) is nil, although there will always be an increase in binary size due to exception tables, etc. Recalling that one advantage of using exceptions is to reduce the need to perform checks on the return values of functions/ methods after every call, its easily possible for a language with exceptions to perform faster (again, in non-exceptional circumstances) than the equivalent program that always checks the return value instead.

    10. Re:Objects... by Anonymous Coward · · Score: 0

      C++ does not work very well on modern microcontrollers compared to C

    11. Re:Objects... by tepples · · Score: 1

      C++ only becomes slower if you use certain features that have a performance impact.

      And virtually every useful feature of C++ that is not in its common subset with C is one of those.

      Example: if you use exceptions, there is a performance penalty.

      And if you use operator new, you use exceptions.

      The main slow downs you will see in your average C++ program, over the corresponding C, is the use of the string class

      That and <iostream>. Once, I tried programming in GNU C++ for a system with an ARM7 CPU and 288 KiB of RAM. Even after applying all the link-time space optimizations I could find, Hello World statically linked against GNU libstdc++'s <iostream> still took 180 KiB. (Dynamic linking wouldn't even have worked because libstdc++.so itself is bigger than RAM.)

      Furthermore, C++ templates allow code re-use with exactly 0 performance loss

      As I understand it, C++ compilers implement templates by making a copy of the object code for each type for which the template code is instantiated. Once you instantiate a template numerous times, your binary gets bigger, and it slows down because it has to keep loading data from storage instead of caching it in RAM. This hurts especially on handheld platforms such as the Nintendo DS, which has only 4 MiB of RAM.

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      This is true but only technically, because most of C is also contained in C++.

    12. Re:Objects... by tepples · · Score: 1

      templates [...] don't carry any runtime speed penalty

      Unless they cause the code to spill out of the instruction cache. Or unless they cause the entire working set to spill out of a handheld device's 4 MB of RAM.

    13. Re:Objects... by daid303 · · Score: 2, Interesting

      Why would you want to break encapsulation?

      Speed. Lazy. Debugging.

      And in C you can have encapsulation, polymorpism and all other goodies OOP provides. C++ just makes it easier. For example many libraries don't export the contents of structures in the exported header files. zlib for example gzopen() returns a "gzFile" which is a typedef void*, and doesn't expose any internals.

    14. Re:Objects... by Anonymous Coward · · Score: 0

      1. Templates, Classes (not virtual), References to name a few
      2. You have other problems when your code runs out of memory that often
      3. which means c sucks too once you find hardware which does not support all functions of the c standard lib? I'm quite sure there are more than enough of those around - assembly is the only real solution!
      4. See Number 3, also as far as I understand it c has no better alternative to templates
      5. This is true because non of the features of c++ are contained in c

    15. Re:Objects... by oiron · · Score: 1

      C++ can be faster than C... This is an old one, which proves the point...

      Remember, C++ is not just OO - that's one of the paradigms it supports, but not the only one.

    16. Re:Objects... by chocapix · · Score: 1

      templates [...] don't carry any runtime speed penalty

      Unless they cause the code to spill out of the instruction cache. Or unless they cause the entire working set to spill out of a handheld device's 4 MB of RAM.

      That's because different instances don't share their (compiled) code, and yes, that's a side-effect of templates. But, if you remove the templates by hand-instantiating them, you'd still have the same issue of code duplication.

      My point was that the templates themselves don't cause any slowdown (unlike, say, virtual functions), not that they always lead to the fastest code.

    17. Re:Objects... by Cyberax · · Score: 1

      "As I understand it, C++ compilers implement templates by making a copy of the object code for each type for which the template code is instantiated. Once you instantiate a template numerous times, your binary gets bigger, and it slows down because it has to keep loading data from storage instead of caching it in RAM."

      Not really. GCC reuses the same code from different instantiations. And of course, if you follow ODR then you'll have at most 1 template instantiation for each combination of type parameters.

      Also, libstdc++ is a beast. But so is glibc. If you compile for embedded devices - don't use it. It's certainly possible to make 'Hello world' to be about 1kb in C++.

    18. Re:Objects... by mpsmps · · Score: 1
      If you learn about C++ before you try to pass yourself off as an authority, you won't spout easily refutable misconceptions.

      C++ only becomes slower if you use certain features that have a performance impact.

      And virtually every useful feature of C++ that is not in its common subset with C is one of those.

      What is the performance overhead of namespaces, typesafe object creation, references, function and operator overloading, use of const ints for array sizes (more efficient than C), non-virtual methods, STL (the word "virtual" does not appear anywhere in the STL sources), support for wide characters, protected/private modifiers, etc.? While features like templates and metaprogramming have performance tradeoffs, skilled programmers can use them to make programs that are faster than the corresponding C programs.

      Example: if you use exceptions, there is a performance penalty.

      And if you use operator new, you use exceptions.

      Firstly, this whole point is spurious because you can always use nothrow new, which was put in the standard precisely for people who want exception-free code.

      Secondly, the (exception-throwing version of) new may well be faster at error handling than malloc. For the very many programs that only catch allocation errors at the top level, setting up the exception handler is just negligible part of startup costs and far faster than checking the return value from each malloc for zero.

      Even if you are doing fine-grained error checking around each call to new, it's not clear whether setting up the exception handler is slower than checking for a null-returrn. It is certainly far less error-prone.

      The main slow downs you will see in your average C++ program, over the corresponding C, is the use of the string class

      That and <iostream>. Once, I tried programming in GNU C++ for a system with an ARM7 CPU and 288 KiB of RAM. Even after applying all the link-time space optimizations I could find, Hello World statically linked against GNU libstdc++'s <iostream> still took 180 KiB. (Dynamic linking wouldn't even have worked because libstdc++.so itself is bigger than RAM.)

      Many C++ programmers use printf instead of iostream. You're perfectly free to use whichever you want, depending whether you are more concerned with code size/performance or type-safety/extensibility.

      Note that C++0x has features specifically designed to support a typesafe printf, which will completely own the very type-unsafe C version.

      Furthermore, C++ templates allow code re-use with exactly 0 performance loss

      As I understand it, C++ compilers implement templates by making a copy of the object code for each type for which the template code is instantiated. Once you instantiate a template numerous times, your binary gets bigger, and it slows down because it has to keep loading data from storage instead of caching it in RAM. This hurts especially on handheld platforms such as the Nintendo DS, which has only 4 MiB of RAM.

      I agree that Nintendo DS programmers should limit their use of templates. Not sure why the many programs which are not targeted at the Nintendo DS (Even the DSi has 4 times as much memory) shouldn't be able to generate the far-faster code made possible by template programming (See the "Was it Worth It?" section here).

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      This is true but only

    19. Re:Objects... by Anonymous Coward · · Score: 0

      A C coder who needs to so sort various things would write two routines. One for sorting integers, another for pointers, and then manage different cases using those.
      A C++ coder would write a single template which would do both. And more. With inlined comparators! Yeah!

      More efficient? Well.. that depends. Do you really value that final 30% of brute cycle-counted sorting performance over what 50 different specializations does to code cache?

    20. Re:Objects... by Anonymous Coward · · Score: 0

      Example: if you use exceptions, there is a performance penalty.

      And if you use operator new, you use exceptions.

      Not if you use nothrow. Eg.:
      obj *p = new(std::nothrow) obj;

    21. Re:Objects... by shutdown+-p+now · · Score: 1

      As GP rightly noted, unless you use specific C++ features (exception, virtual), you get opcode-for-opcode identical code from C++ compared to C. Unless your microcontroller uses Tarot cards to determine the original language in which that MOV was written, I don't see how it's possible.

      As a side note, I've seen drivers written in C++. Worked great.

    22. Re:Objects... by tepples · · Score: 1

      Not if you use nothrow. Eg.:
      obj *p = new(std::nothrow) obj;

      Does the standard library use new(std::nothrow), or does it use regular new?

    23. Re:Objects... by shutdown+-p+now · · Score: 1

      That's not the fault of the feature itself, but of people using it incorrectly (at least in a particular environment).

      It is still quite possible to retain full control over template instantiation by splitting template into header & implementation files (with header only containing function declarations and not definitions, and implementation containing their definitions), using extern template in the header for all specializations that you need, and using explicit instantiations in the implementation file for those same specializations. That way, any attempt to implicitly specialize the template will fail with a linker error will fail due to missing function bodies - and you still retain the convenience of code reuse, even though it's more explicit now.

    24. Re:Objects... by thoughtsatthemoment · · Score: 1

      unless you use specific C++ features (exception, virtual)

      Those are actually the reason I use C++ (along with the smart pointer which is convenient.). Otherwise, unless you are into templates, why not just use plain C? Now I think it makes a lot of sense to say the best subset of C++ is C.

    25. Re:Objects... by shutdown+-p+now · · Score: 1

      Those are actually the reason I use C++ (along with the smart pointer which is convenient.). Otherwise, unless you are into templates, why not just use plain C?

      The single biggest reason to use C++ is actually for RAII - in vanilla C, typical resource cleanup code is either a mess of gotos, or some creative macros that expand to gotos (and which are specific to a particular project in every case). In C++, you can easily say "allocate this, and here's how you free it if this scope is left by any means". Contrary to popular belief, it's not only useful with exceptions, as it works with any flow transfer mechanism - e.g. return or break or even goto.

      Templates are another huge reason, because they bring code reuse to the whole new level. Again, you don't even have to code OO-style to leverage them - you could have PODs and global functions, but still reap all the benefits. And they can be faster than alternatives, too, due to aggressive inlining - compare the performance of qsort vs std::sort in a typical implementation.

      With C++0x, lambdas are another big reason, which ties in with both points above - you use them as functors for templated algorithms, but you can also implement a very concise scope guard with them.

      Getting to minor things, namespaces are handy to have around, and function and operator overloading is convenient at times.

      Now I think it makes a lot of sense to say the best subset of C++ is C.

      And the best subset of C is actually Modula-2 :)

    26. Re:Objects... by Anonymous Coward · · Score: 0

      The standard library can use whatever allocator you want it to use. I often use a deterministic allocator I wrote myself when programming real-time systems.

    27. Re:Objects... by discord5 · · Score: 1

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      On a limited (resource wise, that is) ARM board you don't really have a choice. Well you do, right up to the point where you hit the limits of the hardware.

      Avoiding C++ exceptions is practically impossible if you want to play nice with memory. For example, C has malloc() which is supposed to return NULL if allocation fails for some reason. In C++ operator new throws std::bad_alloc (or at least it should, unless your compiler is ancient). The C program should be able to terminate gracefully, while the C++ program cannot without a catch statement by default.

      There are ways around that though, such as setting a new_handler or using std::nothrow when constructing a new object. eg.

      Foo *bar = new (std::nothrow) Foo();
      if (bar == 0) {
      // allocation failure, handle gracefully
      }

      But the thing is that the moment the memory for Foo is allocated, the constructor itself can do whatever it pleases and the gloves come off. So if the constructor contains a new statement that allocates some more memory, you're right back where you started, unless you called that one with std::nothrow as well, which is something that's not always under your control (eg. 3rd party library).

      C++ templates allow code re-use with exactly 0 performance loss

      Performance? Sure. Binary size on the other hand is a whole other thing. On a limited platform you have little option but ignore templates, which I agree is a shame because you can do some damn convenient things that way. Sadly, this also means that STL is a no go most of the time, which is a sad thing, since now I'm back to writing my own linked lists. "Hey, I could write a template for ... Oh wait..."

      Anyway, I don't want to start the whole C vs C++ thing since a debate like that is pointless and out of fashion (Isn't it java vs ruby these days? I thought the word of the decade was "scalability"). My personal opinion on it is that if I'm working on an embedded system with little resources, I'd rather not have to fight against how the C++ compiler does things for a few kilobytes of extra room and just pick C. On a regular PC you're most likely right, although I do notice a lot of other languages there. Most dominantly C# and objective C on their respective platforms.

    28. Re:Objects... by thoughtsatthemoment · · Score: 1

      And the best subset of C is actually Modula-2 :)

      Are you implying you agreed with what I said about the best subset of C++? Unfortunately I can't see the relevance of Modula-2. Wikipedia says that:

      Modula-2 is a computer programming language designed and developed between 1977 and 1980 by Niklaus Wirth at ETH Zurich as a revision of Pascal

      So not only was it late and it was also derived from PASCAL.

      I agree that scope based memory management in C++ is nice, but I can live without it and sometimes I want to turn it off. You are right about gotos and related macros for memory management in C. I've done that a lot and believe it or not, I'd say my recent C code is the best code I've ever written.

      As to use templates as the primary paradigm in a code base, I can see that's what many people are jumping into now. All I can say is good luck and let's talk in 10 years.

    29. Re:Objects... by shutdown+-p+now · · Score: 1

      Are you implying you agreed with what I said about the best subset of C++?

      No, not really. Unless you're significantly resource-constrained (embedded development etc), there's no reason not to use virtual functions, exceptions etc.

      Unfortunately I can't see the relevance of Modula-2.

      It was more of a joke - Modula-2 has all the features of a system programming language that C does, but in a much more readable and uniform syntax and with fewer kludges.

      As a side note, C isn't quite a subset of C++, either - there are differences between the two. It is more correct to speak of a common subset of both C and C++.

      I agree that scope based memory management in C++ is nice

      It's much more than memory management - it's general-purpose resource management. It also lets you ensure that OS handles are cleanly closed, for example, and generally any resources you may acquire from OS or a third-party library are timely released.

      As to use templates as the primary paradigm in a code base, I can see that's what many people are jumping into now. All I can say is good luck and let's talk in 10 years.

      Many people have been jumping into it about 10 years ago, when STL became popular and Boost got rolling, and compilers have started to get decent support for advanced template features. Today, it's a mature and mainstream paradigm. This isn't to say that it's universally popular - there are C++ coding guidelines that frown upon heavy (or any) use of templates - but those people who use it have been doing so for a long time now. So if you want to talk in 10 years after "jumping into it", today would be about time :)

    30. Re:Objects... by thoughtsatthemoment · · Score: 1

      I've seen code bases with heave template use before, like Anti-grain Geometry (which did a great job but also gives me a headache reading it). But all them are algorithms centric. Now I see people starting to use templates heavily to replace what was previously done with the OO paradigm of C++. Is there such a open source code base out there? I'd be interested to study it.

    31. Re:Objects... by shutdown+-p+now · · Score: 1

      Now I see people starting to use templates heavily to replace what was previously done with the OO paradigm of C++. Is there such a open source code base out there?

      Well, it's not entirely clear what you mean, since templates are strictly orthogonal to OO, and you can't really meaningfully use one to replace the other - not any more so than you can use OO to replace, say, structured programming or FP.

      Of course, you can "replace" one with another in a sense that you can start ignoring OO principles once you get into templates - is that what you mean? Can you clarify, preferably with an example of an API or library that did the "replacement" in the meaning you put into it?

      That said, Boost is likely the biggest open source C++ code base with heavy use of templates for all kinds of things.

    32. Re:Objects... by Hortensia+Patel · · Score: 1

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      A few years ago I would have agreed with you, but these days I'm not so sure. Even if you would have stayed away from templates, virtuals, exceptions, RTTI and other features that obviously impact size/speed, I can think of several possible reasons to stay in C:

      1. C is the lingua franca of languages; if you write a module in C, pretty much everything else can call it without too much effort. A C++ API, on the other hand, can't easily be called from anything except C++ (and preferably C++ built with the same compiler and options). Yes, you can hide your C++ implementation behind a C interface, but that's not free.

      2. C++ tooling is improving (LLVM's Clang in particular looks very promising) but basic text-processing tools work a lot better for a language without overloads etc. Think grep, ctags and the like.

      3. C++ is a huge language, and people tend to settle into their own subsets and idioms to make it manageable. For a solo project that's fine. For a big group project, especially one without a recognized benevolent dictator, it's a recipe for pain.

    33. Re:Objects... by thoughtsatthemoment · · Score: 1

      I meant how you do polymorphism, especially for application development. Many code bases just use templates for smart pointers or containers, but using parametric polymorphism as the primary mechanism for constructing objects is quite different. That's why I am interested to know such a code base.

    34. Re:Objects... by Anonymous Coward · · Score: 0

      Generally when I sort stuff it falls on two categories: it either needs to be insanely fast or it just needs to scale.

      For the first case whatever C++ offers isn't good enough. And for the latter case C's qsort is fine, although a little cumbersome to use, so personally I like to abuse defines:

      shellsort_for(i, j, sizeof a/sizeof *a) if (a[i]a[j]) swap(a[i], a[j]);

      (tableless O(n(log n)(log n)) implementation for shellsort_for is left as an exercise ;)

    35. Re:Objects... by shutdown+-p+now · · Score: 1

      Do you mean using templated code with implied type traits ("concepts") rather than type hierarchies? I.e., instead of:

      class list { ... };
      class array_list : public list { ... };
      class linked_list : public list { ... }
       
      void generic_algorithm(list& i) { ... }

      having:

      class array_list { ... };
      class linked_list { ... };
       
      template<class List>
      void generic_algorithm(List& list);

      ?

      The main reason why it quickly became popular is because the former style does runtime dispatch, which is rarely needed in practice. In other words, it's much more common to be dealing with an object of some unknown specific type, where that type is ultimately (i.e. if tracked through the entire call chain) known at compile-time, than it is to deal with types that are genuinely different at runtime. The latter typically arise in various modeling scenarios (which is precisely why the OO-style implementation of subtype polymorphism first appeared in Simula 67 precisely in this context), which, while common, aren't everything.

      So when either virtual or templates are an option, why prefer templates? For one thing, because they give you more options. If you have Base* x, there's no way for you to generically create a new object of the same type as the most derived type of *x, unless it provides some virtual method to obtain a factory - and all that has to be hand-coded. With templates, you can do T() or new T() with impunity. Templates also enable a form of multiple dispatch (through function overloading), while virtual methods are restricted to single-dispatch - and there are quite a few scenarios in which multiple dispatch is superior.

      Then also there's the issue of performance. If the public API for your library involves virtual-based interface classes, you force that virtualness on your clients, and they have to pay that price with no way to opt-out, in exchange for a feature (true runtime type resolution) that they likely aren't even using. When you use templates, the choice is squarely in client's hands - he can still come up with his own class/interface hierarchy with virtual methods if he wants, and only specialize the templates you provide for the interface class, rather than for all its implementations. But if he needs raw performance and doesn't care about code size bloat, he can have it.

      Getting back to semantics and limitations of virtual - in truth, there doesn't have to be the difference. There's no reason why runtime lookup & dispatch cannot be made to cover all ground that templates cover. Indeed, in most FP languages out there - OCaml, for example, and also Haskell - polymorphic functions don't have different code instantiations for different argument types, but are in fact implemented with mechanisms very reminiscent of C++ vtables. That dichotomy is strictly an artifact of C++ as a language, and that is there because of the "don't pay for what you don't use" philosophy, to which templates also adhere.

    36. Re:Objects... by thoughtsatthemoment · · Score: 1

      I think I know the theory, but I am more interested in practice. I've used virtual functions extensively to build an application, and it was a success and that convinced it was a viable paradigm. Now I'd like to see an example that uses templates (without virtual functions) and builds a non-trivial application.

    37. Re:Objects... by shutdown+-p+now · · Score: 1

      I think I know the theory, but I am more interested in practice. I've used virtual functions extensively to build an application, and it was a success and that convinced it was a viable paradigm.

      All I can say is that, in my 8 years of experience of writing C++ code in production, it had similarly worked for me. Since it was all either in-house or proprietary shrink-wrapped software, I can't give you a link to the code...

      In practice, I found that it's best to use whichever one is the most convenient tool for the task at hand, so code I write has both parametric polymorphism via templates - where that makes sense - and also conventional Simula-style virtual dispatch. The codebase I'm working on my current job - which is Visual Studio - has both in abundance, though there's probably more virtual dispatch in it due to heavy use of COM.

    38. Re:Objects... by Junta · · Score: 1

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      One reason I can think of is incurring the libstdc++ dependency in an embedded or otherwise size critical context. Sometimes you still have precious little OS storage, and your convenience/cost compromises might land shy of C++. This is a matter of design tradeoff, some contexts demand nothing more than assembler, or a libc smaller than glibc, and some 'embedded' can do nearly whatever the hell it wants.

      --
      XML is like violence. If it doesn't solve the problem, use more.
    39. Re:Objects... by thoughtsatthemoment · · Score: 1

      Well, mixing the two is what most people do, for one reason or another.

      I was part of the Visual Studio team many years ago (build 41 still?). Yeah I do remember how heave that is.

    40. Re:Objects... by Anonymous Coward · · Score: 0

      Example: if you use exceptions, there is a performance penalty.

      And if you use operator new, you use exceptions.

      Actually there is no performance penalty for using exceptions in most C++ implementations unless an exception is actually thrown. This might imply that care needs to be taken in e.g. embedded environments but otherwise the benefit is that if you use exceptions properly you have cleaner, more robust, mainline code that is not scattered with error handling and the cost only comes when an exception is thrown. And if exceptions are being used appropriately, throws should be relatively rare. Moreover, I wouldn't mind betting that, because the code can more easily be written to focus on the non-error case, it is more likely to be structured in a way that is amenable to optimisation than C-style code that does error handling properly.

    41. Re:Objects... by Ritchie70 · · Score: 1

      I would hope that a C coder who needs to sort various things would write two routines, one for COMPARING integers, another for COMPARING pointers, use qsort() and get on with their day.

      I don't know what a C++ coder would do, perhaps some sort of thing with templates and sorted collections. I assume that a template also needs to be told how to compare objects at some point - even if it's just the implementation of operator() and operator==().

      A person who would write his (or her) own sort function should, in most cases, be ridiculed, beaten and fired.

      (Yes, I know, there are exceptions to this rule. Rules always have exceptions.)

      --
      The preferred solution is to not have a problem.
    42. Re:Objects... by Ritchie70 · · Score: 1

      That was operator-less-than, not operator(). Slashdot ate my less-than!

      --
      The preferred solution is to not have a problem.
    43. Re:Objects... by ultranova · · Score: 2, Insightful

      C++ can be faster than C...

      And Java can be faster than C++, if you write sufficiently good Java code and sufficiently bad C++ code. That you manage to find a single instance of this is true doesn't prove anything.

      --

      Forget magic. Any technology distinguishable from divine power is insufficiently advanced.

    44. Re:Objects... by ultranova · · Score: 2, Insightful

      No, C is exactly as fast as C++. C++ only becomes slower if you use certain features that have a performance impact.

      Which would be every feature that isn't C with added syntactic sugar.

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      Yes, there is: it's a simple language with very predictable behaviour, compiles fast, and the resulting binary can be trivially interfaced with pretty much every other language. There's no good reason to use C++: you don't get the benefits of managed environments and the real encapsulation they offer, yet it's almost impossible to figure out what code using templates and operator overloading is actually doing.

      Use C for performance and control, or use Java, Python and friends for a real high-level language. C++ gets you the worst of both worlds. Let's just let the damn thing die already.

      --

      Forget magic. Any technology distinguishable from divine power is insufficiently advanced.

    45. Re:Objects... by ultranova · · Score: 1

      not any more so than you can use OO to replace, say, structured programming

      Just make every block of code an object. In fact, make every program statement an object and store them in a linked list or vector. Functions would simply be such lists stored in variables, statements like "if" and "while" would get a list as their arguments, and naturally you could easily alter or construct these lists at runtime. These "function objects" could also have their local variables, with settable initial values, some bound to passed arguments, some shared between invocations. They could have locks to control concurrent access; in fact thread creation would be handled by "concurrent" command, which would take a function object as a parameter, along its parameters and the variable to use to store the return value.

      Basically, get rid of old-style structural programming and use function objects for everything - it's the wave of the future :).

      --

      Forget magic. Any technology distinguishable from divine power is insufficiently advanced.

    46. Re:Objects... by Anonymous Coward · · Score: 0

      Your conclusions are basically correct. From a performance standpoint, whether C or C++ is used make less of a difference than the actual code written, or generated by the compiler. A badly performing C program will be beaten by a better C++ program and vice versa. From that standpoint, writing fast code in any language will largely depend on the algorithms used along with good knowledge on how to write performant code in that language, and not so much on the language used.

      However some of your examples don't really illustrate that point, even if they are meant to. Here are some examples where I feel your misunderstandings are particularly egregious.

      Example: if you use exceptions, there is a performance penalty. If you don't, you don't get the performance penalty.

      Bad example. A good implementation of exceptions will have try cost nothing, and throw, which is an infrequent operation to begin with, would be O(log n) where N is the number of catch blocks. Pretty good if you ask me.

      the extra indirect function calls due to virtual functions (which causes a branch misprediction and hence a pipeline flush on modern cpus, costing you a bunch of clock cycles).

      Any decent C code will have loads of function pointers anyway, creating the same problem. If anything C++ templates make this better by allowing the implementation of generics without requiring indirection.

      Furthermore, C++ templates allow code re-use with exactly 0 performance loss

      Incorrect. Increased code size can lead to worse performance. Templates increase code size. Therefore, the cost, while often low, is not zero. Sometimes it can be substantial.

    47. Re:Objects... by tepples · · Score: 1

      Actually there is no performance penalty for using exceptions in most C++ implementations unless an exception is actually thrown.

      I guess exceptions aren't as heavy as I thought. I once tried C++ on a handheld platform with 288 KiB of RAM; a single throw added 64 KiB to the executable. But the market has since moved on from that platform to one with 4 MiB of RAM.

    48. Re:Objects... by tepples · · Score: 1

      The standard library can use whatever allocator you want it to use.

      True, but any allocator that acts like new(std::nothrow) apparently leads to undefined behavior.

    49. Re:Objects... by Anonymous Coward · · Score: 0

      That is not encapsulation, that is stupidity.

      The same result can be achieved doing typedef struct gzFile_s *gzFile; which I hope is what they actually use.

      Doing that you can use the same header for the library and the programs using it - and save yourself a lot of casts.

    50. Re:Objects... by Anonymous Coward · · Score: 0

      "Parametric polymorphism" (i.e., templates) isn't the only way to achieve polymorphic design. There is also "static" polymorphism (using CRTP, also templates) which is much more like runtime polymorphism.

      Boost uses CRTP in several places. As for anywhere else in the OSS world, I wouldn't look too heavily. I think you will notice that nearly all C++ experts are routinely employed by some closed off company.

    51. Re:Objects... by shutdown+-p+now · · Score: 1

      In fact, make every program statement an object and store them in a linked list or vector. Functions would simply be such lists stored in variables, statements like "if" and "while" would get a list as their arguments, and naturally you could easily alter or construct these lists at runtime.

      Yes, I love Lisp, too. ~

    52. Re:Objects... by thoughtsatthemoment · · Score: 1

      Were you talking about your implementation of Javascript?

    53. Re:Objects... by JulianoR · · Score: 1

      The main slow downs you will see in your average C++ program, over the corresponding C, is the use of the string class as opposed to the nasty but fast strcpy and friends,[...]

      I cannot agree with this. I have seen, more than once, very noticeable performance improvements in my applications when migrating to C++ strings (after migrating to C++). The main reasons are that (1) the string length is directly stored in the object and available in O(1) time (while strlen(), strcat() and strdup() have to walk over the string, so they are O(n)); (2) most good implementations of std::string use copy-on-write behind the scenes, and are generally very well optimized (since almost all applications use strings, library designers tend to focus on this class); and (3) std::string may (and most implementations do) use better and more efficient ways to allocate and reallocate memory (like using memory pools).

    54. Re:Objects... by Anonymous Coward · · Score: 0

      That was a simplified example that delibarately ignored libraries. Pretend that it's something else that doesn't exist in common libraries.

      The point is that a good interface for pointer sorting would be like qsort as it's essentially the same thing for all pointers except for the comparator function. But integers are quite different. They may be of different size from pointers, their comparator function is known and there exist algorithms that manage without comparisons at all. While you can do it the qsort way, it's pretty inefficient.

      Now, with templates way you'd get a new instance of the algorithm for not only those two wildly different cases but also for each different pointer type, which doesn't make much sense.

    55. Re:Objects... by Anonymous Coward · · Score: 0

      Only if you silently return 0 in allocate(). Which is fairly bone-headed, to be honest. You can see how EA created their own OOM-aware nothrow allocators in their STL implementation.

    56. Re:Objects... by js_sebastian · · Score: 1

      Frankly, there is no valid reason for starting a new program in C in this day and age.

      Yes, there is: it's a simple language with very predictable behaviour, compiles fast, and the resulting binary can be trivially interfaced with pretty much every other language. There's no good reason to use C++: you don't get the benefits of managed environments and the real encapsulation they offer, yet it's almost impossible to figure out what code using templates and operator overloading is actually doing.

      Use C for performance and control, or use Java, Python and friends for a real high-level language. C++ gets you the worst of both worlds. Let's just let the damn thing die already.

      I personally use python 90% of the time (when performance does not matter). And when it does, I use C++, which performs just as well as C and gives me a lot of useful features and the convenience of the STL, resulting in better code than I would write in C.

      Honestly, when performance is the main goal Java is not that attractive, and it's not just the more or less constant-factor slowdown due to the interpretation (or JIT, which is not free either) and the extra indirections and checks. The biggest issue is often memory usage. Garbage collection can lead to non deterministic delays and unpredictably high memory usage (up to 10x the actually used memory in some unfortunate corner cases).

      That much said, I'm not bashing java or managed languages. Java is awesome in my opinion. If I had to write a huge enterprise application with a big team of programmers, I would use Java. But for my line of work it just doesn't have the right trade offs.

    57. Re:Objects... by ultranova · · Score: 1

      I personally use python 90% of the time (when performance does not matter). And when it does, I use C++, which performs just as well as C and gives me a lot of useful features and the convenience of the STL, resulting in better code than I would write in C.

      Oh, C++ does lead to potentially very neat code, sure... the problem is that it's impossible to figure out what it's doing. I learned C by reverse engineering Nethack, with no prior experience on anything but good old line-number BASIC; on the other hand, I tried to figure out what a piece of C++ code was doing, and after 10 layers of indirection just gave up (can't remember the project, sorry).

      C++ forces you to worry about low-level details, yet makes it easy to hide those very same details under operator overloading and templates. That's fine if you're working on a project alone, or can ask whoever wrote the code; but if neither of these is true, and you can't even trust a single assignment operation to not behave as expected...

      Honestly, when performance is the main goal Java is not that attractive,

      Thus the "C for performance, Java for high-level language" paradigm :).

      However, I wonder if Java programs wouldn't actually be faster than C in many uses, mainly due to JIT. Take, for example, modern games: the heavy lifting part of 3D graphics is done by the graphics card, and most of what's left is running various scripts. In C/C++ these scripts are interpreted, while in Java - and other JITted languages - you can let the JIT compile them. Java is not really optimal for this purpose, but something like Python or Lisp could easily be.

      --

      Forget magic. Any technology distinguishable from divine power is insufficiently advanced.

    58. Re:Objects... by js_sebastian · · Score: 1

      Honestly, when performance is the main goal Java is not that attractive,

      Thus the "C for performance, Java for high-level language" paradigm :).

      However, I wonder if Java programs wouldn't actually be faster than C in many uses, mainly due to JIT. Take, for example, modern games: the heavy lifting part of 3D graphics is done by the graphics card, and most of what's left is running various scripts. In C/C++ these scripts are interpreted, while in Java - and other JITted languages - you can let the JIT compile them. Java is not really optimal for this purpose, but something like Python or Lisp could easily be.

      Interestingly, the servers of eve online, which i think is still the mmorpg with the largest number of players on a single server in the world, run stackless python, on top of a custom networking component written in C (or was it C++? ehe, i don't remember).

      Unfortunately however the vanilla python most of us are using (cpython) does not excel at concurrency, and if the powers that be keep pushing backwards-incompatible language changes instead of improving the runtime and libraries, the situation is not going to improve so fast.

    59. Re:Objects... by Anonymous Coward · · Score: 0

      And if you use operator new, you use exceptions.

      That there is a performance overhead for exceptions is mostly a myth. The significant expense only occurs when a try frame is set up, and the additional code of any catches to resolve the thrown exceptions (both of which would be necessary if error handling is to exist within the program in the first place). Exception handling is a specification that doesn't define the implementation, and compiler manufacturers are allowed to use different approaches as long as they meet the standard (the two most common approaches, the "code" and "table" implementations, are significantly different and have different performance trade offs). If you are in a situation where you don't want error handling, then there is nothing keeping you from making an operator new that doesn't throw exceptions either, so even in that case there is no performance penalty for C++. In fact, with the ability to overload operator new C++ can easily be made faster than C with custom allocation strategies specialized for some given platform. Similar code in C would require a modification to otherwise generic code or requiring the C code to have been written for that possibility in advance (for example, some macro expansion to allocating memory from a pool rather than using malloc, etc.)

      As I understand it, C++ compilers implement templates by making a copy of the object code for each type for which the template code is instantiated.

      You understand wrong. Some compilers do that; others don't. If the generated code ends up being equivalent instructions, a competently written compiler can eliminate the additional code, just as if the programmer had written the common code in C with void pointers.

      Of course, not all C++ compilers do this (just like not all of them use the same exception strategy), but many do, and a defect in one particular implementation isn't a legitimate complaint against the language.

  3. Great - Time to hold off upgrading Compiz by christoofar · · Score: 1

    The language and dependency changes aside, how much do you want to bet there will be problems in every package distro?

    After 2 and a half years of getting Compiz sorted in SuSE, RH, Slackware so you have a 50% or better chance of it working out of the box when you install a distro, not having to dig through massive tweaking to get it operating... I'm expecting a step or two backwards in the "installability" department for a while.

    1. Re:Great - Time to hold off upgrading Compiz by drinkypoo · · Score: 1

      After 2 and a half years of getting Compiz sorted in SuSE, RH, Slackware so you have a 50% or better chance of it working out of the box when you install a distro, not having to dig through massive tweaking to get it operating... I'm expecting a step or two backwards in the "installability" department for a while.

      Nobody should be putting Compiz 0.9 into a shipping distribution. Hopefully by the time 0.10 comes out they'll have it unfucked again.
      Fedora might do it, of course. But I don't see it until some point releases have gone by.

      --
      "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
  4. Re:favorite way by uberchicken · · Score: 2, Insightful

    -1, linux zealotry bordering on FUD

  5. Summary Fail by drinkypoo · · Score: 5, Interesting

    The relevant words from the announcement are "complete rewrite". Or in simpler terms for the users, you do not want to run this until it reaches 0.10 (also as per the article.) This is a development and not stable release. (Sure would be nice if they would go 1.0 instead of .10 if it's going to be a stable release...)

    Here's the stuff from the announcement interesting to users:

    Rendering framework split into the composite and opengl plugins, the former
        making compiz a compositing window manager and the latter performing that
        compositing using OpenGL. Such a split will allow new rendering plugins such
        as XRender and Clutter to be developed as well as for compiz to run as a
        non-compositing window manager

    Added support to drag windows to edges and have them fill the adjacent side of
        the screen

    * Added support for automatic wallpaper rotation
    * Added edge support to grid plugin so windows can easily be resized by dragging
        to an edge or corner

    Everything else is of interest only to developers...

    --
    "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
    1. Re:Summary Fail by rawler · · Score: 1

      Sure would be nice if they would go 1.0 instead of .10 if it's going to be a stable release...

      1.0 = 100%. When they reach 1.0, there can never ever be any more releases. ;)

    2. Re:Summary Fail by Anonymous Coward · · Score: 1, Funny

      The devs would have to sac up, dig deep and give 110%.

  6. badass by Anonymous Coward · · Score: 0

    I had compiz working great in Ubuntu 8, made using Linux fun and is great for adding the "wooo" factor when demoing it for potential switchers, then i installed Ubuntu 10 and it no longer works :(
    so i no longer show it to anybody as frankly there isnt much of a visual woo factor over other OSs without it,

    and as we know every self-repecting hipster fashionista judges a book by its cover (look at the iphone)
    and in order for Linux to be popular with the mainstream it has to do stuff better, that includes making it look "cool" Compiz is a step there.
    FOSS has to be able to say "look at how slick this looks AND it can do [task here]"

    be proud of your GUI

    1. Re:badass by equex · · Score: 1

      I had everything working perfectly in Ubuntu 8.04 LTS as well. I had 2 Radeon HD 2600's in Crossfire config, with two monitors (big desktop mode in Compiz using ATI prop drivers (yes i actually had it working 100%, even 3D desktop cube over 2 monitors!)) and a TV hooked up. Everything worked perfectly and I was for a few months 100% converted to Linux as primary desktop OS .

      One day, it just stopped working. And I spent hours and hours trying to restore the system to a state where I could boot into X again. I cannot say for sure what happened, but it was right after I one day had to boot into Windows XP again for some reason that it failed. Maybe it was a kernel update in Linux at exactly the same time, I don't know. I did not update the ATI drivers, that much I know. I suspect that somehow either Linux or Windows messes with the Radeon's firmware so the other cannot use it.

      Until this day I haven't been able to restore 100% functionality to Linux's graphics. While using Compiz, all movies will flicker and X doesn't boot unless I unplug the TV. Movies will work properly if I disable Compiz. I've tried a reinstall using Ubuntu 9 but that did not work either. I'm lost. I now use Windows if I suspect i am going to watch something on the TV or monitor that day. Unfortunately, that's very often. So the end result is that I only use Linux if my wife is gone. (Gives me time to be a dev geek!)

      I've spent hours and days trying to get Linux to do what Windows has been doing since basically Win98. I don't care anymore. If I need anything more fancy than a command prompt, I'm booting into Windows.


      /rant, possibly offtopic!

      --
      Can I light a sig ?
  7. Re:favorite way by AnonymousClown · · Score: 2, Insightful

    -1, linux zealotry bordering on FUD

    Nah. He's karma whoring.

    --
    RIP America

    July 4, 1776 - September 11, 2001

  8. Speed by Wowsers · · Score: 1

    Would the coding switch gain any speed increase?

    Since having the enforced change from the ultra fast, ultra stable Beryl to the not very fast Compiz, I have not been very impressed with Compiz. The developers told me they didn't change anything to get the Beryl fork back into Compiz, but the fact on _MY_ system is simple.

    With Beryl I could run whatever effect I wanted and even multiple effects at the same time, and the CPU was barely used, about 98% of the work was offloaded to the graphics card. Now with Compiz if I do something like rotate the cube or some other effect, the CPU ends up doing most of the work, which is ridiculous. Same distro, same graphics card. Obviously something changed.

    Actually looking at the process usage right now, Compiz is using 3.9% of the CPU just doing nothing AND with an upgraded CPU. Under Beryl with a same type of processor but slower processor, the maximum CPU usage was 5% doing whatever effect you wanted. This is not right.

    Enforcing a change from Beryl to Compiz was wrong.

    --
    Take Nobody's Word For It.
    1. Re:Speed by christoofar · · Score: 1

      You're not going to see any speed gain from *just* switching to C++ from C. A direct translation of code from C to some other language invariably never accomplishes this. The compilation of Compiz will also be slower if it was just a language change, anyway.***

      *** Unless the authors also did a major refactor and performance enhancement job while they were sifting through the code, which is what I always strive to do when I have to refactor an entire project from scratch, but in a time crunch or to get new features out quickly... might not be able to do.

      I haven't finished RTFA (it's in another tab), but I would have thought if massive performance changes were being made to the code---surely that would be at the forefront of any refactor announcement. Most developers love to parade their performance boosting efforts at release time.

      I would not expect Compiz 0.10 (or 1.0) to be much different than previous releases except for already announced feature-change that's being baked into the new code.

    2. Re:Speed by David+W.+White · · Score: 1

      Wowsers, on the face of things, I would doubt that, since C is by design faster that C++. I guess over time though with a little optimization here and there we might gain speed improvement in Compiz. I used to use Beryl with Knoppix years ago before it became stable. I had to manually configure conf files a couple of time. I changed to Compiz when I switched distros. Compiz used to crash at first but its pretty stable on my system now.

    3. Re:Speed by siride · · Score: 1

      I doubt those things have anything to do with C vs. C++ and have more to do with fallbacks, GL API usage and graphics driver support. Those are the bottlenecks, not the language.

    4. Re:Speed by hazah · · Score: 1

      C, by design is as fast as C++ (or vise versa). If you're talking about what they were designed for, as opposed to how they are used, where are you making this particular distinction? What can be coded in C to run faster than in C++?

  9. Re:favorite way by Anonymous Coward · · Score: 1, Insightful

    Fewer viruses

    True, Linux has a smaller user base/market share, and therefore is less of a target for malicious software.

    Lower cost of ownership

    Debatable, depending on the environment and exact software... but often this is true.

    CLI/scripting system that actually works

    Very, very true. Although PowerShell is quite powerful... but quite different from most shell scripting in the UNIX world.

    Most open source software runs on it

    Depends what you mean by "most" ... "most" open source software runs on many, many platforms... including Windows.

    Drivers for just about any piece of hardware ever built

    'cept all the hardware that only has drivers for Windows.

    No blue screen of death

    True, you get kernel panics instead when hardware fails or you have a rogue driver. The driver issue isn't as significant, however, if you can get away with sticking to the standard in-kernel drivers.

    Not nearly as resource hungry (unless of course you use Compiz :-)

    Again this is totally debatable depending on what you're doing and the software you are running. My Ubuntu system loads up more shit than my Windows 7 system after a fresh boot, it seems. Sometimes the gnome-power-manager is consuming 200 MB of ram all on its own. I still prefer the Ubuntu system, however.

    Penguins way cooler than butterflies

    Definitely true :)

  10. Re:favorite way by ZERO1ZERO · · Score: 5, Interesting

    Compiz doesn't actually use that much system resources, nor strain your hardware either. It uses your gfx card to do all the work, which otherwise would be doing 99% nothing in most other circumstances anyway.

  11. First release of merged branches by NewToNix · · Score: 4, Informative

    This is a first release after the reunification of the Compiz, Compiz++, NOMAD and Compiz Fusion branches. It's unstable, but at least it's good to see all the effort coming under the same roof again.

  12. Re:Sensible choices'r'us by Stumbles · · Score: 2, Insightful
    Oh yes, cmake is really complicated compared to the autotools build stuff. I mean I really enjoy fiddling around with all the *.in, *a4, *.am, ltmain.sh, etc just so I can do; ./configure --help.

    But then I guess you have never tried to use cmake; else you would not have made the ignorant statement about its incomprehensibility. If you have never used autoconf, automake, make, libtool, m4 and friends it would be just as incomprehensible.

    --
    My karma is not a Chameleon.
  13. So.. what is it? by bakuun · · Score: 4, Insightful

    It'd be nice if the summary contained at least a sentence describing what the software actually does.

    1. Re:So.. what is it? by christoofar · · Score: 4, Funny

      It sucks the paint off your house and gives you and your family a permanent orange afro.

    2. Re:So.. what is it? by David+W.+White · · Score: 1

      bacuun - its a window manager with some real cool visual effects like rotating cube, wobbly windows, etc.

    3. Re:So.. what is it? by L4t3r4lu5 · · Score: 3, Informative

      Nothing useful. It's eye candy, like a turbo-charged Aero Glass with 3D effects.

      I use the cube desktop switcher and that's it. For some reason I find the idea of a cube easier to map out my mind when I have several windows open than a chain of 4 desktops.

      --
      Finally had enough. Come see us over at https://soylentnews.org/
    4. Re:So.. what is it? by Anonymous Coward · · Score: 0

      I often find this with articles. However, in this case, the first link is the wiki page for Compiz, and if you did't already know what Compiz is, you probably won't care what language they use anyway.

    5. Re:So.. what is it? by Jahava · · Score: 3, Insightful

      Nothing useful. It's eye candy, like a turbo-charged Aero Glass with 3D effects. I use the cube desktop switcher and that's it. For some reason I find the idea of a cube easier to map out my mind when I have several windows open than a chain of 4 desktops.

      So in other words, you find at least one aspect of it to be very useful. While some window effects are just pure eye-candy (e.g., wobbly windows), many of the added desktop effects provide various degrees of enhanced functionality. This includes:

      • Desktop presentation, be it cube, zooming, or task switching, can be molded and animated to allow the user to better understand and utilize the multiple desktops.
      • Transparency allows information to be literally overlayed, decreasing the intrusiveness of upper-stratum menus and windows.
      • Various effects can tag and categorize different applications or application states (active, inactive, shaded, etc.)
      • The added capabilities allow enhanced usability tools, like magnifiers and mouse location, to be well-integrated and seamless.

      Don't dismiss the suite as just eye-candy; if the main perception of Compiz is that it exists only to make things more fun and prettier, then its overall value to the desktop is understated.

    6. Re:So.. what is it? by Anonymous Coward · · Score: 0

      So you keep your desktop set to the default settings after installation? Not even changing the wallpaper? Because that's nothing useful, just eye candy.

    7. Re:So.. what is it? by LizardKing · · Score: 1

      ... and gives you and your family a permanent orange afro

      What, a Valderama?

    8. Re:So.. what is it? by L4t3r4lu5 · · Score: 1

      I turn the wallpaper off because as you say, it's just eye candy. I prefer a dark grey background. Easier on the eye (it's a light bulb, not a sheet of paper) and not so harsh a contrast as black.

      --
      Finally had enough. Come see us over at https://soylentnews.org/
    9. Re:So.. what is it? by Anonymous Coward · · Score: 0

      Nothing useful. It's eye candy, like a turbo-charged Aero Glass with 3D effects.

      You are wrong, Compiz does have some useful features.

      The two most useful features for me are "inverted screen/windows colors" and the Exposé knockoff.

      Personally, Preffer to "number" my virtual desktops and use META+[1,2,3,4] to access them directy. Also, no stupid cube, wobbling windows and other fugly effects for me thanks a lot (I use Win Classic theme on my XP machine).

      xtracto [anon 'cause I've modded]

    10. Re:So.. what is it? by LynnwoodRooster · · Score: 1

      Sweet - they've created the cure to male pattern baldness! Now if we can just get past the "love child of Buckwheat and Carrot Top" side effect...

      --
      Browsing at +1 - no ACs, I ignore their posts. So refreshing!
    11. Re:So.. what is it? by Anonymous Coward · · Score: 0

      Agree.

    12. Re:So.. what is it? by CosaNostra+Pizza+Inc · · Score: 1

      It is a 3-D accelerated window desktop manager for *nix operating systems. It does for *nix what Aero does for Windows Vista and Windows 7. Basically, it is eye candy for your desktop providing 3d accelerated effects like window shadows, active window switcher effects, open/close window effects, etc. 3D managers usually incurs a performance penalty.

    13. Re:So.. what is it? by Anonymous Coward · · Score: 0

      But you also lose basic functionality, such as the ability to actually name your virtual desktops!

      Lame..

    14. Re:So.. what is it? by some_guy_88 · · Score: 1

      Or the ability to resize a window without just seeing it's border unless you can put up with it lagging and stuttering.

    15. Re:So.. what is it? by SCHecklerX · · Score: 2, Insightful

      Don't forget window grouping and tab groups. I use that a lot. Expose is nice for managing multiple desktops as well.

  14. BS by airjrdn · · Score: 0, Offtopic
    • Fewer viruses - Agreed
    • Lower cost of ownership - BS, too much time is spent hacking up config files to make crap work or work right
    • CLI/scripting system that actually works - BS, anything you can write and make work in Linux, I can in Windows
    • Most open source software runs on it - Show me anything worthwhile that doesn't run in Windows or have a better alternative there
    • Drivers for just about any piece of hardware ever built - BS, that's the primary thing most users have issues with, half baked drivers
    • No blue screen of death - Agreed, but I haven't seen one yet in Win7
    • Not nearly as resource hungry (unless of course you use Compiz :-) - Agreed, but neither was Win98 which is typically how Linux feels
    • Penguins way cooler than butterflies

    Mod me down if you want to, but I've yet to have Windows drop me to a command prompt after an video card driver update, OS update (Ubuntu anyone?) or had to recompile sound drivers after every OS update (Ubuntu on that one too). My file manager will display in a column what date pictures were taken so I can categorize them accordingly, can yours do that? It couldn't the last time I checked.

    1. Re:BS by Anonymous Coward · · Score: 1, Insightful

      * Fewer viruses - Agreed

      Though I still haven't figured out where all these people are catching viruses from. I never saw one once in my Windows days.

      * Lower cost of ownership - BS, too much time is spent hacking up config files to make crap work or work right

      FUD; while it's true that occasionally (very occasionally) one has to edit a config file, most things "just work" these days. I don't have to spend any more time hacking Linux configurations than I used to have to spend messing about with the Windows registry -- and at least Linux config files are documented!

      * CLI/scripting system that actually works - BS, anything you can write and make work in Linux, I can in Windows

      True, though DBUS is pleasanter to use in a script than COM. And I assume you're using VBScript, JScript, PowerShell, or a Windows port of some Unix shell, not the default batch scripting language.

      * Most open source software runs on it - Show me anything worthwhile that doesn't run in Windows or have a better alternative there

      True. The only advantage Linux has here is that it's easier to install open-source software and keep it up to date; the selection is basically the same.

      * Drivers for just about any piece of hardware ever built - BS, that's the primary thing most users have issues with, half baked drivers

      Partially true. I did have trouble with a printer a while back, and NVidia graphics drivers are still a pain if you insist on using the latest version instead of whatever's packaged for your distro. Every other bit of hardware I've tried has just worked first time.

      * Not nearly as resource hungry (unless of course you use Compiz :-) - Agreed, but neither was Win98 which is typically how Linux feels

      You're kidding, right? Please tell me you're kidding. Or blind. Or haven't used Win98 in 10 years, which might explain why you haven't a clue how primitive it was compared to any current OS.

    2. Re:BS by Culture20 · · Score: 4, Insightful

      * Lower cost of ownership - BS, too much time is spent hacking up config files to make crap work or work right

      On Windows, too much time is spent hacking up the registry to make crap work or work right. Just this last Thursday, I had to manually scan the registry to delete every reference to a printer driver that kept killing someone's spooler service... because the spooler service needed to be running to delete the printer normally. If it had been a unix system, I could have just edited a line in a file and been done.

      * CLI/scripting system that actually works - BS, anything you can write and make work in Linux, I can in Windows

      Using cygwin, bash compiled for Windows or DOS, or other scripting applications that are not guaranteed to be on every Windows system.

      * Most open source software runs on it - Show me anything worthwhile that doesn't run in Windows or have a better alternative there

      Well, Linux runs in Windows, so I'd say you've won this argument.

      * Drivers for just about any piece of hardware ever built - BS, that's the primary thing most users have issues with, half baked drivers

      Half-baked drivers in Windows XP, Vista, and 7. That printer driver mentioned above? It was an HP driver written for and installed in Win7 64bit.

      * No blue screen of death - Agreed, but I haven't seen one yet in Win7

      I haven't either, but I have seen a Win7 machine reboot constantly (the equiv of BSOD since Win7 is set to reboot on fail).

      * Not nearly as resource hungry (unless of course you use Compiz :-) - Agreed, but neither was Win98 which is typically how Linux feels

      I still have Win98se running on an old machine for old games. Win98se is actually snappier than modern Linux, which is in turn snappier than WinXP/7. How much window compositing did Win98se do? Firewalling? Multi-user? Even the 1998 version of Linux had multi-user support and ipchains.

      Mod me down if you want to, but I've yet to have Windows drop me to a command prompt after an video card driver update

      I've had it boot up to a BSOD, which looks worse than a command prompt, or a blank screen where I had to remote in or boot up in safe graphics mode.

      [I've yet to have Windows drop me to a command prompt after an] OS update (Ubuntu anyone?)

      I've had it boot up to a BSOD, which looks worse than a command prompt.

      or had to recompile sound drivers after every OS update (Ubuntu on that one too).

      I wish I could. Sometimes vendors take years to get their sound drivers working. Google realtek, imac, and Windows 64 bit.

      My file manager will display in a column what date pictures were taken so I can categorize them accordingly, can yours do that? It couldn't the last time I checked.

      This is the first time that I ever checked. No, it does not, but it could with a little quick editing. Right clicking and selecting properties shows that the Gnome file manager (didn't check KDE) can see the image properties, including "Date Taken", so the information is there. Linux users are probably just better mentally organized, and name their photo directories YYYY_MM_DD

    3. Re:BS by somersault · · Score: 1

      I've not had to edit any config files on Ubuntu since version 8, apart from Apache - which needs exactly the same setup on Windows.

      Evolution doesn't have a decent Windows port (there is a port available, but it crashed on installation and I couldn't be assed trying to diagnose it, just left the user with Outlook).

      Windows "feels" worse than any OS I've ever used, with maybe the exception of Amiga Workbench 1.3.

      I always file my pictures in folders with the date that they were taken in YYYY-MM-DD format, so yes I've been able to do that in both Windows and Linux ever since I started taking photos. I don't get people that leave photos on their camera for weeks (or longer). Plus if anyone else is that disorganised then I'm sure there must be one or two file explorers or photo organisers for Linux that can sort by photo tags.

      --
      which is totally what she said
    4. Re:BS by airjrdn · · Score: 1

      That's my point. When moving photos from the camera to the OS I do maintain that exact directory structure, but in Windows I don't have to check every photo individually for the date taken, it's a column in the file manager.

      No need to try to make Linux users smarter than they think they are though, Windows users and possibly even Mac users can be fairly mentally organized as well.

    5. Re:BS by Hatta · · Score: 1

      in Windows I don't have to check every photo individually for the date taken, it's a column in the file manager.

      ls -lt *.jpg

      If you want to automatically file them into directories based on date you can use --time-style=iso and pipe it into awk or perl and write a quick script you can use every time you do this. You definitely do not have to sort them by date, create a folder for each date, and drag and drop each group of files into its directory.

      You can do the same sort of thing in Powershell I'm sure. This isn't a case where linux is necessarily better than windows, but it is a case where the CLI is definitely better than a GUI.

      --
      Give me Classic Slashdot or give me death!
    6. Re:BS by airjrdn · · Score: 1

      Again, Linux pushing me to a command prompt. The point was that the file managers in Linux can't handle this basic requirement useful to users at any skill level. We can all do things at the command prompt if we can write a little code, but most users want to use the GUI.

    7. Re:BS by Culture20 · · Score: 1

      in Windows I don't have to check every photo individually for the date taken, it's a column in the file manager.

      ls -lt *.jpg

      This isn't what GP was talking about. That's file modification time, not the date the photo was taken (which is data inside the image file, not in the filesystem about the file). The closest you could get with ls would be to re-touch all the timestamps to match the image date data first, then use ls.
      find /image/directory/ -name \*.jpg -exec touch -d `exiftime -tg {} |sed -e 's/Image Generated: //' |sed -e 's/:/-/' |sed -e 's/:/-/'` {} \;
      or something similar. I can't remember if backticks work in -exec.

      Of course, exiftime has sorting built in:
      exiftime -tg -l *.jpg
      But since GP is a Windows user, command line is a tool of the devil.

    8. Re:BS by Hatta · · Score: 1

      Linux defaults to the command line because the command line is better. There's a reason we moved beyond pointing and grunting into symbolic language. Writing a few lines of code is in fact easier than manually copying, renaming, converting, etc dozens of files. And when you're done you get a script you can use the next time such a task comes up.

      If you really really want to use the GUI though, there's no shortage of file managers that will display the date in a column. Konqueror does it by default. So does Dolphin and Krusader. Same with Thunar, Xfe, and emelfm2. In fact, I'm having trouble coming up with a file manager that doesn't display the date. Rox-filer didn't at first, but it was one click to "show extra details".

      --
      Give me Classic Slashdot or give me death!
    9. Re:BS by Anonymous Coward · · Score: 0

      date taken is an information inside EXIF which obviously not visible using plain ls. -t only sort based on modification date. So no, that's not same.

    10. Re:BS by Hatta · · Score: 1

      This isn't what GP was talking about. That's file modification time, not the date the photo was taken (which is data inside the image file, not in the filesystem about the file).

      The filesystem time and the exif time should be the same when they're on the camera. Just pass -p to cp when you copy them over.

      --
      Give me Classic Slashdot or give me death!
    11. Re:BS by siride · · Score: 1

      Linux file managers can read that data just fine and display. Maybe they don't have it by default for whatever reason. I'm sure you can just select the columns you want, such as "picture taken date" and you'll be fine and dandy.

    12. Re:BS by Culture20 · · Score: 2, Insightful

      command line is better. There's a reason we moved beyond pointing and grunting into symbolic language.

      Best description of why to use CLI; it allows for an explosion of thought.

    13. Re:BS by Geeky · · Score: 1

      This isn't what GP was talking about. That's file modification time, not the date the photo was taken (which is data inside the image file, not in the filesystem about the file).

      The filesystem time and the exif time should be the same when they're on the camera. Just pass -p to cp when you copy them over.

      Yes, but when you edit the file (in Photoshop, say), the date taken stays the same and the filesystem timestamp changes.

      It actually annoys me that Windows defaults to showing the exif date taken when it detects a directory of images - I'd much rather see the filesystem datestamp and sort by that, so I can see which I've already edited. I already organise the directory structure by date taken anyway.

      --
      Sigs are so 1990s. No way would I be seen dead with one.
    14. Re:BS by Hatta · · Score: 1

      That's a fair point. But at this stage it seems like we've moved beyond the field where a general purpose file manager is appropriate. There's no point in having a "date taken" column in a utility that many people will never use for photos. If you really need to sort your photos based on this photo specific metadata, there are photo managers for that.

      --
      Give me Classic Slashdot or give me death!
    15. Re:BS by airjrdn · · Score: 1

      Not just date, date picture taken. The last time I checked, which was a year or so ago, it couldn't be done by setting any options, etc. My forum post is probably still at ubuntu. The cmd line is better for some things, but not all. If so, do you ever use a GUI? Think your Mom is going to write that script? For you and I a cmd prompt has it's advantages, but for the vast majority of users, it's useless.

    16. Re:BS by Anonymous Coward · · Score: 0

      The point is you don't have to in linux either - add the date taken column to the filemanger...it only requires one right click and two left clicks...

    17. Re:BS by Anonymous Coward · · Score: 0

      If 'date modified' isn't a column in your Linux-based file manager, then you almost certainly just haven't seen the settings dialog that configures whether or not that column is visible. Rest assured, certainly in KDE and in GNOME, and in many other file managers I've used, the feature is absolutely present.

    18. Re:BS by Junta · · Score: 1

      Lower cost of ownership - BS, too much time is spent hacking up config files to make crap work or work right

      This perception problem is common with perl. You can run a modern linux system fairly naively, but the enthusiasts will make the 'fancy tricks' look like 'the' way of life. There are advanced capabilities that are possible with fancy trickery, but most people would do fine if they ignored those capabilities and just used their system. Same applies to a lot of systems with advanced capabilities, for a simple example look up source engine command parameters for adjusting multiplayer settings. If you naively use those games, you'll likely have no problem, but if you search for cl_updaterate and start reading, you would be given the impression that there are tons and tons of parameters that simply *must* be tweaked for an 'acceptable' experience.

      CLI/scripting system that actually works - BS, anything you can write and make work in Linux, I can in Windows

      There is what is technically in theory possible, and then there is how to do it. If you compare vbscript/cmdscript to bash/(python|perl|etc), the syntax is dramatically better. Now Powershell brings a fair amount of better syntax and has at least decent interactive startup time in Windows 7/28kr2 (before that it was a mess), but in WindowsPE, you are still stuck with cmd/vbscript as your tools. In my opinion, Powershell leans a little more toward perl/python in some ways that make things like bash a touch easier for typical shell scripting.

      Most open source software runs on it - Show me anything worthwhile that doesn't run in Windows or have a better alternative there

      Compiz. Window scaling with title search is incredibly awesome in terms of practical application whereas Aero is strictly just eye-candy. Most applications will run on either platform, but on a typical linux it's 'aptitude install openoffice' rather than trying to find individual websites to host the software.

      Drivers for just about any piece of hardware ever built - BS, that's the primary thing most users have issues with, half baked drivers

      All platforms are subject to crappy drivers from crappy vendors. I had to search all over the damn place about networking on a new Windows 7 going out every couple ours to find out that the manufacturer's driver would go tits up due to segmentation offload (turning it off involved navigating several dialogs graphically, in linux it would just be 'ethtool -K eth0 tso off'). Pick a reputable hardware vendor and you'll get a good driver experience regardless of platform. Pick a sketchy vendor, and your experience is likely to suck regardless of OS.

      --
      XML is like violence. If it doesn't solve the problem, use more.
    19. Re:BS by spongman · · Score: 1

      Linux defaults to the command line because the command line is better.

      better for whose grandma?

    20. Re:BS by jim_v2000 · · Score: 1

      God people....who cares? Sometimes Windows and Linux can be shitty, sometimes they can be great. As a daily user of both OS's, I say that problems occur in both OS's at about the same frequency, and are usually something trivial.

      --
      Don't take life so seriously. No one makes it out alive.
  15. Re:favorite way by Anonymous Coward · · Score: 0

    If you have two servers with weblogic the linux one costs $10.000.000 and the windows one $10.000.500.

    Yeah linux isn't at all that cheap.

  16. Re:favorite way by L4t3r4lu5 · · Score: 1, Insightful

    You forgot a unified update system with updates rarely requiring a system restart.

    --
    Finally had enough. Come see us over at https://soylentnews.org/
  17. Re:favorite way by Anonymous Coward · · Score: 0

    re: viruses / vulnerabilities

    try this distro: http://www.damnvulnerablelinux.org

    an excellent tool for learning.

  18. Re:favorite way by Anonymous Coward · · Score: 0

    However informative your list is not a Windows users list.

  19. Re:favorite way by Rogerborg · · Score: 4, Interesting

    I use a variety of POSIX operating systems 95% of the time, at work through necessity, and at home through choice. And because I use them, rather than despite it, I am compelled to respond.

    Fewer viruses

    And drunken cheerleaders get date raped more than shut-in nerd chicks. Personally, I prefer nerd chicks, and you likely do too, but most people don't. Really, they don't, and there's no use telling them that their opinion is wrong.

    Lower cost of ownership

    If you don't value your time. For the latest of many, many examples down the years, I 'invested' 3 hours this weekend trying to get WiFi with WPA working again after upgrading my wife's box from Ubuntu 9.10 to 10.04. Verdict: the rt73usb driver has (yet again) returned to a state of porkage, so it was (yet again) ndiswrapper and Windows drivers for the eventual win.

    CLI/scripting system that actually works

    Until of course you try and run a script written for fooshell on barshell, i.e. when a distro changes its shell.

    Most open source software runs on it

    Can be made to run on it, given enough time.

    Drivers for just about any piece of hardware ever built

    If you limit "ever" to "older than two years or so". But sure, many of the drivers give the appearance of working tolerably well, for a surprising amount of the time! And when they don't, well, there's ndiswrapper, or we'll-fix-it-in-the-next-release, or you've-got-the-source-compile-a-previous-version-yes-we-know-it-doesn't-build-against-your-kernel-headers-or-gcc-version-fix-it-yourself-you-filthy-M$-shill.

    No blue screen of death

    Ain't seen on one Windows for years.

    Not nearly as resource hungry (unless of course you use Compiz :-)

    Granted. Oh, unless you've got a driver bug, which you almost certainly do if your hardware was designed this millennium. Then see above.

    Penguins way cooler than butterflies

    By that measure, that would mean...

    But the easiest way of making a windows user envious is to use a mac

    ...that.

    This is not the year of Linux on the desktop (or the netbook). I thought we were there with Ubuntu 10.04, but it's actually a regression from 9.10. I'd just recommend 9.10, but that's effectively abandonware now, just like all previous versions of all Linux distros, "LTS" included.

    Again: I'm writing this from Ubuntu 9.10. I've got RHEL5 in that VM over there, SUSE 11 yonder, Solaris in that shell, and even SUA on Windows (tastes a bit like POSIX). I'm happy with POSIX OSen. But I would not recommend them to a Joe Windows user, ever, since I don't want to be their Support Guy from now until there's a distro that actually Just Works.

    --
    If you were blocking sigs, you wouldn't have to read this.
  20. Re:favorite way by KiloByte · · Score: 5, Informative

    In fact, on old systems with a graphics card it is significantly faster than the traditional way of redrawing windows.

    Why? Because:
    1. the gfx card can do part of the work
    2. all windows are already drawn and kept in the graphic card's memory

    --
    The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
  21. Re:favorite way by Anonymous Coward · · Score: 0

    • Drivers for just about any piece of hardware ever built

    Sure, please tell me where is the driver for my cell phone's USB cable on Linux. Hell, I can't even find one for x64 versions of Windows.

  22. Re:Sensible choices'r'us by Anonymous Coward · · Score: 0

    Most build systems are arcane at best.

    Insanely, I think Visual Stuidio's is the best out there (for ease of use)... right up until you start trying to link libraries that have been linked against different version of the runtime.

  23. Re:favorite way by Jurily · · Score: 5, Informative

    No, karma whoring is to post something completely obvious you know will be modded up and not add anything to the discussion. Like this comment.

  24. Re:favorite way by CastrTroy · · Score: 3, Insightful

    Fewer Viruses - While this is technically true, most viruses I've seen installed on users machines are the result of users actively clicking and running an executable on their machine. While not running in root mode by default on Linux helps to prevent some of the damage, I think a virus running as a regular unprivileged user could still cause a lot of damage. This is also ignoring the fact that if the same incompetent users if presented with a message asking them to perform administrator actions for no reason at all would still click on "Yes", even if there should be no reason for them to do so, as long it promises smiley icons.

    Lower cost of Ownership - Last time I went shoppping for a computer, I didn't see any discounts for not having Windows installed from the get go. Either you go with Dell/HP/Lenovo, and they only offer windows, or when the offer Linux, it's the same price, or only a little cheaper, but you get a lot less selection of machines you can get. The other option is to build your own machine from off the shelf components. This is my favourite option, as you can get exactly what you want, but you will end up spending more.

    CLI/Scripting system - Almost nobody except tech geeks cares about this. Also, Powershell on Windows isn't all that bad. It has its pluses and its minuses.

    Most open source software runs on it - Most all of open source that is worth running will run on Windows. Maybe not all of it, but most of the more important stuff. Conversely, almost no closed source software runs on Linux. Which might not matter to you, but if you're trying to get work done, having things like Photoshop, Outlook (hate it but necessary for business), and many other closed source programs, makes a big difference.

    Drivers - Sure you get drivers for all the old stuff. But are you sure that shiny new piece of hardware that just came out last week will run to its full potential. Probably not. And there's also plenty of older hardware that I had that I couldn't run on Linux.

    No Blue Screen - I haven't seen a blue screen on a Windows machine in many years. And when I do, it's usually because of bad RAM, causing something to get corrupted. Blue screens still exist, but they don't happen quite as often as they used to. I imagine most Linux systems would also crash pretty badly when they have bad memory.

    I'm not some Windows Zealot. I use Windows when it makes sense, and I use Linux where it makes sense. But I don't really think that that any of the reasons you mentioned are valid. Especially if you're talking about home desktop use. Which in the case of Compiz, is exactly the kind of people we are talking about.

    --

    Anthropic principle: We see the universe the way it is because if it were different we would not be here to see it.
  25. Re:favorite way by somersault · · Score: 1

    CLI/scripting system that actually works

    Very, very true. Although PowerShell is quite powerful... but quite different from most shell scripting in the UNIX world.

    You really expect any CLI, no matter how awesome, will make Windows users jealous? I definitely think Compiz is one of the few ways to make your average Windows user jealous of Linux, with perhaps your favourite package manager coming next. I remember reading that MS are building an app store for Windows though, so it won't be something to be jealous of for long!

    Of course, trying to make other people jealous of you is pretty pathetic.

    --
    which is totally what she said
  26. Re:favorite way by shipofgold · · Score: 1
    I am really tired of hearing about Linux and it's "Fewer Viruses". The only reason that there are fewer viruses for Linux is that the bad guys have not found a good reason to write a virus for it. Current Linux users tend to be a little more aware of the dangers of installing unknown software, but if Linux should ever gain traction on the desktop of what might be known "a typical windows user", the exact same issues regarding viruses will surface.

    Some of the other points in the parent are BS as well:

    • Lower cost of ownership? -- I have spent hours trying to get a video capture card to work with the BTTV driver....my time should be worth something. In the early days just getting X11 to work on my video card was a couple of days work....that is a lot better now.
    • Drivers for most hardware? -- That BTTV driver never worked with my card...card now enjoys a home in a windows box. Hardware manufacturers should be the ones writing the drivers...not someone who reverse engineers a windows driver. Unfortunately more than a few of the Linux drivers appear to be reverse engineered hacks rather than written from hardware specs.
    • No blue screen of death? -- debug a kernel panic sometime...

    Don't get me wrong, I love Linux and use it daily. A couple of things that should be on the list:

    • Package management -- If I want to know what a particular file is needed for, a linux package manager can tell me....windows is a nightmare in trying to decipher the processes that are running.
    • Automation -- While it can be done, automating something in Windows is a pain in the a--. Most Linux programs come with enough command line options that you can do stuff without the need to go into a GUI....ever try to script a GUI?

    Does the typical windows/mac user care about these? No.

    I am a proud user of Linux, but I fear that the day it goes mainstream, I will need to start looking for something else.

  27. You mean, nothing for you, right? by Seth+Kriticos · · Score: 2, Interesting

    I have to agree that the cube is useless (and I don't use it).

    There are a number of plugins that increase productivity a lot though, namely the scale, desktop wall, expo, app switcher and zoom plugin. Problem is: the default configuration is not designed to be useful, but to be easy.

    While installing new systems, I install the CompizConfig Settings Manager, and then set up the plugins for efficiency: I basically map common window functionality to screen edge/corner clicks with the mouse.

    Base setup is 6 (2x3) desktops. I move between these desktops by clicking one of the edges (depending on which direction I want to go - up/down/left/right) of my screen with the right mouse button.. See the overview (expo) with right click to the top-right edge. Alt-tab/Alt-shift-tab with mouse button clicks to the top left edge (app switcher), and see open window overview with right/left clicks to the bottom-left corner of the screen (scale).

    This (combined with select - emulated middle button pasting) effectively enables me to do all activity you'd normally need mouse+keyboard to do with keyboard only.. and that very fast and instinctively.

    Guess what you wanted to say is: the default configuration could use some tuning. Problem is: though this improves baseline productivity and is very fun when being used to it, it violates the common desktop paradigm that every desktop function has to be an icon, or context menu. In other words, setting it up in a useful manner involves thinking and learning a bit, which most folks seem to avoid by all means. (no offense).

    1. Re:You mean, nothing for you, right? by Seth+Kriticos · · Score: 1

      oops..

      I meant to do mouse+keyboard activity with either mouse or keyboard, but not both at the same time.

    2. Re:You mean, nothing for you, right? by L4t3r4lu5 · · Score: 1

      But my point was that the cube isn't useless for me. I can much more easily remember the faces of a cube than slide position. Plus, being able to move from space 1 to 4 instantly by moving left is super-handy.

      --
      Finally had enough. Come see us over at https://soylentnews.org/
    3. Re:You mean, nothing for you, right? by Seth+Kriticos · · Score: 2, Interesting

      Ah, sorry, wrong wording. Actually, I just wanted to expand your comment. In my experience (and I spent quite some time on it) much of the usefulness of compiz is a matter of configuration.

      So I'd rephrase my leading comment to "the desktop cube is useless to me". But that's what I like about being able to adopt compiz to my bidding. People are different, and I can adopt compiz to my preferences while not bothering you. :)

      People should be aware of how the work and see how they can adopt the tools to make the process more efficient. And in the content of the comment I tried to show a method, well my method of how I did this.

      Context: I'm a horribly lazy person. That's why I spend a lot of time optimizing things. I learned Dvorak SDK and VIM for that reason, and did the same for compiz for exactly the same reason. I admit, the customizations that I did are not really obvious.

    4. Re:You mean, nothing for you, right? by Anonymous Coward · · Score: 0

      Try downloading something like VirtualBox and setting up a few virtual machines. The cube is an exceptional way to navigate between them and the host when they're fullscreened.

  28. Re:favorite way by drinkypoo · · Score: 3, Informative

    Compiz doesn't actually use that much system resources, nor strain your hardware either.

    I have a 3.2GHz tri-core Phenom II system with a GTS 240 (~400MHz, 96 stream processors) and Compiz will easily consume 5% or more if you have a window with continual graphics updates, like a game or a video player. That's a lot of CPU! You can manually disable transforms on that window but that requires a visit to the settings manager that would leave the average user dumbfounded.

    --
    "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
  29. Re:favorite way by mdwh2 · · Score: 1

    But the easiest way of making a windows user envious is to use a mac

    Something that's more closed than Windows and Linux?

    No, we're not envious. You might think that we should be envious, just like the guy who brags about his expensive designer clothes or Iphone, but the rest of us don't actually care.

  30. Re:Sensible choices'r'us by rawler · · Score: 1

    I have used autotools, and they're still incomprehensible.

  31. Re:Sensible choices'r'us by Anonymous Coward · · Score: 0

    Whenever some big project (bullet, opencv, etc) has switched to cmake and says that it is preferred over autotools, it never works. I always just end up using autotools to build it instead because it Just Works (tm).

  32. Re:favorite way by Dog-Cow · · Score: 0, Flamebait

    A Windows user is quite unlikely to care about either Windows or Mac OS X being a "closed" system.

    Of course, you're extremely stupid, so I don't really blame you for missing that point.

  33. Re:favorite way by Hatta · · Score: 1

    Until of course you try and run a script written for fooshell on barshell, i.e. when a distro changes its shell.

    If you were using #!/bin/sh and expecting bash specific code to work, you're doing it wrong. If you want bash, call it by its proper name and it will always work.

    --
    Give me Classic Slashdot or give me death!
  34. Re:The sooner Android replaces KDE, the better by meow27 · · Score: 1

    Gnome and KDE were imperfect Desktop environments so that F/OSS unix could have one. Now that we are getting a good one at long last (Android). Why stick with the old an obselete?



    What can i do in android that i cant do in gnome?
    What can the windows gui do that i cant do in gnome?
    What can the mac gui do that i cant do in gnome?

    Just because an environment is simplistic doesn't mean it sucks. I prefer gnome over kde because it focuses less on eye-candy and more usability.

    I prefer gnome over windows because it doesn't try to compress my programs menu.

    Also who are you to say that android is a perfect environment? Why do they constantly come out with new updates?

    finally android was made for a touchscreen environment, not a point and click one.
  35. Re:Sensible choices'r'us by GreyWolf3000 · · Score: 1

    You actually go through the trouble to reimplement build systems in autotools? That's a lot of work, dude. I'm calling foul here.

    --
    Slashdot: Where people pretend to be twice as smart as they really are by behaving like children.
  36. Re:Enlightment again? by Anonymous Coward · · Score: 0

    Oh, great old one, please tolerate my invasion on your lawn.

    What the hell is your problem with X?

  37. Re:favorite way by Abcd1234 · · Score: 1

    Oh come on... how, exactly, is the Mac platform (no, not the iPad, not the iPhone, the Mac, ie Mac OS X) "more closed than Windows"? At best it's exactly as closed, though I'd argue somewhat less so (thanks to the existence of Darwin, their work on the ObjC gcc backend, Webkit, etc).

  38. Re:Enlightment again? by boxwood · · Score: 0, Flamebait

    The default Ubuntu UI (which includes compiz) is better designed than MacOSX.

    Have you ever used it? I have tried both MacOS X and Ubuntu, and Ubuntu is far more user friendly than MacOS. They just don't have the hype machine that Apple has.

  39. C++ or C+Template? by tepples · · Score: 1

    Classes (not virtual)

    Sugar for functions that take this as their first argument. But as Micropolis showed, these are useful for taking legacy code that uses global or module-scope variables and allowing it to be instantiated multiple times. I'll grant you this one.

    References

    Sugar for pointers.

    You have other problems when your code runs out of memory that often

    Only if you consider running on a microcontroller or a handheld device a "problem". In such a case, running out of memory means the allocator has to purge items from the cache. Then you run into other classes that use new as their factory, for which new might throw for reasons unrelated to memory: TCP connections, file system access, file format parsers, etc.

    which means c sucks too once you find hardware which does not support all functions of the c standard lib?

    You're referring to 8-bit microprocessors, I take it. But there's still a lot of interesting hardware that runs C well but doesn't do so well at virtual and <iostream> of C++.

    as I understand it c has no better alternative to templates

    It appears you're not as much of a fan of C++ as a fan of the subset of C++ including C and templates.

  40. Re:favorite way by Rogerborg · · Score: 1

    CLI/scripting system that actually works

    Until of course you try and run a script written for fooshell on barshell, i.e. when a distro changes its shell.

    If you were using #!/bin/sh and expecting bash specific code to work, you're doing it wrong. If you want bash, call it by its proper name and it will always work.

    Well, sure, if your definition of "actually works" depends on "if you use it right", which is a perfectly reasonable condition.

    But then that means the Windows "CLI/scripting system" also "actually work9s)", doesn't it? Perhaps more so, since (AFAIK) a script that was working won't suddenly assplode when you download a service pack or update.

    Heck, maybe you were agreeing with me. It's hard to tell.

    --
    If you were blocking sigs, you wouldn't have to read this.
  41. Re:favorite way by Anonymous Coward · · Score: 0

    I have a dual core Pentium E5200 with 1 GB of RAM and Compiz takes very little resources. Next to no CPU usage, even with video players and such.

  42. Template misuse by tepples · · Score: 1

    if you remove the templates by hand-instantiating them, you'd still have the same issue of code duplication.

    The difference is that algorithms and containers in C or Java encourage the use of erasure to a higher type (e.g. void * or java.lang.Object). C++ templates can be used this way, but they can also be instantiated once for each T* (by pointer) or even once for each T (by value). I can think of a few things to watch out for when using templates:

    • Templates make compiler error messages hard for the programmer to read.
    • The ability to instantiate templates multiple times tempts the programmer to make unproductive time/space tradeoffs that might be hard for other programmers to find and fix.
    • Template containers that hold objects by value introduce a risk of slicing when used with STL containers.

    So some people aren't big fans of C++ templates because templates are so easy to misuse.

    1. Re:Template misuse by hazah · · Score: 1
      Your "easy to misuse" link sounds more like fear-mongering than anything practical. Almost every answer is in the context of "oh but it doesn't work as advertised", which is actually complete B.S. Either he's not reading the right documentation, or there's another agenda.

      Beyond those fundamental limitations, templates follow the tradition of C++ features of interacting poorly with each other. Templates can't be compiled because they are not code - they are, well, templates from which code can be generated once you have the parameters, and then you can compile it. C++, like C, defines no way to locate the compiled code of a definition given its name. Consequently, template definitions are placed in #include files, and recompiled in each translation unit each time they are instantiated, even if the exact same instantiation is used in N other files.

      Really? Again, what a load of bullshit! Template code works PERFECTLY with all other code! Why? Because instantiated code is just regular C++ code. To top this off C++ has something called "One Definition Rule", which means you cannot have the same thing defined twice, whether it's a regular class or a second template instantiation with the same parameters. They HAVE to be merged in order to be valid C++.

      After reading some of these.. I simply stopped. This is just someone with an axe to grid and is harmful to actual information.

    2. Re:Template misuse by tepples · · Score: 1

      C++ has something called "One Definition Rule", which means you cannot have the same thing defined twice, whether it's a regular class or a second template instantiation with the same parameters. They HAVE to be merged in order to be valid C++.

      If you have 20 translation units that instantiate a template with one set of types, you have to recompile all 20 to get the new definition, even if they do end up merged at link time. And if you instantiate it with more than one set of types, those can't be merged at all. Finally, compiler diagnostic messages involving deeply nested template types can prove counterintuitive for the programmer to interpret: "What the fuck are char traits?"

      This is just someone with an axe to grid and is harmful to actual information.

      I get an impression that the author is a fan of dynamic or otherwise managed languages like Python, Java, and C#.

    3. Re:Template misuse by Anonymous Coward · · Score: 0

      Templates make compiler error messages hard for the programmer to read.

      90% of new C++ template code being written today is using one of either Boost.StaticAssert, Boost.ConceptCheck, Boost.MPL.Assert, or static_assert.

      Boost.TypeTraits (included in C++0x under <type_traits>) make template argument checking a deliciously simple task.

      The ability to instantiate templates multiple times tempts the programmer to make unproductive time/space tradeoffs that might be hard for other programmers to find and fix.

      This is reckless abuse of templates. Any good programmer will optimize for instantiation count, compilation time, genericity (separation of concerns), and function body size (minimum generated code amount). Templates 101. Anyone who does not do this should not be employed.

      Template containers that hold objects by value introduce a risk of slicing [wikipedia.org] when used with STL containers.

      Example in the article (ref reassignment) is only unexpected to someone unfamiliar with how references actually work. Slicing only matters if you are trying (and failing) to do polymorphism, in which case, you have bigger concerns... like eliminating polymorphism.

      Anyway, the sliced base object still can't be converted back to its original type without a user-defined derived copy constructor.

      And if you follow semi-standard practice, all classes you create will be default-noncopyable, further preventing likelihood of such an "accident." Not to imply this actually ever happens.

      So some people aren't big fans of C++ templates because templates are so easy to misuse [yosefk.com].

      Why use C++ at all if you are not going to use templates? It's an improvement over C, at least, but still nowhere near ideal. There are far, FAR better languages than C++ when you remove its template support. Generic programming is the only thing keeping C++ relevant today as a modern programming language.

      And Yosefk? Way to lose all credibility, dude. May I suggest quoting religious scripture along with it?

    4. Re:Template misuse by hazah · · Score: 1

      If you have 20 translation units that instantiate a template with one set of types, you have to recompile all 20 to get the new definition, even if they do end up merged at link time. And if you instantiate it with more than one set of types, those can't be merged at all. Finally, compiler diagnostic messages involving deeply nested template types can prove counterintuitive for the programmer to interpret: "What the fuck are char traits?"

      Realize please that where an instantiation is placed isn't defined by C++. An implementation is free to make it work just as you described, however, that is not the only way that this is done. Of course a template instantiated with a different parameter will yield a completely seperate class, it's supposed to be a distinct type (unlike say, Java), I don't think this classifies as an issue because it's that way by design. Finally, the template error messages are actually like a stack trace. You are effectively running a program during compilation, should that program run deep, then you shouldn't be surprised by a deep trace. This may very well be a language issue, but not one with a clear solution, since the solution can't undermine the purpose of the feature in the first place. In my own mind I feel that something like exception handling during compile time may help here, but this is just a very uneducated guess.

  43. Re:favorite way by Anonymous Coward · · Score: 0

    But then that means the Windows "CLI/scripting system" also "actually work9s)", doesn't it?

    Yes, windows work9s well.

  44. Re:Enlightment again? by jjohn · · Score: 1

    Good lord, I did not expect so many to come the defense of that grand old dame, X.

    Rather than get into an argument on the Internet about Computers, I'll just say that
    the Linux desktop remains a beloved canard to me. I do not doubt that others will disagree
    with me.

  45. What Newlib++? by tepples · · Score: 1

    if you follow ODR then you'll have at most 1 template instantiation for each combination of type parameters.

    The problems come when A. programmers become unaware of how many combinations of type parameters they're actually using, or B. programmers can't decipher template type names in compiler diagnostic messages.

    Also, libstdc++ is a beast. But so is glibc. If you compile for embedded devices - don't use it.

    Newlib is better than glibc for embedded devices. What C++ standard library implementation do you recommend for these?

    It's certainly possible to make 'Hello world' to be about 1kb in C++.

    I've done so with std::fputs of <cstdio>, but there are still a lot of self-proclaimed C++ purists who apply the no-true-Scotsman fallacy on C++ code using <cstdio>, claiming that <cstdio> isn't in the spirit of C++.

    1. Re:What Newlib++? by Cyberax · · Score: 0, Flamebait

      I've used STLPort (STL is mostly header-only) without _ANY_ C++ stdlib.

      If you don't use exceptions (which you probably shouldn't on such small devices) then you'll only need to manually define default global ::new and ::delete operators and a handful of other functions.

      As for C++ purists - tell them to go fsck themselves. IOStreams is an exceedingly ugly part of C++ standard library. A small C++ wrapper over the fopen/fclose/... is usually much better.

  46. Re:Objects... not as easy as they sound by Rob+Y. · · Score: 2, Interesting

    I would imagine that the biggest performance hit for C++ vs C is just the fact that most objects make extensive use of memory allocations. C++ makes this 'safer' than in C, and so most C++ users use it. In C, I tend to avoid memory allocation. You end up defining arrays sized to some reasonable maximum, but there's no performance penalty for that. Occasionally, this does cause problems when that maximum was underestimated, but most of the time it's pretty effective.

    Where I work, we have a transaction processing system that was developed in C. Most of the library code is in C, and multiple attempts to build applications in C++ have resulted in something much more complex and less supportable than the 'standard' C apps. I don't know if this is due to unskilled C++ programmers, or if maybe the particular environment, being highly optimized for C coding, just doesn't gain many of the advantages C++ could provide had the platform been object oriented in the first place.

    For example, our standard apps maintain state persistence by simply writing out one or more C structures to a temp file on disk. These files are simply read back in on the next transaction, requiring no code and no serious overhead (the data's usually in cache anyway). It sounds crude, but it's amazingly effective. C++ coders could continue to do this, of course, but they've assumed they needed to use objects for this purpose, leading to complex schemes for streaming those objects out to disk for persistence.

    Then you get the programmers that attempt to build a pseudo MVC view around a platform that was designed to be a back-end system with a smart terminal front end. In this platform, all the code is on the back end, and the 'view' and the 'controller' are pretty much intertwined. But they persist and build these arbitrary separations which have to then communicate back and forth and each have to persist their own states. After the fact, they've all agreed that what they've built is harder to support than the C stuff they were building before. .Again, maybe this is bad coding or a misunderstanding of the OOP model, but it does point out a problem with C++. Unless you're just building code around an existing, well defined C++ framework, you're not likely to implement a great object model on the first (or fifth) try.

    --
    Posted from my Android phone. Oh, I can change this? There, that's better...
  47. Re:favorite way by V!NCENT · · Score: 1

    Fewer Viruses - check
    Lower TCO - check
    CLI is not working on windows - wrong
    Most FLOSS runs on it - check
    Drivers for more hardware - check
    No kernels panics (BSOD) - wrong
    Not nearly as resource hungry - wrong because tests indicate that Windows 7 is less hungry than Ubuntu
    Penguins - what a BS
    The easyest way of making a Windows user envious = getting the hottest chick on the planet

    --
    Here be signatures
  48. Re:favorite way by V!NCENT · · Score: 4, Funny

    No, karma whoring is to post something completely obvious you know will be modded up and not add anything to the discussion solely because you want to boost your karma. Unlike this comment.

    --
    Here be signatures
  49. C++ as better C vs. no-true-Scotsman C++ by tepples · · Score: 1
    I am not an authority on C++.

    you can always use nothrow new

    As I understand it, the standard library uses throw new, not nothrow new. So if you use the standard library, you get the exception handlers linked in.

    What is the performance overhead of namespaces, [...] references, [...] use of const ints for array sizes (more efficient than C), non-virtual methods, protected/private modifiers

    True, these features allow one to use C++ as "a better C". But a lot of C++ fanboys will claim that if a program doesn't use virtual, throw, and <iostream>, it's not in the spirit of C++.

    typesafe object creation, STL (the word "virtual" does not appear anywhere in the STL sources)

    Exception overhead. Or is the entire C++ standard library also available in a nothrow version?

    function and operator overloading

    No runtime overhead, but especially operator overloading is easy for a programmer to do wrong. People see += and think "cheap"; they see .addAll (Java) or .extend (Python) and think expensive.

    support for wide characters

    Doesn't <wchar.h> aka <cwchar> have these too?

    Many C++ programmers use printf instead of iostream.

    I agree, but C++ fans who write things like C++ FAQ Lite section 15 disagree. See both sides of the story in C++ FQA Lite section 15.

    Note that C++0x has features specifically designed to support a typesafe printf

    That will be interesting once LLVM and GCC actually implement it. Have they yet?

    1. Re:C++ as better C vs. no-true-Scotsman C++ by shutdown+-p+now · · Score: 1

      As I understand it, the standard library uses throw new, not nothrow new. So if you use the standard library, you get the exception handlers linked in.

      The standard library allows you to specify allocators for everything in it that requires memory allocation, precisely so that you can use your own allocation mechanisms. Writing one that does new(std::nothrow) is trivial.

      Of course, this assumes that you want to ignore any OOM errors (which, given the existence of things such as Linux "OOM killer", is a reasonable default), since there's no way for, say, std::string to report a memory allocation error other than just propagating the exception. If you really want to check for OOM without exceptions, then, yes, you'll have to stay clear from STL and other bits of C++ standard library. Which, of course, doesn't diminish the utility of C++ language features.

      True, these features allow one to use C++ as "a better C". But a lot of C++ fanboys will claim that if a program doesn't use virtual, throw, and iostream, it's not in the spirit of C++.

      You present a "no true Scotsman" fallacy of your own here. Given that STL doesn't have a single virtual function in it, and the only "throw" I'm aware of is in at() (which is intentionally provided as a range-checking alternative to operator[] which no-one uses in practice anyway), it's hard for anyone reasonably knowledgeable in C++ to argue that C++ requires virtual and whatnot.

      Exception overhead. Or is the entire C++ standard library also available in a nothrow version?

      The majority of C++ standard library (certainly, the most useful pieces) is in form of templates, which are effectively hygienic macros. Consequently, if your compiler can disable exceptions, that typically applies to the standard library, as well.

      No runtime overhead, but especially operator overloading is easy for a programmer to do wrong. People see += and think "cheap"; they see .addAll (Java) or .extend (Python) and think expensive.

      What does addAll have to do with operator+=? I mean, sure, you could overload the latter that way (just as you could overload it to do system("rm -rf /")), but no-one in a sane mind does that.

      That will be interesting once LLVM and GCC actually implement it. Have they yet?

      g++ has had them since 4.3 - which is to say, for slightly over 2 years now.

    2. Re:C++ as better C vs. no-true-Scotsman C++ by tepples · · Score: 1

      this assumes that you want to ignore any OOM errors (which, given the existence of things such as Linux "OOM killer", is a reasonable default)

      I was referring to embedded systems and handheld devices, not PCs. I specifically had Nintendo DS (4 MB RAM, single-tasking) in mind.

      If you really want to check for OOM without exceptions, then, yes, you'll have to stay clear from STL and other bits of C++ standard library.

      Would it be safe to say that common STL implementations operate under the assumption that allocate() throws std::bad_alloc rather than returning 0?

      What does addAll have to do with operator+=? I mean, sure, you could overload the latter that way

      std::string does exactly this. I was under the impression that std::vector did the same, calling std::vector::insert() at the end, but now I guess not.

      • Java: someArrayList.addAll(otherSequence);
      • Python: someList.extend(otherSequence)
      • C++: someVector->insert(someVector->end(), otherSequence->begin(), otherSequence->end());
    3. Re:C++ as better C vs. no-true-Scotsman C++ by shutdown+-p+now · · Score: 1

      Would it be safe to say that common STL implementations operate under the assumption that allocate() throws std::bad_alloc rather than returning 0?

      Yes, though this is unnecessarily vague. It would be most precise to say that common STL implementation does not expect allocate() to ever return 0. Technically, if you do that, the behavior is undefined, but in practice a segfault is practically guaranteed on most platforms (not so, for example, on real-mode DOS; no idea about Nintendo DS). So there's no exception overhead, if that's what you're looking it; but also no way to recover from OOM, either - while you can trap SIGSEGV, you can't do recovery from the signal handler.

      std::string does exactly this.

      True, but it is amortized O(1) for std::string, so I don't see a problem there.

    4. Re:C++ as better C vs. no-true-Scotsman C++ by loufoque · · Score: 1

      Reason why iostreams are needlessly big and complicated is because of their intricate and complicated locale system, that very few implementations have exploited to make it useful (and by that I mean none major).
      The locale system and the wide characters support are so broken anyway that they're beyond repair, even the C subset.

      I'm pretty sure you'd be hard pressed to find any decent C++ programmer who thinks iostreams is good. It's just better than printf/scanf because it's type safe and doesn't require static buffers, so people still use them for non performance critical stuff (and printf should be the same). For serious file reading/writing, you use specific parsers/formatters anyway.

      If you're doing embedded C++, you're going to want to get rid of anything related to iostreams, wide characters and locale support, be it C or C++.

  50. Re:favorite way by siride · · Score: 1

    Well, on my system, Windows 7 idles at about 1.5 GB of RAM in use, while Gentoo idles at about 200 MB, so...

  51. Re:favorite way by siride · · Score: 1

    Yes, if you don't do things right, they won't work right. Wow, you are a genius. Perhaps bash is less forgiving than Windows crap, but I'd call that a feature, not a bug. The main problem with Windows is that it is so damn forgiving in every area that people can do stupid things and then require the OS to support them for years/decades to come, fucking everyone else over in the meantime. Windows shell scripting still works from release to release because they simply don't change anything because it is simply no longer under development and is deprecated.

  52. Re:favorite way by V!NCENT · · Score: 1

    Ha... ha... ha... ha... ha....

    Okey....

    1. Windows 7 has better OpenGL performance no matter what hardware and what drivers you throw at it.
    2. 1.5GB? Sorry but I thought Windows 7 didn't use more than 200-300MB RAM and cached out wasted RAM space?
    3. What are you running next to GNU+Linux?

    --
    Here be signatures
  53. Re:favorite way by V!NCENT · · Score: 1

    Oh I forgot to mention less kilowatts...

    --
    Here be signatures
  54. pop goes the weasle because the weasle goes pop by Anonymous Coward · · Score: 0

    Big deal, C++ sucks hard if an amateur tries to write in it when he's used to C.

    Guess I won't be upgrading.

    1. Re:pop goes the weasle because the weasle goes pop by Runaway1956 · · Score: 1

      Now THREE is a good reason not to adopt new technology. We really need to keep things at a level that amateurs can understand. But, wait, what about the struggling NOVICE? Let's drop back 20 and punt. No new technologies that blooming idiot novices can't master in 24 hours! That's the way forward, for certain!

      --
      "Windows is like the faint smell of piss in a subway: it's there, and there's nothing you can do about it." - Charlie Br
    2. Re:pop goes the weasle because the weasle goes pop by Runaway1956 · · Score: 1

      Oh yeah. I'm a novice speller. There IS a reason to preview posts, huh? Who'da thunk it?

      --
      "Windows is like the faint smell of piss in a subway: it's there, and there's nothing you can do about it." - Charlie Br
  55. Re:favorite way by Wowsers · · Score: 1

    I just used the middle click / cube shrinks and becomes semi-transparent and can be rotated... effect in Compiz, which immediately shot up the CPU usage for both cores of my processor from 20% to around 60% per core. Under Beryl the CPU usage changed about 2% over what the system was already running at. I would say that Compiz does not use the graphics card like Beryl did, and the Compiz devs deny there is a problem.

    --
    Take Nobody's Word For It.
  56. Re:favorite way by shutdown+-p+now · · Score: 2, Insightful

    If you were using #!/bin/sh and expecting bash specific code to work, you're doing it wrong. If you want bash, call it by its proper name and it will always work.

    A more likely scenario is that a script written by someone else improperly references /bin/sh despite being chock full with bashisms.

    The real problem is that many people these days just assume Unix = Linux and can't even think of /bin/sh possibly not being bash (or something "compatible enough"). This is especially true of "Linux on the desktop" crowd, as server admins typically know better

  57. Re:favorite way by shutdown+-p+now · · Score: 1

    Something that's more closed than Windows and Linux?

    1. OS X is not any more closed than Windows.
    2. A Windows user will likely not care anyway.

  58. Structures by DragonHawk · · Score: 1

    For example, our standard apps maintain state persistence by simply writing out one or more C structures to a temp file on disk.

    Of course, the C standard explicitly states that the layout in memory of structures is implementation-dependent, so doing things like that sets yourself up for serious pain when you do things like change compiler versions, optimization options, or run on different platforms.

    In my experience, a lot of programs run without crashing only through sheer luck.

    --

    dragonhawk@iname.microsoft.com
    I do not like Microsoft. Remove them from my email address.
    1. Re:Structures by Rob+Y. · · Score: 1

      This is strictly done for temporary files to hold state between web-like transactions. I would never use this technique as a 'database'.

      --
      Posted from my Android phone. Oh, I can change this? There, that's better...
  59. Re:Sensible choices'r'us by Stumbles · · Score: 1
    Then I would have to say your tool-chain is messed up in some fashion, your cmake installation is hosed in some fashion or you are just trolling. I have built opencv with cmake since their initial version release switched and up to its current release; it has always compiled and installed just fine.

    So you are saying if you were to compile kde-4.4.x (they use cmake) you would convert it all to autotools? ... I don't believe you at all, not for a second.

    --
    My karma is not a Chameleon.
  60. Sugar? by DragonHawk · · Score: 1

    References

    Sugar for pointers.

    And C is sugar for assembler, which is sugar for writing machine code directly using a hex editor.

    The whole point of any language feature is to make it easier to use machine features. Calling them "sugar" doesn't negate that.

    --

    dragonhawk@iname.microsoft.com
    I do not like Microsoft. Remove them from my email address.
    1. Re:Sugar? by tepples · · Score: 1

      References

      Sugar for pointers.

      And C is sugar for assembler

      In what situations would one use C++ references where pointers do not suffice?

      The whole point of any language feature is to make it easier to use machine features. Calling them "sugar" doesn't negate that.

      I didn't necessarily mean "sugar" in a negative way. I do remember writing that classes with no virtual methods are a useful sugar.

    2. Re:Sugar? by Anonymous Coward · · Score: 0

      For operator overloading. It was the main reason for adding references to the language. Without them you would have to write &x + &y all the time. Plus, you would have to allow breaking one of C++ rules: you can't overload operators for primitive types (i.e., pointers). One place where you must have references is in overloading the indexing operator. You can't write x[1] = y without references. You'd have to write *(x[1]) = y. Yuck.

  61. Re:favorite way by tyrione · · Score: 1

    I'm happy with POSIX OSen. But I would not recommend them to a Joe Windows user, ever, since I don't want to be their Support Guy from now until there's a distro that actually Just Works.

    Seriously? My POSIX compliant OS X is something I do recommend as it does Just Work.

  62. Re:Objects... not as easy as they sound by gbjbaanb · · Score: 1

    C++ coders could continue to do this, of course, but they've assumed they needed to use objects for this purpose, leading to complex schemes for streaming those objects out to disk for persistence.

    My PoV on C v C++ coding comes down to this kind of stuff. In C, you'll have a function that takes a struct parameter and writes it to file. In C++ you put that function inside the struct and remove the parameter.

    so Persist(struct Data d); becomes d.Persist(); simples!

    In effect, no difference - except to handily keep methods and data together and easier to understand. Obviously a decent C programmer will put the persistence routines and data struct together in a module... which is roughly the same thing.

    The benefit to C++ is that you get all the above type of coding (ie no difference but a bit of easier code organisation) and you can, if you want to, use some nice new features like the STL.

    Any coder who thinks that C++ is a great place to go fully OO is miguided, IMHO. I've seen object hierarchies and exception hierarchies that are totally confused, difficult to debug and understand. In fact, you could say that this kind of app should not be written in C++, but written in UML instead! In other words - confused, difficult to understand, debug and fragile as any other "Enterprise" app.

    So - keep it simple and you're golden, try to go crazy with every little feature and you're stuffed. I have a feeling that many a coder who tries the latter and fails then moves on to Java or C# thinking its the language that is at fault.

  63. Re:favorite way by GNUALMAFUERTE · · Score: 2, Interesting

    I run compiz on several Atom 230 and 330. This are mini-itx mobos that have integrated Intel GMAs (Pineview series). I am checking this as we speak over SSH.

    Compiz CPU usage: 2% Ram: 34MB.

    This is with all settings turned up to 11, and, since this machines are surveillance systems, 4 windows showing 352x288 video @30fps each, plus a fullscreen browser window that is constantly updated.

    Total CPU usage is ~3.4%.

    --
    WTF am I doing replying to an AC at 5 A.M on a Friday night?
  64. Re:favorite way by siride · · Score: 1

    Well, I know OpenGL performance on Linux is sucky, but Windows 7 is definitely using more RAM. That's what task manager shows. And yes, I know how to read the various dials on there.

    I don't know what your 3rd question is supposed to mean.

  65. Re:Enlightment again? by hazah · · Score: 2, Informative
    Swing: X = GUI
    Miss: X = GUI

    Assuming something is what it isn't will surely give you wrong impressions. X is NOT by ANY means a GUI. Try again.

  66. Re:favorite way by Runaway1956 · · Score: 1

    I'm not going to pretend to understand all the "rules" that Windows or any other operating system plays by, regarding RAM.

    But, it seems pretty obvious to me that most operating systems are going to use, or try to use, all the memory available.

    Ubuntu desktop has 8 gig of memory, currently using 2.2 gig, 1 gig of which is given over to my Win7 virtual machine.

    Inside the Virtual machine, 700 meg in use, running only Firefox and task manager. My Firefox is rather bloated, with several scripts and addons installed.

    In my experience, both Ubuntu and Win7 run nicely with 1 gig of memory. Both tend to gobble up RAM if it's available. Your mileage may vary, depending on how you configure your system, applications installed, and resources available.

    --
    "Windows is like the faint smell of piss in a subway: it's there, and there's nothing you can do about it." - Charlie Br
  67. Re:favorite way by Anonymous Coward · · Score: 5, Insightful

    Lower cost of ownership

    If you don't value your time.

    Linux is only free if your time is worth nothing.
    Windows is only $119.99 if your time is worth nothing.

  68. Re:favorite way by EsbenMoseHansen · · Score: 1

    Sometimes the gnome-power-manager is consuming 200 MB of ram all on its own.

    I'm all for bashing Gnome, but I think in that case you're not reading the numbers right. Probably, most of those 200MB are links to shared libs loaded anyway as part of the Gnome system. If you divide that bit up equally among all the users of those libraries, you'll probably end up with 4-6M or so. If you only take the bit that is used *extra* for having gnome-power-manager, you'll probably get less than a megabyte, a likely less than .1.

    All numbers are wild guesses since I don't actually have a Gnome system :)

    --
    Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
  69. Re:favorite way by Kjella · · Score: 1

    I think the biggest issue is that there's no real market for Linux computers. Too many are tinkerers who'll put it on their old PC or random parts or some sale or will want a different distro than it's sold with anyway or whatnot. Sure, there's a select few Ubuntu models online at Dell US but otherwise the availability is very, very slim. And if you first buy these they don't come with a Windows license so it's not for the "let me get my feet wet and if I panic I can boot into Windows" crowd, as far as I know pretty much nobody sells dual boots. The end result is that Linux is trying to jump the "Just works" hurdle on all hardware simultaneously, which is incredibly hard. What we need are known Linux-friendly machines you can point people to and say "This machine will run both Linux and Windows. Try it, if it's not for you dual boot back and all you lost was a little bit of time." Right now you have to commit far too much for comfort.

    --
    Live today, because you never know what tomorrow brings
  70. Re:favorite way by Eli+Gottlieb · · Score: 1

    Funny, I've been using Ubuntu 10.04 on my netbook since it came out, and previous versions since I got the thing, but I never had problems of the kind you describe.

  71. Re:favorite way by Anonymous Coward · · Score: 0

    1. what you really meant to say was the gfx card has to do some work too in addition to the cpu
    2. due to limitation of the composite extension the data has to be bounced around like mad causing serious performance issues, this is quite apparent when resizing windows

  72. Re:favorite way by V!NCENT · · Score: 1

    Task manager shows RAM in use, including cache, which is common knowledge.

    Then the third question is also supposed to be dead obvious:
    Gentoo is nothing more buyt Lego. So what did you build with Gentoo? A bloated Ubuntu, a mean and lean, feature-less E17 machine... etc etc... How the hell can you compare Gentoo to Windows?!

    --
    Here be signatures
  73. Re:favorite way by V!NCENT · · Score: 1

    Don't critize that which you know nothing about, I guess?

    FWIW; Fedora here eats up about 1.1GB and KDE4 is even harder to max out due to all the libs/data engines sharing. Mever exceeded the 2GB limit. SWAP has never been doing anything at all. I have 8GB of RAM, because it's drit cheap and because I wanted more RAM than I would ever need.

    --
    Here be signatures
  74. clod by Anonymous Coward · · Score: 0

    i have an orange afro you insensitive clod

  75. Re:favorite way by siride · · Score: 1

    I know how to read memory reports, you dolt. Right now, I have 1762 MB in use, 2158 it Standby (cache) and 13 MB free. I compare that with Linux, which uses pretty much the same virtual memory model as Windows (aside from the global vs. local working set deal and a few other things of no importance here) and I see that Windows uses three times as much memory as Linux does running basically the same programs -- services excluded. What did I build with Gentoo? I installed KDE and I have a KDE desktop. It works, it's snappy and uses a lot less memory than Windows 7. I can compare it with Windows because at the end of the day, it's still a monolithic OS kernel, system libraries, system software/desktop environment plus user applications. I can't think of a single reason why my Gentoo w/KDE is not comparable to Windows 7 with Explorer.

  76. My technical expertise level by bugs2squash · · Score: 1

    Is way too low for me to have contributed to Compiz anyway. But I do worry when I see simpler projects converting to C++, because I feel that it locks me out along with so many people that might otherwise contribute. I look at C++ and the whole thing may as well be encrypted or written in perl for the amount that I can understand it. I could at least struggle through what the C was trying to tell me.

    --
    Nullius in verba
    1. Re:My technical expertise level by stoanhart · · Score: 1

      The two are not really that different. If you can read C code, you should be able to read C++, so long as you are familiar with basic object oriented concepts (classes, inheritance, encapsulations, public vs. private, etc.) If not, you can probably find a short primer online (maybe 5 pages) that can explain all you need to know in order to at least get the gist of the code.

  77. Re:favorite way by V!NCENT · · Score: 1

    Then there's something horribly wrong with your Windows 7. I have access to a Windows 7 workstation here and Windows 7 doesn't consume that much. On the other hand you can't tell me that you installed a full blown KDE SC 4.x. KDE3.5.x? Or you must be running something realy, realy stripped down... 200MB is almost impossible...

    --
    Here be signatures
  78. Re:favorite way by Anonymous Coward · · Score: 0

    Unused RAM is wasted RAM. Windows correctly uses a lot of the physical memory not in other use to hold stuff it would otherwise need to get from the HDD.

  79. Re:favorite way by siride · · Score: 1

    Yeah, I'm thinking I might need to do a clean install. I find 1.7 GB with just Chrome open to be appalling. I do have a full-blown KDE running, but KDE really isn't that heavy, despite what the GNOME-tards say.

    It's only 200 MB when first started up and with no apps running. It does get bigger, but it usually stays between 250 MB and 400 MB when idling.

  80. Re:favorite way by bonch · · Score: 1

    Don't forget the tactic of responding to a highly-rated comment in a contrarian way by accusing the poster of a strawman argument and accusing them of astroturfing, you two-faced M$ stockholder.

  81. Re:favorite way by the_womble · · Score: 2, Informative

    And drunken cheerleaders get date raped more than shut-in nerd chicks. Personally, I prefer nerd chicks, and you likely do too, but most people don't. Really, they don't, and there's no use telling them that their opinion is wrong.

    Do people prefer Windows? After actually trying Linux? Not in my experience.

    If you don't value your time.

    Most stuff works out of the box. Some stuff does not work out of the box on Windows or Mac either.

    Until of course you try and run a script written for fooshell on barshell, i.e. when a distro changes its shell.

    Dash is supposed to compatible with Bash if you stuck to Debian policy of affected scripts (those than use #!/bin/sh - if you useed bash specific features you should have used #!/bin/bash . Any examples of stuff that breaks? BTW Bash is still the login shell.

    Can be made to run on it, given enough time.

    Most stuff non-geeks use is in the major distros repos and is easier to install than Windows apps.

    But I would not recommend them to a Joe Windows user, ever, since I don't want to be their Support Guy from now until there's a distro that actually Just Works.

    My father, my wife, by seven year old daughter, her former pre-school principal, an accountant who used to work for me are all presumably geeks? They all prefer Linux.

  82. Re:favorite way by ZosX · · Score: 1

    That's still a pretty good tick on the processor. Windows 7 eats up 0% at idle with all the bling turned on. The taskmanager is the only thing that reports cpu usage. I never liked compiz on linux because it always involved a decent amount of resource drain, even with accelerated drivers. I'm sure its better than when I last tried it, but I want 100% of my cpu all the time if possible.

  83. Re:favorite way by kiddygrinder · · Score: 1

    200-300MB RAM and cached out wasted RAM space

    heh, that's why windows 7 runs so well on 256 meg of ram
    /sarcasm

    --
    This is a joke. I am joking. Joke joke joke.
  84. Re:favorite way by GNUALMAFUERTE · · Score: 3, Interesting

    Excuse me, what part of "since this machines are surveillance systems, 4 windows showing 352x288 video @30fps each, plus a fullscreen browser window that is constantly updated. Total CPU usage is ~3.4%." You didn't understand?

    It's not compiz itself eating up that much processing power. It's the 4 threads capturing 352x288 video @30 fps, and displaying it in 4 different windows.

    Also, it is IMPOSSIBLE for any operating system to be actively displaying how much CPU it is using while using 0% CPU. Answer: WINDOWS IS LYING TO YOU.

    On the other hand, even if windows created some magic way to run out of thin air while using 0 processor power, it would mean nothing because it would still be completely useless.

    --
    WTF am I doing replying to an AC at 5 A.M on a Friday night?
  85. Re:favorite way by nschubach · · Score: 1

    Have you tried?

    I've had more USB devices "just work" in Linux where I had to install something special BEFORE plugging in my hardware in XP.

    Linux's USB Mass storage drivers are light years ahead of Windows, IMHO.

    --
    Every time I start to have faith in humanity, I ruin it by driving to work between 7 and 8 am.
  86. Re:favorite way by LordLimecat · · Score: 2, Insightful

    Heres why I WOULD recommend them to some people, in certain controlled instances (have, actually):

    A) have you actually tried to figure out how to secure a network, or even your Dad's computer, when doing so requires he have the ABSOLUTE LATEST version of flash, adobe reader, and java? Not to mention those realplayer and QT plugins that are sure to get exploited one of these days? Linux gets it right with centralized software updates; Windows is an absolute nightmare in this regard. Theres WSUS, but oh wait you cant add crap like foxit reader to it, and MSI deployments can be a nightmare to upgrade. Not to mention some things just dont have MSIs.

    B) Most users these days honestly dont care that much about windows, as the programs that they run and the way their windows act. Seeing as many users manage to make the transition to Mac just fine, I dont see why you would claim that there are no "Joe Windows users" out there who would survive an easy transition to, say, Ubuntu 9.04. And in general, once you get things working (which ISNT that hard, theres 8 million wiki articles on just about every concievable 9.04 problem by now), they will continue to work; as exploits get discovered, the system will automatically patch as the updates are released.

    C) Being able to customize the crap out of Linux means I can take Ubuntu {favorite version}, set up some sane defaults (remove crappy and unnecessary programs, install VNC and a DDNS updater), then compile the whole thing into a single CD that installs the working system as is. A little more work and you can have a backup that runs to an external drive (back-in-time), and set the CD to auto-wipe / reinstall the root partition without touching the /home. D) Heres the real kicker. Windows as of now has AWFUL recovery options. Windows XP was the last OS that had any form of disaster recovery-- combofix works well, its got the recovery console, its got repair installs, and its boot.ini is actually editable in any OS. Vista and 7 dont have a useable repair (to repair, you have to launch it from a working windows install...), and any recoveries you make to a new HDD will just not work because the disk ID wont match the BCD. If you get a virus on Vista or 7, youre basically hosed, because combofix doesnt really work on it, and there arent any fantastic removal tools yet (theres GMER, but its showing its age, and I dont know if it works on Win7 x64).
    If something goes wrong on Ubuntu, conversely, I can hand them a disk with a remote-access agent on it, remote in, and fix their root partition easily.

    Look, Ive heard this argument that "I dont want to be their tech repair guy" before, but chances are you already are, and given the choice between friends and family using Windows with its AWFUL update mechanism, its AWFUL vulnerabilities, its AWFUL recovery options, and the joys of having to hunt down drivers to make crap work (ever try installing XP on a machine that was bundled with Vista home? It SUCKS.), I will take Linux with centralized everything and built in drivers any day.

  87. Re:Enlightment again? by WeatherGod · · Score: 1

    Mod parent up! Damn, I just spent all my mod points on another thread. I can't tell you the number of times I had to get this fact straight with people.

  88. XRandR? by Anonymous Coward · · Score: 0

    XRandR still broken for multiple video cards? Seriously, it's 2010 and they still haven't fixed that shit. People with three monitors are far more common then they once were, and we still get left out in the cold. Hell, it's shameful that Nvidia's flagship quad monitor cards utterly fail with Compiz because of the little detail of a PCIe switch on the card connecting two GPU's.which are EXACTLY THE SAME. ATI is no better either, and the pain will only increase with the Eyefinity rigs.

  89. Re:favorite way by 8086 · · Score: 1

    Compiz does need a simple Mac-style settings interface with optimal settings pre-fed along with the more advanced one. It takes nearly an hour to explore all options and select the configuration that will look the coolest for one's desktop.

  90. Re:favorite way by V!NCENT · · Score: 1

    Ah I see... But I'm guessing you are not running preload? Or did you not count that as RAM usage?

    --
    Here be signatures
  91. Re:Sensible choices'r'us by JackieBrown · · Score: 1

    kde is the first thought I had. I initially hated cmake but have really grown quite fond of it.

  92. Re:The sooner Android replaces KDE, the better by Anonymous Coward · · Score: 1, Funny

    What can i do in android that i cant do in gnome?

    Provided that you only have an inaccurate pointing device that obscures 30% of the screen, pretty much anything.

  93. Re:favorite way by Anonymous Coward · · Score: 0

    Conversely, almost no closed source software runs on Linux. Which might not matter to you, but if you're trying to get work done, having things like Photoshop

    GIMP

    Outlook

    Thunderbird - I use that exclusively at work where they don't even know that you can buy software from anyone other than M$

    No Blue Screen - I haven't seen a blue screen on a Windows machine in many years. And when I do, it's usually because of bad RAM, causing something to get corrupted. Blue screens still exist, but they don't happen quite as often as they used to. I imagine most Linux systems would also crash pretty badly when they have bad memory.

    While I also don't see blue screens on my work machine, I do see a lot of instability, poor memory management, bloatware, and general time wasting annoyances on my Windows machine. I definitely have to spend a lot of time getting things working in Linux, but it is nice to actually know that I'm a competent user of the machine and not just someone along for the ride.

  94. Re:Sensible choices'r'us by Stumbles · · Score: 1

    I am no where near a cmake guru, but it does seem a lot simpler to deal with than the autotools stuff; not that I am an autotools guru. Though I do wish the cmake folks would shorten the option names. They can get a lot more lengthy than those used in ./configure, like; -DCMAKE_INSTALL_PREFIX, why not just INSTALL_PREFIX or PREFIX?

    --
    My karma is not a Chameleon.
  95. Re:favorite way by siride · · Score: 1

    I'm not running preload. I've never found it to be worth it. Things load fast enough already anyway.

    I booted back into Gentoo again last night and the numbers are more like this: starts off around 200 MB once I get into KDE. After doing things for a bit, but then closing all programs, it's more around 400 MB. I presume more code paths get touched by KDE and other libs and those get pulled into active RAM. But that's still considerably less than Winodws 7 is using.

  96. Sorry, but not impressed by Ngarrang · · Score: 1

    I've seen Compiz, and I must admit that a user like me simply not impressed by the bells and whistles. I use my computer to get stuff done. I want the primary interface to get to my apps to stay out of the way and NOT take up the memory I would rather my apps have. In Windows, I set the performance options to maximum performance. Yes, I turn off all of the animations and -- as I see it -- completely unnecessary visual effects. I use my computer for the apps, not to waste time with pretty-pretty icons, swoopy sound effects and transparents fade-ins/outs. For me, it is about the utility of the device. I want the OS to be stable and do its job efficiently. Just get me to my applications and leave my CPU to making my app faster.

    --
    Bearded Dragon
  97. Re:favorite way by drinkypoo · · Score: 1

    Compiz does need a simple Mac-style settings interface with optimal settings pre-fed along with the more advanced one. It takes nearly an hour to explore all options and select the configuration that will look the coolest for one's desktop.

    It has one, though neither is installed by default when you install compiz. Install simple-ccsm, it gets you both the complex and simple configuration tools. The simple one allows you to activate plugins by assigning them to hot corners, edges, keys etc. The complex one allows you to enable them and then assign keys etc. It's actually a very graceful way of handling the situation, and I hope it continues for 0.10.
    I spent probably hours collectively tweaking Compiz, but then I started with Beryl on Xgl. And I use Emerald, so I count theme tweaking in there. I have a very nice clear glass theme that I adore, especially now that emerald seems to be able to stay running for more than ten minutes.

    --
    "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
  98. User experience by Anonymous Coward · · Score: 0

    or had to recompile sound drivers after every OS update (Ubuntu on that one too).

    I wish I could. Sometimes vendors take years to get their sound drivers working. Google realtek, imac, and Windows 64 bit.

    I know this is horribly off topic, but I have to say this. This concerns user experience. Recompiling and patching by hand is IDIOTIC thing to require a user to do. Two reasons:

    • On a normal distro you have normal packages installed. To compile anything, you need development packages which are like toxic waste for a normal user. They are there for no apparent good reason other than that you can fix a nasty or annoying bug in a certain package. This becomes unreasonable, because patching one package requires installing at least 10 development libraries.
    • Package management. Those dev-packages get lost in package management, so you're never really confident that you removed all that unnecessary dumb shit. After you patch and compile a package, you have to install it usually by 'make install'. This effectively installs it outside the package management. That means you have to keep the sources for the package to be able to uninstall it, if necessary. This might be fine IF YOUR ACTUALLY DEVELOPING. Over time package management makes things even worse. Your patched version usually gets overwritten by a newer packaged version. Then you get basically a miniature DLL-hell, because package management has no idea what the old files were. If you get into problems like program not working, reinstalling won't probably work. Happened to me enough times.
    • Patching can also go wrong very easily. For instance, if user decides that he seems to have a choice of downloading newer sources. Patch might do something horribly wrong to a wrong version. I know that an experienced user won't do silly things like that, but the inexperienced have no idea why the exact version matters so much. Even when explained to them.

      Compiling usually ends in tears also. Most users who have a certain problem with, for instance a wifi-card, and try a certain patch follow a guide that is usually at least an year old. In that year many packages required to build the package you need to patch have changed. Because distro maintainers are not demigods who find every little compile-time bug, you usually get at least one package that simply won't compile with out fiddling. Or you get the same result because the user skipped/forgot one command from the guide. Even if everything went well, you still might end up with a version that screws up your configs.

      I had all these problems + crash course to mercurial patching em28xx-driver on Ubuntu 8.10. Even after that my video capture device wouldn't still work other than randomly.

      Let's take a car analogy. Say your car's engine is low on power and makes horrid noise. Your friend and an expert tells you that crankshaft bearings need to be replaced (hypothetically). They give you some instructions how to do it. Let's assume you live in a communist country where you can get all necessary parts and tools for free. Now all you need to do is to dismantle the car enough so that you can get the engine out. Then you have to dismantle the whole engine to get to the crankshaft. After replacing the bearings you have to assemble the engine and put it back in the car. Then you only have to assemble the car. Now you have fixed the bugs in your car.

      Except that usually when you do things the hard way you hit a dead end somewhere (rusted bolt) and you give up. Or you end up with an engine that has a dozen new problems.

      Now I ask you. Would you do all this? Would a normal person do all this? No, they hire someone else to do it i.e. automate the process. Of course, there are people who would do all that. They are called enthusiasts.

      Don't design your user experience for enthusiasts.

  99. Re:Sensible choices'r'us by Anonymous Coward · · Score: 0

    With autotools you just fiddle with configure.ac and the various Makefile.am's. You don't touch the Makefile.in's or the *.m4 files.

    Autotools is very powerful. It is also easy to use, but I admit it is hard to learn how to use.

    cmake is easier to learn how to use, is also easy to use, but is way less complete.

    The biggest advantage for cmake is the built-in support for OSX and Windows, if you want to build on these platforms.

    IMHO there is very little reason to choose cmake for a *nix project.

  100. Re:BS - WOW by Anonymous Coward · · Score: 0

    Both sides of this argument are quite good. Thanks to you both for a well thought out and civilized discussion comparing the strengths of two popular operating systems.

    However, this is Slashdot. There is no room for this sort of cerebral and informed debate so I'll have to ask you to leave.

  101. Language only as good as best implementation by tepples · · Score: 1

    That there is a performance overhead for exceptions is mostly a myth.

    There might not be a time overhead, but there sure is a space overhead. Adding a single throw and try...catch to a program compiled with g++ resulted in 64 KiB of additional library code. This is a lot more significant on a handheld device from mid-2001 with 288 KiB of RAM than on its successor from three and a half years later with 4 MiB, so I guess nowadays it isn't enough to worry about.

    If the generated code ends up being equivalent instructions, a competently written compiler can eliminate the additional code

    For one thing, I don't see how often templates instantiated for types of different sizes would result in equivalent instructions. For another, which free C++ compilers are competently written in this respect?

    a defect in one particular implementation isn't a legitimate complaint against the language.

    A language is only as good as its best free implementation.

  102. Re:favorite way by warchildx · · Score: 1

    Also, it is IMPOSSIBLE for any operating system to be actively displaying how much CPU it is using while using 0% CPU. Answer: WINDOWS IS LYING TO YOU.

    Maybe not lying per-se, but not displaying to a drilled down accuracy either. 0% at idle, is showing that the system is using less than 1% usage at idle... windows doesnt show cpu usage percent in smaller than 1 increments.

    So to clarify, system using 0% *according to windows* could equate to approximately [0].16% cpu usage at idle. - Not exactly 0%, but for rounding purposes, alot closer to 0 than 1.

  103. Re:favorite way by GNUALMAFUERTE · · Score: 1

    I fully understand that it is a rounding error. They are using floor() instead of round().

    Anyway, I put it that way because the parent post was implying that windows was better than GNU/Linux because in my case my OS was using 3.4% of CPU while showing 4 full video windows on an OpenGL Desktop, and running Apache, MySQL and several other daemons in the background, which he considered "idle", and he compared that to a windows os doing nothing that showed "0%".

    --
    WTF am I doing replying to an AC at 5 A.M on a Friday night?
  104. Re:favorite way by Anonymous Coward · · Score: 0

    Dash is supposed to compatible with Bash

    You mean, Dash is supposed to be compatible with sh. In the past most distros just used Bash for sh compatibility, but Dash is supposed to be much faster, but it doesn't have the features of dash. For scripts that are truly sh compatible, there shouldn't be a problem using Dash instead of Bash.

  105. Re:favorite way by Anonymous Coward · · Score: 0

    but it doesn't have the features of dash

    Dammit, that should be "but it doesn't have the features of Bash".

  106. Re:favorite way by ZosX · · Score: 1

    No. I was talking about how you claimed that Compiz uses up 2% at idle. What are you claiming? That your system with nothing else running is hovering at 2% or are you saying that compiz is using 2% at any given time? I wasn't trying to say anything about the 3.4% you keep harping about. Yes that's certainly not a bad number. I was just talking about how your display interface of choice shouldn't take up ANY CPU. If it can't offload to the gpu, it is totally useless to me. As it is windows aero does not even register on my CPU. The pretty desktop widgets take up 2% or so, but I can toggle them off with an icon on my taskbar. My experience with X and especially compiz is that they both eat CPU cycles like candy and something tells me that even with perfectly good video card drivers with real decent open gl acceleration, compiz and X would still eat up CPU cycles. Why? Because they both suck. Maybe one day instead of coding 4 different window managers/desktop environments running on an ancient windows server from the 1990s and having major distros line up on a single solution that integrates from top to bottom as one homogeneous piece of code. I won't hold my breath.

  107. Re:favorite way by GNUALMAFUERTE · · Score: 1

    Your idea that your WM shouldn't use the processor is ridiculous at best. Everything takes up cycles, a program running on your computer will take up cycles unless it is asleep. In windows you can't even tell them apart because the whole system is a fucking mess where you can't really tell apart what each process is doing.

    On the other hand, comparing a few shitty reflections that windows added to an actual full OpenGL desktop is ridiculous.

    The sole fact that you are actually using windows proves that you are a fucking asshole that isn't qualified to comment on anything related to computers. Go be a farmer or something that you can actually manage with your single digit IQ.

    --
    WTF am I doing replying to an AC at 5 A.M on a Friday night?