[SelectionDAG] Disallow indirect "i" constraint
authorFangrui Song <maskray@google.com>
Sun, 29 Dec 2019 23:53:46 +0000 (15:53 -0800)
committerFangrui Song <maskray@google.com>
Mon, 30 Dec 2019 00:50:42 +0000 (16:50 -0800)
commit5edb40c0220e80fc4cdb726d30d1d8b8e8580892
treede4d76facba3a43fd169a68ae019ea66e9975690
parentb1fb07ddbaa539f9173e32dc27110168b165c1fe
[SelectionDAG] Disallow indirect "i" constraint

This allows us to delete InlineAsm::Constraint_i workarounds in
SelectionDAGISel::SelectInlineAsmMemoryOperand overrides and
TargetLowering::getInlineAsmMemConstraint overrides.

They were introduced to X86 in r237517 to prevent crashes for
constraints like "=*imr". They were later copied to other targets.
13 files changed:
llvm/include/llvm/CodeGen/TargetLowering.h
llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
llvm/lib/Target/AArch64/AArch64ISelDAGToDAG.cpp
llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp
llvm/lib/Target/Hexagon/HexagonISelDAGToDAG.cpp
llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp
llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp
llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
llvm/lib/Target/Sparc/SparcISelDAGToDAG.cpp
llvm/lib/Target/WebAssembly/WebAssemblyISelDAGToDAG.cpp
llvm/lib/Target/X86/X86ISelDAGToDAG.cpp
llvm/lib/Target/X86/X86ISelLowering.h