1. Computers
  2. Display Drivers
  3. Graphics Cards
  4. Memory
  5. Motherboards
  6. Processors
  7. Software
  8. Storage
  9. Operating Systems


Facebook RSS Twitter Twitter Google Plus


Phoronix Test Suite

OpenBenchmarking.org

GCC 4.7 Link-Time Optimization Performance

Michael Larabel

Published on 21 August 2012
Written by Michael Larabel
Page 1 of 3 - 17 Comments

With the recent interest regarding Link-Time Optimization support within the Linux kernel by GCC, here are some benchmarks of the latest stable release of GCC (v4.7.1) when benchmarking several common open-source projects with and without the performance-enhancing LTO compiler support.

This article, which spawned out of the many LTO comments from the Linux kernel link-time optimization article, has a few benchmarks conducted since then from an Intel Ivy Bridge system. More GCC LTO benchmarks will come in a future article. GCC's Link-Time Optimization support allows for creating faster generated binaries at the cost of increased compile times and greater system memory (RAM) usage. When building software with the performance-oriented feature, link-time optimizations are applied on recent versions of the GNU Compiler Collection that allow for in-lining of functions between different files, performing various compile-time optimizations across the binary as a whole, dropping dead code, and running entire checks across the whole binary rather than just individual files.

As explained on the GCC Wiki, "Link Time Optimization (LTO) gives GCC the capability of dumping its internal representation (GIMPLE) to disk, so that all the different compilation units that make up a single executable can be optimized as a single module. This expands the scope of inter-procedural optimizations to encompass the whole program (or, rather, everything that is visible at link time)...The fundamental mechanism used by the compiler to delay optimization until link time is to write the GIMPLE representation of the program on special sections in the output file. For the initial implementation on the branch, ELF was chosen as the container format for these sections, but in GCC-4.6 support has been added on the trunk for PE-COFF and Mach-O. In order to use LTO the target must support one of these binary formats."

Using GCC LTO requires passing "-flto" compiler flag to enable the main Link-Time Optimization features. There's also a "-fwhopr" that is similar to "-flto" but splits compilation to achieve scalability for very large code-bases that cannot fit all in memory at once.

For this quick GCC 4.7.1 LTO benchmarking, the Intel Core i7 3517UE "Ivy Bridge" system was running Ubuntu 12.10 x86_64 with GCC 4.7.1 from the Ubuntu Quantal repository and then running several common computational test profiles with and without the "-flto" compiler flag. All other CFLAGS/CXXFLAGS options were maintained the same throughout the testing process. This benchmarking was handled in a fully automated manner using the open-source multi-platform Phoronix Test Suite software.

<< Previous Page
1
Latest Linux Hardware Reviews
  1. NVIDIA GeForce GTX 980: The Best GPU For Linux Gamers
  2. ROCCAT LUA: A Linux-Friendly Gaming Mouse
  3. Cheetah Mounts: The Affordable Way To Put Your TV On The Wall
  4. Scythe Mugen MAX
Latest Linux Articles
  1. Preview: Radeon Gallium3D Performance For CS:GO On Linux
  2. XWayland Linux Gaming Performance With GNOME Wayland On Fedora 21
  3. EXT4/Btrfs/XFS/F2FS Benchmarks On Linux 3.17
  4. Fedora 21 Alpha First Impressions: It's Great
Latest Linux News
  1. Fedora Might Try A New Scheduling Strategy For Its Releases
  2. AMD's Catalyst Working On A GLSL Shader Cache
  3. OpenMP 4.0 Offloading Is Closer For GCC 5
  4. Wayland Presentation Extension Added To Weston
  5. Intel Skylake Support Rolls Out To Mesa's DRM
  6. VA-API's Libva 1.4.0 Brings VP8 Encoding Support
  7. Operating System U Fails To Live Up To Its Goals
  8. AMD Catalyst 14.9 Officially Released For Linux
  9. Nouveau Memory Re-Clocking Comes For More NVIDIA GPUs
  10. NVIDIA Suggests Explicit Synchronization For Nouveau
Latest Forum Discussions
  1. NVIDIA Alerts Nouveau: They're Starting To Sign/Validate GPU Firmware Images
  2. New AMD Catalyst drivers out today
  3. Updated and Optimized Ubuntu Free Graphics Drivers
  4. Take the Steam Survey results with a grain of salt. It is flawed.
  5. FSF Issues Statement On Shellshock Bash Vulnerability
  6. AMD Wants To Know What's Wrong With Catalyst
  7. New Group Calls For Boycotting Systemd
  8. Counter-Strike: Global Offensive NVIDIA/AMD Benchmarks On Linux