Dr. Dobb's is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.


Channels ▼
RSS

Open Source

Optimizing Open-Source Software for Intel Architectures


Max is a software engineer at Intel's Software Products Division.

Harry is a product-line marketing manager at Intel's Software Products Division.


Compiler optimization plays an important role in the performance of open-source applications. Default optimization settings are often used during compilation that, in effect, leave some application performance unrealized. Through the use of aggressive compiler optimization, many applications show appreciable increases in performance. In many cases, you can increase the performance of an application in situations where detailed performance analysis is impractical. Understanding the techniques used to apply higher optimization settings and some of the benefits and costs of doing so is essential to improve end-user application performance.

The MySQL open-source database (www.mysql.com) is widely used to manage corporate data, handle transactions, and run e-commerce and data warehousing applications. It is a key component of LAMP, a web server solution consisting of Linux, Apache, MySQL, and PHP/Python/Perl. MySQL is available on many 32- and 64-bit platforms, including Linux, UNIX, BSD, Apple, Windows, IA-32, Power PC, and SPARC. In this article, we focus on MySQL 4.1.12 running on Linux and Intel architectures. However, the process can be applied to other platforms as well.

The GNU Compiler Collection includes a C and C++ compiler, typically referred to as "gcc" and "g++," respectively. Here we refer to these compilers collectively as "GCC." The compiler is available for numerous architectures and operating systems, and offers good performance and compatibility with C/C++ language standards. While we focus on Versions 3.4.4 and 3.2.3, the techniques we describe are valid for earlier or later versions of the compiler.

For its part, the Intel C++ Compiler is an optimizing compiler offered on operating systems such as Windows and Linux, and on architectures such as IA-32, Itanium, and systems with Intel EM64T. The Intel Compiler offers good conformance to C and C++ standards, as well as binary compatibility with GCC. The Intel Compiler is tuned to offer high performance on Intel architecture processors, taking advantage of the latest microarchitectural features. In this article, we refer to Version 9.0, although the techniques can be applied to other versions.


Related Reading


More Insights