mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-26 07:29:55 +00:00
Essentially the same as the GEP change in r230786. A similar migration script can be used to update test cases, though a few more test case improvements/changes were required this time around: (r229269-r229278) import fileinput import sys import re pat = re.compile(r"((?:=|:|^)\s*load (?:atomic )?(?:volatile )?(.*?))(| addrspace\(\d+\) *)\*($| *(?:%|@|null|undef|blockaddress|getelementptr|addrspacecast|bitcast|inttoptr|\[\[[a-zA-Z]|\{\{).*$)") for line in sys.stdin: sys.stdout.write(re.sub(pat, r"\1, \2\3*\4", line)) Reviewers: rafael, dexonsmith, grosser Differential Revision: http://reviews.llvm.org/D7649 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@230794 91177308-0d34-0410-b5e6-96231b3b80d8
46 lines
1.3 KiB
LLVM
46 lines
1.3 KiB
LLVM
; RUN: llc < %s
|
|
; PR2671
|
|
|
|
define void @a(<2 x double>* %p, <2 x i8>* %q) {
|
|
%t = load <2 x double>, <2 x double>* %p
|
|
%r = fptosi <2 x double> %t to <2 x i8>
|
|
store <2 x i8> %r, <2 x i8>* %q
|
|
ret void
|
|
}
|
|
define void @b(<2 x double>* %p, <2 x i8>* %q) {
|
|
%t = load <2 x double>, <2 x double>* %p
|
|
%r = fptoui <2 x double> %t to <2 x i8>
|
|
store <2 x i8> %r, <2 x i8>* %q
|
|
ret void
|
|
}
|
|
define void @c(<2 x i8>* %p, <2 x double>* %q) {
|
|
%t = load <2 x i8>, <2 x i8>* %p
|
|
%r = sitofp <2 x i8> %t to <2 x double>
|
|
store <2 x double> %r, <2 x double>* %q
|
|
ret void
|
|
}
|
|
define void @d(<2 x i8>* %p, <2 x double>* %q) {
|
|
%t = load <2 x i8>, <2 x i8>* %p
|
|
%r = uitofp <2 x i8> %t to <2 x double>
|
|
store <2 x double> %r, <2 x double>* %q
|
|
ret void
|
|
}
|
|
define void @e(<2 x i8>* %p, <2 x i16>* %q) {
|
|
%t = load <2 x i8>, <2 x i8>* %p
|
|
%r = sext <2 x i8> %t to <2 x i16>
|
|
store <2 x i16> %r, <2 x i16>* %q
|
|
ret void
|
|
}
|
|
define void @f(<2 x i8>* %p, <2 x i16>* %q) {
|
|
%t = load <2 x i8>, <2 x i8>* %p
|
|
%r = zext <2 x i8> %t to <2 x i16>
|
|
store <2 x i16> %r, <2 x i16>* %q
|
|
ret void
|
|
}
|
|
define void @g(<2 x i16>* %p, <2 x i8>* %q) {
|
|
%t = load <2 x i16>, <2 x i16>* %p
|
|
%r = trunc <2 x i16> %t to <2 x i8>
|
|
store <2 x i8> %r, <2 x i8>* %q
|
|
ret void
|
|
}
|