0

I have been using Linux for a few months, and I am currently running Arch on an old desktop. I have heard great things about compiling everything from source, for example, that Gentoo and other similar distros are blazing fast. I have never used it, and I do not plan to very soon. However, I may want to speed up my daily applications. I am also wondering whether I should use GCC or Intel's C compiler. I typically use at most 2 GB of RAM, but I have an old and slow processor. Should I compile all of my applications from source or keep using binaries?

Thanks!

3

The answer is yes. Noticeably? Almost never.

Depending on the hardware you are going to run it on, speed "might" be improved, because you could use whatever optimizations your CPU offers. But note that most of the time an applications is just using libraries, so in order to take advantage of that you should go full Gentoo, for example.

Is it worth the effort? Probably not, unless your are running on pretty old hardware, or you are doing some serious number crunching or something that is run so many times a second, each instruction counts.

Current hardware is basically idle most of the time, and that's a fact that allows for stuff like SETI@home, Folding@home, Great Mersenne Prime Search, ...

In older hardware, configuration might help more than recompilation (that comes with its own set of problems, like maintanability, security fixes and dependency tracking).

For example, configuring Firefox to use just one or two parallel content processes helps a lot in low memory systems. If CPU is your problem, you might want to either disable or manually run certain services or background tasks. Tumblerd can easilly kill an old computer, and so does updatedb.

Always on the configuration side, you could recompile to disable unneeded libraries/services or adjust other fields. For example building libreoffice with --disable-pdfimport. In that general case, you'd still be better off downloading the source packages used in your system (not upstream) and tweaking those. Not a lot to gain, but lots to learn.

Also note that the speed of an application may in cases be limited by disk or network I/O speed. In these cases, compiling the software from source can not be expected to improve performance.

5
  • Thanks. If I tried it then which compiler should I use for old intel hardware? – user398085 Apr 14 '20 at 4:39
  • 1
    A compiler that understands the specific features of your platform. If you want to dive that deep, this last question of yours might deserve a brand new post. – Eduardo Trápani Apr 14 '20 at 5:08
  • Oh sorry, I do not know that much about low level stuff. – user398085 Apr 14 '20 at 5:39
  • @coder54321, best bet is probably latest GCC/clang, support for old machines isn't purged often and you win new developments. – vonbrand Apr 14 '20 at 11:55
  • Thanks vonbrand. – user398085 Apr 14 '20 at 17:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy