Hyperthreading, SMP and InterBase, Firebird, Yaffil

Dmitri Kouzmenko

kdv@ib-aid.com

When one uses either Firebird/ Yaffil Classic or InterBase 7.1/7.5, the following questions are often asked: “what server to choose, a multiprocessor, or a single- processor one?” and “should Hyper-Threading be enabled on the server or not?”

It’s quite possible that if the server is purchased from the hardware provider, such questions do not arise, since in such cases basic configuration is used (for example, a dual-processor server with HT).

However, different tests and comments witness to the fact that it makes sense to use (keep enabled) the hyperthreading technology only on single-processor workstations (!), and not on servers. There are many reasons why Hyper- threading should be turned off on the server:

Note: Each paragraph contains a link to a document, which exemplifies “why it is so.” But this does not mean that the conclusion in a particular paragraph is drawn from that document. You, of course, will be able to find on the Internet corroboration of the described facts and our experience. We followed our own experience and tests results, and we have analyzed some reports (tests) of other people, as well as many different documents concerning HyperThreading.

1. Database-application (Firebird, Interbase, Yaffil) is an application, which actively uses both the processor and disk memory. At the same time, the percentage of processor and disk charge may vary.

Total charge of several real (as well as virtual) processors can occur only on “calculating” applications.

2. Enabling HT on a double-processor computer leads to appearance of four processors (which are 2 physical and 2 virtual). Thus, when all processors are used, the processor bus becomes more loaded. As a result, instead of productivity increase, the system performance would slowdown by 10-15%.

3. According to different reports, enabling HT slightly increases productivity, decreases it, or does not affect productivity at all. Therefore, the result can be seen only when analyzing a particular combination of motherboard, memory, and processors. [conferences ia newsgroups]

4. As Intel and Microsoft claim, Windows 2003 is the only operating system “certified” for HyperThreading. Therefore, if one uses either Windows NT or Windows 2000, it is most likely that if HT is enabled, productivity would be the same or would decrease. The same is true for Linux, i.e. HT should be enabled using appropriate versions of this OS.

http://www.intel.com/support/pla tform/ht/os.htm?iid=ipp_htm+os&

Note: InterBase 7.1 tests on Windows 2000 and Windows2003 with enabled HyperThreading have shown that Win 2000’s productivity becomes worse. At the same time, it is similar for both OS’, if HT is disabled. That is why the ibconfig ENABLE_HYPERTHREADING parameter for IB 7.1 is disabled by default.

5. Generally, there are applications, which may work incorrectly (fail) on multiprocessor computers if HyperThreading is enabled. (search Google for bsod+hyperthreading)

6. The HyperThreading technology is designed for increasing of multi-thread applications’ productivity. Therefore, execution speed of two processes on two virtual processors would be slower than it is on two physical processors. If in addition to a database, some applications are active on the server, then enabling HT would cause decrease of general productivity (this does not concern single-processor systems, in which a slightly increase of productivity may be).

http://www.intel.com/technology/ hyperthread/

Supplement

While we hope you understood that HyperThreading must be turned off on server, it is still not clear whether it is better to use a single-processor server, or a multiprocessor one. The answer to that question depends on architecture of the server and operating system: In the “2 and more processors ” column:

“No” - not recommended or it makes sense to tie a server process to a specific processor (for example, for Windows through the ibaffinity utility or through the CPU_AFFINITY parameter in ibconfig/fire- bird.conf).

“Yes” - this server variant with this operating system will use all processors. In IB 7.x, it is required to purchase proces- sor license for each additional physical processor.

For clarity sake, “yes” variants in the table are typed in bold.

Server Server type Operating system 2 and more processors
InterBase 6.0 SuperServer Windows No
Linux No
Solaris-SPARC No
Classic Linux Yes
InterBase 6.5 SuperServer Windows No
Linux No
Solaris-SPARC No
InterBase 7.x SuperServer Windows Yes
Linux Yes
Solaris-SPARC Yes
Firebird 1.0 SuperServer Windows No
Linux No
Solaris-x86 No
HP-UX No
Classic Linux Yes
Solaris-x86 Yes
Solaris-SPARC Yes
FreeBSD Yes
MacOS/X Yes
HP-UX Yes
Firebird 1.5 SuperServer Windows No
Linux No
Classic Windows Yes
Linux Yes
FreeBSD Yes
MacOS/X Yes
Sinixz Yes
Solaris-x86 Yes
Yaffil SuperServer Windows No
Classic Windows Yes

One Response to “Hyperthreading, SMP and InterBase, Firebird, Yaffil”

  1. Administrator Says:

    Interesting article about HyperThreading pro and contras:

    “Hyperthreading hurts server performance, say developers”, Rupert Goodwins, ZDNet UK, November 18, 2005, 11:55 GMT

    http://news.zdnet.co.uk/0,39020330,39237341,00.htm

Leave a Reply

You must be logged in to post a comment.