sMmx/de: what changed
Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.
Title: sMmx/de
| Old | New | Line | |
|---|---|---|---|
| 1 | + | Zurück zu den [[local compiler directives/de|lokalen Compiler Direktiven]].\ | |
| 2 | + | ||
| 3 | + | =\$MMX= Die Direktive \$MMX gilt nur für Intel 80x86 und kompatible Prozessoren.\ | |
| 4 | + | Die Direktive \$MMX bestimmt, ob der MMX Prozessor verwendet wird.\ | |
| 5 | + | Die Direktive \$MMX kennt zwei Schalter + und -.\ | |
| 6 | + | Die Verwendung des MMX Prozessors erhöht bei grösseren Datenmengen die Zuweisungsgeschwindigkeit von Fliesskommazahlen erheblich.\ | |
| 7 | + | ||
| 8 | + | Beispiel:\ | |
| 9 | + | ||
| 10 | + | Program MMXDemo; | |
| 11 | + | ||
| 12 | + | uses mmx; | |
| 13 | + | ||
| 14 | + | var | |
| 15 | + | dblZahl : double; | |
| 16 | + | arrDblZahl : array[0..10000] of double; | |
| 17 | + | lngI : longint; | |
| 18 | + | ||
| 19 | + | begin | |
| 20 | + | dblZahl := 1.0; | |
| 21 | + | {$mmx+} | |
| 22 | + | // es werden Fliesskommazahlen verwendet, aber es wird nichts berechnet | |
| 23 | + | for lngI := 0 to 10000 do | |
| 24 | + | arrDblZahl[lngI] := dblZahl; // hier findet eine 64 Bit Zuweisung statt | |
| 25 | + | {$mmx-} | |
| 26 | + | emms; // leert die FPU | |
| 27 | + | // nun können Fliesskommaberechnungen stattfinden | |
| 28 | + | ... | |
| 29 | + | end. | |
| 30 | + | ||
| 31 | + | --Olaf 16:36, 7 January 2013 (UTC) | |
| 32 | + | ||
| 33 | + | --- | |
| 34 | + | *From the Free Pascal wiki, page "sMmx/de", as it stood on 2013-04-21 after a change by Olaf, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).* | |
| 35 | + | Category: Free Pascal Programmers Guide/de |
