File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -1707,7 +1707,8 @@ bool PPCFastISel::SelectRet(const Instruction *I) {
1707
1707
1708
1708
// Special case for returning a constant integer of any size - materialize
1709
1709
// the constant as an i64 and copy it to the return register.
1710
- if (const ConstantInt *CI = dyn_cast<ConstantInt>(RV)) {
1710
+ if (isa<ConstantInt>(RV) && RV->getType ()->isIntegerTy ()) {
1711
+ const ConstantInt *CI = cast<ConstantInt>(RV);
1711
1712
CCValAssign &VA = ValLocs[0 ];
1712
1713
1713
1714
Register RetReg = VA.getLocReg ();
Original file line number Diff line number Diff line change 3
3
; RUN: llc -verify-machineinstrs -O0 -mcpu=pwr7 -mtriple=powerpc64-ibm-aix-xcoff -vec-extabi < %s | FileCheck %s --check-prefixes=CHECK,BE
4
4
; RUN: llc -verify-machineinstrs -O0 -mcpu=pwr7 -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=CHECK,LE
5
5
6
+ ; RUN: llc -verify-machineinstrs -O0 -mcpu=pwr7 -mtriple=powerpc64-unknown-linux-gnu -use-constant-int-for-fixed-length-splat -use-constant-fp-for-fixed-length-splat < %s | FileCheck %s --check-prefixes=CHECK,BE
7
+ ; RUN: llc -verify-machineinstrs -O0 -mcpu=pwr7 -mtriple=powerpc64-ibm-aix-xcoff -vec-extabi -use-constant-int-for-fixed-length-splat -use-constant-fp-for-fixed-length-splat < %s | FileCheck %s --check-prefixes=CHECK,BE
8
+ ; RUN: llc -verify-machineinstrs -O0 -mcpu=pwr7 -mtriple=powerpc64le-unknown-linux-gnu -use-constant-int-for-fixed-length-splat -use-constant-fp-for-fixed-length-splat < %s | FileCheck %s --check-prefixes=CHECK,LE
9
+
6
10
define void @test1 (ptr %P1 , ptr %P2 , ptr %P3 ) nounwind {
7
11
; BE-LABEL: test1:
8
12
; BE: # %bb.0:
You can’t perform that action at this time.
0 commit comments