mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-17 18:31:04 +00:00
0488fb649a
The x86_mmx type is used for MMX intrinsics, parameters and return values where these use MMX registers, and is also supported in load, store, and bitcast. Only the above operations generate MMX instructions, and optimizations do not operate on or produce MMX intrinsics. MMX-sized vectors <2 x i32> etc. are lowered to XMM or split into smaller pieces. Optimizations may occur on these forms and the result casted back to x86_mmx, provided the result feeds into a previous existing x86_mmx operation. The point of all this is prevent optimizations from introducing MMX operations, which is unsafe due to the EMMS problem. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115243 91177308-0d34-0410-b5e6-96231b3b80d8
36 lines
910 B
LLVM
36 lines
910 B
LLVM
; RUN: llc < %s -relocation-model=static -march=x86 -mcpu=yonah | grep pxor | count 1
|
|
; RUN: llc < %s -relocation-model=static -march=x86 -mcpu=yonah | grep pcmpeqd | count 1
|
|
; 64-bit stores here do not use MMX.
|
|
|
|
@M1 = external global <1 x i64>
|
|
@M2 = external global <2 x i32>
|
|
|
|
@S1 = external global <2 x i64>
|
|
@S2 = external global <4 x i32>
|
|
|
|
define void @test() {
|
|
store <1 x i64> zeroinitializer, <1 x i64>* @M1
|
|
store <2 x i32> zeroinitializer, <2 x i32>* @M2
|
|
ret void
|
|
}
|
|
|
|
define void @test2() {
|
|
store <1 x i64> < i64 -1 >, <1 x i64>* @M1
|
|
store <2 x i32> < i32 -1, i32 -1 >, <2 x i32>* @M2
|
|
ret void
|
|
}
|
|
|
|
define void @test3() {
|
|
store <2 x i64> zeroinitializer, <2 x i64>* @S1
|
|
store <4 x i32> zeroinitializer, <4 x i32>* @S2
|
|
ret void
|
|
}
|
|
|
|
define void @test4() {
|
|
store <2 x i64> < i64 -1, i64 -1>, <2 x i64>* @S1
|
|
store <4 x i32> < i32 -1, i32 -1, i32 -1, i32 -1 >, <4 x i32>* @S2
|
|
ret void
|
|
}
|
|
|
|
|