PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Anandtech: Mac OS X: beautiful but... Performance problems


Gast
2005-06-05, 10:26:05
http://www.anandtech.com/mac/showdoc.aspx?i=2436&p=7


Was ist davon zu halten?

Gast
2005-06-05, 10:27:24
Ergänzung:


Mac OS X is incredibly slow, between 2 and 5(!) times slower, in creating new threads, as it doesn't use kernel threads, and has to go through extra layers (wrappers). No need to continue our search: the G5 might not be the fastest integer CPU on earth - its database performance is completely crippled by an asthmatic operating system that needs up to 5 times more time to handle and create threads.
http://www.anandtech.com/mac/showdoc.aspx?i=2436&p=8

Gast
2005-06-05, 10:30:21
http://www.macuser.de/forum/showthread.php?t=96267

Ganon
2005-06-05, 10:32:02
Ja. Das Ergebnis ist, das OS X für Server ungeeignet ist.

Das ist unter den "OS X Kennern" und selbst bei Apple (auch wenn sie OS X Server verkaufen ;)) bekannt.

Apple arbeitet dran und Server-Admins nehmen Linux. ;)

Gast
2005-06-05, 10:35:53
Sollte sich aber zum Teil auch auf dem Desktop auswirken?

Arbeitet wirklich Apple dran? Ist doch nichts neues oder?

Gast
2005-06-05, 10:37:33
Performance problems
As the mach kernel is hidden away deep in the FreeBSD kernel, Mach (kernel) threads are only available for kernel level programs, not applications such as MySQL. Applications can make use of a POSIX thread (a " pthread"), a wrapper around a Mach thread.


http://images.anandtech.com/reviews/cpu/mac_compared/tn2028_3.gif

Mac OS X thread layering hierarchy (Courtesy: Apple)
This means that applications use slower user-level threads like in FreeBSD and not fast kernel threads like in Linux. It seems that FreeBSD 5.x has somewhat solved the performance problems that were typical for user-level threads, but we are not sure if Mac OS X has been able to take advantage of this.

In order to maintain binary compatibility, Apple might not have been able to implement some of the performance improvements found in the newer BSD kernels.

Another problem is the way threads could/can get access to the kernel. In the early versions of Mac OS X, only one thread could lock onto the kernel at once. This doesn't mean only one thread can run, but that only one thread could access the kernel at a given time. So, a rendering calculation (no kernel interaction) together with a network access (kernel access) could run well. But many threads demanding access to the memory or network subsystem would result in one thread getting access, and all others waiting.

This "kernel locked bottleneck" situation has improved in Tiger, but kernel locking is still very coarse. So, while there is a very fine grained multi-threading system (The Mach kernel) inside that monolithic kernel, it is not available to the outside world.

So, is Mac OS X the real reason why MySQL and Apache run so slow on the Mac Platform? Let us find out... with benchmarks, of course!

Ganon
2005-06-05, 10:40:45
Sollte sich aber zum Teil auch auf dem Desktop auswirken?

Arbeitet wirklich Apple dran? Ist doch nichts neues oder?

Also auf dem Desktop wirkt sich das nicht sonderlich aus. Anwenderprogramme benötigen nicht allzu oft die bemängelten Features. Das sind meist rein Server-Sachen.

Oder hast du schon mal einen unterschied zwischen FreeBSD, Linux und OS X bei Programmen wie OpenOffice, oder FireFox bemerkt? Da zählen andere Sachen.
Und das OpenOffice auf meinem Mac schneller startet und auch besser läuft als auf einem stärkeren PC (1,2Ghz gegen 2Ghz) (egal ob Linux oder Windows), zeigt das es nicht relevant ist. ;)

Apple arbeitet wirklich daran. Darum hat man auch in Tiger den Kernel in großen Teilen geändert. Steht auch im Text.

edit:
Poste doch gleich den ganzen Artikel. Ich glaube auf nen Link können alle klicken. ;)

Gast
2005-06-05, 10:42:22
Könnte Apple eigentlich den OSX-Unterbau "problemlos" wechseln, wenn etwas anderes Unixartiges besser geeignet wäre/gäbe... ?

Ganon
2005-06-05, 10:46:06
Keine Ahnung. Wenn man sich aber die bemängelte Kapselung anguckt, kann man das annehmen.

Ganon
2005-06-05, 10:51:38
Achja.

Entsprechende Programme sind eh meist plattformunabhängig programmiert. D.h. die wenigsten nutzen LinuxKernel-Threads. Das sind meist nur Server-Programme.

Und wenn man unter OS X Cocoa nutzt, dann ist Performance eher nebensächlich (da komplettes Modell über Nachrichten). Da zählt einfache Programmierung und Benutzerfreundlichkeit.

Deswegen lautet das Fazit auch:

"Workstation yes, Server no"

Lokadamus
2005-06-05, 11:37:50
Könnte Apple eigentlich den OSX-Unterbau "problemlos" wechseln, wenn etwas anderes Unixartiges besser geeignet wäre/gäbe... ?mmm...

Unwahrscheinlich, da BSD eine andere Lizenz hat als Linux. Bei Linux hätten sie nach kürzester Zeit immer wieder Streitigkeiten, weil sie den Kernelsource dann veröffentlichen müssten ...

Edit: Haben sie nur Linux als Gegenstück herangezogen? Hätten auch FreeBSD miteinbeziehen können ...