Mercurial > projects > dstress
annotate run/a/asm_movups_01_A.d @ 1630:d0efa3ae5522 default tip
run/mini/naked_asm5: New x86_64 ABI passes the arguments in reverse order.
author | David Nadlinger <code@klickverbot.at> |
---|---|
date | Sat, 23 Apr 2011 22:57:32 +0200 |
parents | 236f0d02b8b9 |
children |
rev | line source |
---|---|
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
1 // $HeadURL$ |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
2 // $Date$ |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
3 // $Author$ |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
4 |
1265 | 5 // __DSTRESS_TORTURE_BLOCK__ -fPIC |
6 | |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
7 module dstress.run.a.asm_movups_01_A; |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
8 |
1010 | 9 version(D_InlineAsm_X86){ |
10 version = runTest; | |
11 }else version(D_InlineAsm_X86_64){ | |
12 version = runTest; | |
13 } | |
14 | |
15 version(runTest){ | |
16 import addon.cpuinfo; | |
17 | |
18 int main(){ | |
19 haveSSE!()(); | |
20 | |
1265 | 21 float[4] a = [1.0f, 2.0f, 3.0f, 4.0f]; |
22 float[4] b; | |
1044 | 23 |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
24 asm{ |
1265 | 25 movdqu XMM0, a; |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
26 movups b, XMM0; |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
27 } |
1044 | 28 |
1265 | 29 if(b[0] != a[0]){ |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
30 assert(0); |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
31 } |
1265 | 32 if(b[1] != a[1]){ |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
33 assert(0); |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
34 } |
1265 | 35 if(b[2] != a[2]){ |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
36 assert(0); |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
37 } |
1265 | 38 if(b[3] != a[3]){ |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
39 assert(0); |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
40 } |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
41 |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
42 return 0; |
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
43 } |
1010 | 44 }else{ |
45 pragma(msg, "DSTRESS{XFAIL}: no inline ASM support"); | |
46 static assert(0); | |
983
642e3fea11a9
extended SSE tests - most of them are broken, see http://d.puremagic.com/bugzilla/show_bug.cgi?id=115
thomask
parents:
diff
changeset
|
47 } |