summaryrefslogtreecommitdiff
path: root/lib/Target/ARM/ARMISelLowering.h
diff options
context:
space:
mode:
authorNadav Rotem <nrotem@apple.com>2012-09-02 12:10:19 +0000
committerNadav Rotem <nrotem@apple.com>2012-09-02 12:10:19 +0000
commit9f40cb32ac31283f8636d516e7b10f3ad921955c (patch)
tree975488b92abdc8d73e2313554cff5e927e5f48f7 /lib/Target/ARM/ARMISelLowering.h
parent7de7078933292b0487f1f39f539bece922e3dde5 (diff)
downloadllvm-9f40cb32ac31283f8636d516e7b10f3ad921955c.tar.gz
llvm-9f40cb32ac31283f8636d516e7b10f3ad921955c.tar.bz2
llvm-9f40cb32ac31283f8636d516e7b10f3ad921955c.tar.xz
Not all targets have efficient ISel code generation for select instructions.
For example, the ARM target does not have efficient ISel handling for vector selects with scalar conditions. This patch adds a TLI hook which allows the different targets to report which selects are supported well and which selects should be converted to CF duting codegen prepare. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163093 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMISelLowering.h')
-rw-r--r--lib/Target/ARM/ARMISelLowering.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Target/ARM/ARMISelLowering.h b/lib/Target/ARM/ARMISelLowering.h
index 13b83de85d..757c68ee37 100644
--- a/lib/Target/ARM/ARMISelLowering.h
+++ b/lib/Target/ARM/ARMISelLowering.h
@@ -257,6 +257,11 @@ namespace llvm {
virtual const char *getTargetNodeName(unsigned Opcode) const;
+ virtual bool isSelectSupported(SelectSupportKind Kind) const {
+ // ARM does not support scalar condition selects on vectors.
+ return (Kind != ScalarCondVectorVal);
+ }
+
/// getSetCCResultType - Return the value type to use for ISD::SETCC.
virtual EVT getSetCCResultType(EVT VT) const;