1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-26 04:32:44 +01:00
llvm-mirror/test/CodeGen/RISCV
Craig Topper fa61017019 [SelectionDAG][RISCV] Use isSExtCheaperThanZExt to control whether sext or zext is used for constant folding any_extend.
RISCV would prefer a sign extended constant since that works better
with our constant materialization. We have an existing TLI hook we
use to control sign extension of setcc operands in type legalization.
That hook happens to do the right check we need here, but might be
straying from its original purpose. With only RISCV defining this
hook in tree, I wasn't sure if it was worth adding another hook
with identical behavior.

This is an alternative to D105785 where I tried to handle this in
the RISCV backend by not creating ANY_EXTENDs in some places.

Reviewed By: frasercrmck

Differential Revision: https://reviews.llvm.org/D105918
2021-07-19 09:25:28 -07:00
..
GlobalISel
intrinsics
rvv [RISCV] Teach computeKnownBitsForTargetNode that VLENB will never be more than 65536/8. 2021-07-17 11:24:20 -07:00
add-before-shl.ll
add-imm.ll [RISCV] Optimize addition with immediate 2021-04-26 13:26:17 +08:00
addc-adde-sube-subc.ll
addcarry.ll
addimm-mulimm.ll
addrspacecast.ll
aext-to-sext.ll [RISCV] Protect the SHL/SRA/SRL handlers in LowerOperation against being called for an illegal i32 shift amount. 2021-06-29 09:45:13 -07:00
align.ll
alloca.ll
alu8.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
alu16.ll [RISCV] Use SLLI/SRLI instead of SLLIW/SRLIW for (srl (and X, 0xffff), C) custom isel on RV64. 2021-04-11 13:59:51 -07:00
alu32.ll [SelectionDAG][RISCV] Use isSExtCheaperThanZExt to control whether sext or zext is used for constant folding any_extend. 2021-07-19 09:25:28 -07:00
alu64.ll
analyze-branch.ll
arith-with-overflow.ll
atomic-cmpxchg-flag.ll
atomic-cmpxchg.ll [AtomicExpand] Merge cmpxchg success and failure ordering when appropriate. 2021-06-03 11:34:35 -07:00
atomic-fence.ll
atomic-load-store.ll
atomic-rmw.ll
atomic-signext.ll [SelectionDAG][Mips][PowerPC][RISCV][WebAssembly] Teach computeKnownBits/ComputeNumSignBits about atomics 2021-05-20 20:34:23 +01:00
attributes.ll
blockaddress.ll
branch-relaxation.ll
branch.ll [RISCV] Add isel-patterns to optimize (a < 1) into blez (a <= 0) 2021-03-15 11:32:43 -07:00
bswap-ctlz-cttz-ctpop.ll [RISCV] Add tests for __builtin_parity idiom. 2021-06-27 12:37:29 -07:00
byval.ll
callee-saved-fpr32s.ll
callee-saved-fpr64s.ll
callee-saved-gprs.ll
calling-conv-half.ll [RISCV] Improve 64-bit integer constant materialization for more cases. 2021-04-02 10:18:08 -07:00
calling-conv-ilp32-ilp32f-common.ll
calling-conv-ilp32-ilp32f-ilp32d-common.ll
calling-conv-ilp32.ll
calling-conv-ilp32d.ll
calling-conv-ilp32f-ilp32d-common.ll
calling-conv-lp64-lp64f-common.ll
calling-conv-lp64-lp64f-lp64d-common.ll
calling-conv-lp64.ll
calling-conv-rv32f-ilp32.ll
calling-conv-sext-zext.ll
calls.ll [RISCV] Prevent use of t0(aka x5) as rs1 for jalr instructions. 2021-07-13 09:46:21 -07:00
cmp-bool.ll
codemodel-lowering.ll
compress-float.ll
compress-inline-asm.ll
compress.ll
copy-frameindex.mir CodeGen: Print/parse LLTs in MachineMemOperands 2021-06-30 16:54:13 -04:00
copysign-casts.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
disable-tail-calls.ll
disjoint.ll CodeGen: Print/parse LLTs in MachineMemOperands 2021-06-30 16:54:13 -04:00
div.ll [RISCV] Add more i32 srem/sdiv with power of 2 constant tests. NFC 2021-07-18 00:21:14 -07:00
double-arith.ll
double-bitmanip-dagcombines.ll [RISCV] Improve 64-bit integer materialization for some cases. 2021-04-01 09:12:52 -07:00
double-br-fcmp.ll
double-calling-conv.ll
double-convert.ll [RISCV] Use ComputeNumSignBits/MaskedValueIsZero in RISCVDAGToDAGISel::selectSExti32/selectZExti32. 2021-06-10 19:06:45 -07:00
double-fcmp.ll
double-frem.ll
double-imm.ll
double-intrinsics.ll [RISCV] Implement lround*/llround*/lrint*/llrint* with fcvt instruction with -fno-math-errno 2021-07-06 11:43:22 -07:00
double-isnan.ll
double-mem.ll
double-previous-failure.ll
double-select-fcmp.ll
double-stack-spill-restore.ll
dwarf-eh.ll
elf-preemption.ll [RISCV] Prefer to lower MC_GlobalAddress operands to .Lfoo$local 2021-05-11 11:29:45 -07:00
exception-pointer-register.ll
fastcc-float.ll
fastcc-int.ll
fixups-diff.ll test: clean up some of the RISCV tests (NFC) 2021-06-17 09:51:09 -07:00
fixups-relax-diff.ll test: clean up some of the RISCV tests (NFC) 2021-06-17 09:51:09 -07:00
float-arith.ll
float-bit-preserving-dagcombines.ll [RISCV] Improve 64-bit integer materialization for some cases. 2021-04-01 09:12:52 -07:00
float-bitmanip-dagcombines.ll
float-br-fcmp.ll
float-convert.ll [RISCV] Use ComputeNumSignBits/MaskedValueIsZero in RISCVDAGToDAGISel::selectSExti32/selectZExti32. 2021-06-10 19:06:45 -07:00
float-fcmp.ll
float-frem.ll
float-imm.ll
float-intrinsics.ll [RISCV] Implement lround*/llround*/lrint*/llrint* with fcvt instruction with -fno-math-errno 2021-07-06 11:43:22 -07:00
float-isnan.ll
float-mem.ll
float-select-fcmp.ll
flt-rounds.ll
fold-addi-loadstore.ll
fp16-promote.ll [RISCV] Use softPromoteHalf legalization for fp16 without Zfh rather than PromoteFloat. 2021-04-01 12:41:57 -07:00
fp128.ll
fp-imm.ll
fpenv.ll [RISCV] Custom lowering of SET_ROUNDING 2021-04-22 15:04:55 +07:00
frame-info.ll
frame.ll
frameaddr-returnaddr.ll
get-register-invalid.ll
get-register-noreserve.ll
get-register-reserve.ll
get-setcc-result-type.ll
ghccc-rv32.ll
ghccc-rv64.ll
half-arith.ll
half-bitmanip-dagcombines.ll [RISCV] Use softPromoteHalf legalization for fp16 without Zfh rather than PromoteFloat. 2021-04-01 12:41:57 -07:00
half-br-fcmp.ll
half-convert.ll [RISCV] Use ComputeNumSignBits/MaskedValueIsZero in RISCVDAGToDAGISel::selectSExti32/selectZExti32. 2021-06-10 19:06:45 -07:00
half-fcmp.ll
half-imm.ll
half-intrinsics.ll [RISCV] Implement lround*/llround*/lrint*/llrint* with fcvt instruction with -fno-math-errno 2021-07-06 11:43:22 -07:00
half-isnan.ll
half-mem.ll
half-select-fcmp.ll
hoist-global-addr-base.ll [RISCV] Add isel-patterns to optimize (a < 1) into blez (a <= 0) 2021-03-15 11:32:43 -07:00
i32-icmp.ll
imm-cse.ll
imm.ll [RISCV] Improve 64-bit integer constant materialization for more cases. 2021-04-02 10:18:08 -07:00
indirectbr.ll
init-array.ll
inline-asm-abi-names.ll
inline-asm-clobbers.ll
inline-asm-d-abi-names.ll
inline-asm-d-constraint-f.ll
inline-asm-f-abi-names.ll
inline-asm-f-constraint-f.ll
inline-asm-i-constraint-i1.ll
inline-asm-invalid.ll
inline-asm-S-constraint.ll [RISCV] Support machine constraint "S" 2021-07-13 09:30:09 -07:00
inline-asm.ll
interrupt-attr-args-error.ll
interrupt-attr-callee.ll
interrupt-attr-invalid.ll
interrupt-attr-nocall.ll
interrupt-attr-ret-error.ll
interrupt-attr.ll
jumptable.ll [CGP][RISCV] Teach CodeGenPrepare::optimizeSwitchInst to honor isSExtCheaperThanZExt. 2021-06-23 15:38:11 -07:00
large-stack.ll [RISCV] remove redundant instruction when eliminate frame index 2021-03-21 18:54:00 +08:00
legalize-fneg.ll
lit.local.cfg
lsr-legaladdimm.ll
machineoutliner.mir
mattr-invalid-combination.ll
mem64.ll
mem.ll
mir-target-flags.ll
module-target-abi2.ll
module-target-abi.ll
mul.ll [RISCV] Add custom type legalization to form MULHSU when possible. 2021-04-01 10:15:55 -07:00
musttail-call.ll
neg-abs.ll
nomerge.ll
option-nopic.ll
option-norelax.ll
option-norvc.ll
option-pic.ll
option-relax.ll
option-rvc.ll
out-of-reach-emergency-slot.mir
patchable-function-entry.ll Revert "[RISCV] Remove -riscv-no-aliases in favour of new -M no-aliases" 2021-05-29 15:11:37 +01:00
pic-models.ll
pr40333.ll
prefetch.ll
readcyclecounter.ll
rem.ll [RISCV] Add more i32 srem/sdiv with power of 2 constant tests. NFC 2021-07-18 00:21:14 -07:00
remat.ll
reserved-reg-errors.ll
reserved-regs.ll
rotl-rotr.ll
rv32e.ll
rv32i-rv64i-float-double.ll
rv32i-rv64i-half.ll [RISCV] Use softPromoteHalf legalization for fp16 without Zfh rather than PromoteFloat. 2021-04-01 12:41:57 -07:00
rv32zba.ll [RISCV][test] Add new tests for mul optimization in the zba extension with SH*ADD 2021-07-09 09:48:23 +08:00
rv32zbb-intrinsic.ll Recommit "[RISCV] Add IR intrinsic for Zbb extension" 2021-04-02 11:50:19 -07:00
rv32zbb-zbp.ll [RISCV] Teach DAG combine to fold (and (select_cc lhs, rhs, cc, -1, c), x) -> (select_cc lhs, rhs, cc, x, (and, x, c)) 2021-04-29 09:43:51 -07:00
rv32zbb.ll [RISCV] Rename Zb* extension tests to use lower case 'Z' in file names. 2021-03-22 19:17:04 -07:00
rv32zbc-intrinsic.ll [RISCV] Add IR intrinsics for Zbc extension 2021-04-02 12:09:13 -07:00
rv32zbe-intrinsic.ll [RISCV] [1/2] Add IR intrinsic for Zbe extension 2021-04-25 19:14:34 -07:00
rv32zbp-intrinsic.ll [RISCV] Teach DAG combine what bits Zbp instructions demanded from their inputs. 2021-04-25 21:54:06 -07:00
rv32zbp.ll [RISCV] Lower i8/i16 bswap/bitreverse to grevi/greviw with Zbp. 2021-06-07 10:31:51 -07:00
rv32zbr.ll [RISCV] Add IR intrinsic for Zbr extension 2021-04-02 10:58:45 -07:00
rv32zbs.ll [RISCV] Optimize bitwise and with constant for the Zbs extension 2021-06-08 07:26:00 +08:00
rv32zbt.ll [RISCV] Teach DAG combine to fold (and (select_cc lhs, rhs, cc, -1, c), x) -> (select_cc lhs, rhs, cc, x, (and, x, c)) 2021-04-29 09:43:51 -07:00
rv64-large-stack.ll
rv64d-double-convert.ll
rv64f-float-convert.ll
rv64f-half-convert.ll
rv64i-complex-float.ll
rv64i-demanded-bits.ll
rv64i-double-softfloat.ll
rv64i-exhaustive-w-insts.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
rv64i-single-softfloat.ll Update @llvm.powi to handle different int sizes for the exponent 2021-06-17 09:38:28 +02:00
rv64i-tricky-shifts.ll
rv64i-w-insts-legalization.ll [RISCV] Add isel pattern to optimize (mul (and X, 0xffffffff), (and Y, 0xffffffff)) on RV64 2021-03-20 14:55:46 -07:00
rv64m-exhaustive-w-insts.ll [RISCV] Have sexti32 also recognize AssertZExt from types smaller than i32. 2021-02-22 14:56:22 -08:00
rv64m-w-insts-legalization.ll
rv64zba.ll [RISCV] Teach constant materialization that it can use zext.w at the end with Zba to reduce number of instructions. 2021-07-16 09:35:56 -07:00
rv64zbb-intrinsic.ll [RISCV] Use gorciw for i32 orc.b intrinsic when Zbp is enabled. 2021-04-04 17:14:28 -07:00
rv64zbb-zbp.ll [SelectionDAG][RISCV] Use isSExtCheaperThanZExt to control whether sext or zext is used for constant folding any_extend. 2021-07-19 09:25:28 -07:00
rv64zbb.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
rv64zbc-intrinsic.ll [RISCV] Add IR intrinsics for Zbc extension 2021-04-02 12:09:13 -07:00
rv64zbe-intrinsic.ll [RISCV] Teach DAG combine what bits Zbp instructions demanded from their inputs. 2021-04-25 21:54:06 -07:00
rv64zbp-intrinsic.ll [RISCV] Teach DAG combine what bits Zbp instructions demanded from their inputs. 2021-04-25 21:54:06 -07:00
rv64zbp.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
rv64zbr.ll [RISCV] Add IR intrinsic for Zbr extension 2021-04-02 10:58:45 -07:00
rv64zbs.ll [RISCV] Optimize bitwise and with constant for the Zbs extension 2021-06-08 07:26:00 +08:00
rv64zbt.ll [RISCV] Rename Zb* extension tests to use lower case 'Z' in file names. 2021-03-22 19:17:04 -07:00
sadd_sat_plus.ll [RISCV] Add a special case to lowerSELECT for select of 2 constants with a SETLT condition. 2021-04-07 13:47:17 -07:00
sadd_sat.ll [RISCV] Add a special case to lowerSELECT for select of 2 constants with a SETLT condition. 2021-04-07 13:47:17 -07:00
saverestore.ll [RISCV] Don't emit save-restore call if function is a interrupt handler 2021-04-16 12:54:47 +08:00
scalable-vector-struct.ll [RISCV] Use whole register load/store for generic load/store. 2021-02-09 15:52:04 +08:00
sdata-limit-0.ll
sdata-limit-4.ll
sdata-limit-8.ll
sdata-local-sym.ll
select-and.ll
select-bare.ll
select-binop-identity.ll [RISCV] Teach DAG combine to fold (and (select_cc lhs, rhs, cc, -1, c), x) -> (select_cc lhs, rhs, cc, x, (and, x, c)) 2021-04-29 09:43:51 -07:00
select-cc.ll [RISCV] Teach normaliseSetCC to canonicalize X > -1 to X >= 0 and X < 1 to 0 >= X. 2021-03-12 11:50:10 -08:00
select-const.ll
select-optimize-multiple.ll
select-optimize-multiple.mir
select-or.ll
setcc-logic.ll
sext-zext-trunc.ll
shadowcallstack.ll
shift-masked-shamt.ll
shifts.ll
shrinkwrap.ll
spill-fpr-scalar.ll [RISCV][NFC] Add a single space after comma for VType 2021-06-09 11:18:22 +08:00
split-offsets.ll
split-sp-adjust.ll
srem-lkk.ll [TargetLowering][RISCV][AArch64][PowerPC] Enable BuildUDIV/BuildSDIV on illegal types before type legalization if we can find a larger legal type that supports MUL. 2021-02-11 09:43:13 -08:00
srem-seteq-illegal-types.ll [RISCV][NFC] Add a single space after comma for VType 2021-06-09 11:18:22 +08:00
srem-vector-lkk.ll [RISCV] Improve 64-bit integer materialization for some cases. 2021-04-01 09:12:52 -07:00
ssub_sat_plus.ll [RISCV] Add a special case to lowerSELECT for select of 2 constants with a SETLT condition. 2021-04-07 13:47:17 -07:00
ssub_sat.ll [RISCV] Add a special case to lowerSELECT for select of 2 constants with a SETLT condition. 2021-04-07 13:47:17 -07:00
stack-realignment-with-variable-sized-objects.ll
stack-realignment.ll [RISCV] remove redundant instruction when eliminate frame index 2021-03-21 18:54:00 +08:00
stack-slot-size.ll [RISCV] Fix stack slot for argument types (Bug 49500) 2021-04-29 09:10:48 +01:00
stack-store-check.ll
subtarget-features-std-ext.ll
tail-calls.ll [RISCV] Prevent use of t0(aka x5) as rs1 for jalr instructions. 2021-07-13 09:46:21 -07:00
target-abi-invalid.ll
target-abi-valid.ll
thread-pointer.ll
tls-models.ll
uadd_sat_plus.ll [RISCV] Improve i32 UADDSAT/USUBSAT on RV64. 2021-03-16 07:44:06 -07:00
uadd_sat.ll [RISCV] Improve i32 UADDSAT/USUBSAT on RV64. 2021-03-16 07:44:06 -07:00
umulo-128-legalisation-lowering.ll
urem-lkk.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
urem-seteq-illegal-types.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
urem-vector-lkk.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
usub_sat_plus.ll [RISCV] Improve i32 UADDSAT/USUBSAT on RV64. 2021-03-16 07:44:06 -07:00
usub_sat.ll [RISCV] Improve i32 UADDSAT/USUBSAT on RV64. 2021-03-16 07:44:06 -07:00
vararg.ll [RISCV] remove redundant instruction when eliminate frame index 2021-03-21 18:54:00 +08:00
vec3-setcc-crash.ll Revert "[RISCV] Use zexti32/sexti32 in srliw/sraiw isel patterns to improve usage of those instructions." 2021-06-27 10:33:43 -07:00
vector-abi.ll CodeGen: Print/parse LLTs in MachineMemOperands 2021-06-30 16:54:13 -04:00
verify-instr.mir
wide-mem.ll
xaluo.ll [SelectionDAG][RISCV] Use isSExtCheaperThanZExt to control whether sext or zext is used for constant folding any_extend. 2021-07-19 09:25:28 -07:00
zext-with-load-is-free.ll
zfh-imm.ll