1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-29 23:12:55 +01:00
llvm-mirror/test/CodeGen/X86/bitcast-i256.ll
Michael Liao 7c620b0d5f Enhance type legalization on bitcast from vector to integer
- Find a legal vector type before casting and extracting element from it.
- As the new vector type may have more than 2 elements, build the final
  hi/lo pair by BFS pairing them from bottom to top.

llvm-svn: 163830
2012-09-13 19:58:21 +00:00

12 lines
269 B
LLVM

; RUN: llc -mtriple=x86_64-unknown-unknown -mcpu=core-avx-i < %s | FileCheck %s --check-prefix CHECK
define i256 @foo(<8 x i32> %a) {
%r = bitcast <8 x i32> %a to i256
ret i256 %r
; CHECK: foo
; CHECK: vextractf128
; CHECK: vpextrq
; CHECK: vpextrq
; CHECK: ret
}