[llvm] r348655 - [Hexagon] Fix post-ra expansion of PS_wselect
Krzysztof Parzyszek via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 7 14:00:53 PST 2018
Author: kparzysz
Date: Fri Dec 7 14:00:53 2018
New Revision: 348655
URL: http://llvm.org/viewvc/llvm-project?rev=348655&view=rev
Log:
[Hexagon] Fix post-ra expansion of PS_wselect
Added:
llvm/trunk/test/CodeGen/Hexagon/expand-wselect.mir
Modified:
llvm/trunk/lib/Target/Hexagon/HexagonInstrInfo.cpp
Modified: llvm/trunk/lib/Target/Hexagon/HexagonInstrInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Hexagon/HexagonInstrInfo.cpp?rev=348655&r1=348654&r2=348655&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Hexagon/HexagonInstrInfo.cpp (original)
+++ llvm/trunk/lib/Target/Hexagon/HexagonInstrInfo.cpp Fri Dec 7 14:00:53 2018
@@ -1293,7 +1293,6 @@ bool HexagonInstrInfo::expandPostRAPseud
auto T = BuildMI(MBB, MI, DL, get(Hexagon::V6_vccombine))
.add(Op0)
.addReg(PReg, S)
- .add(Op1)
.addReg(SrcHi)
.addReg(SrcLo);
if (IsDestLive)
Added: llvm/trunk/test/CodeGen/Hexagon/expand-wselect.mir
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Hexagon/expand-wselect.mir?rev=348655&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/Hexagon/expand-wselect.mir (added)
+++ llvm/trunk/test/CodeGen/Hexagon/expand-wselect.mir Fri Dec 7 14:00:53 2018
@@ -0,0 +1,13 @@
+# RUN: llc -march=hexagon -run-pass postrapseudos %s -o - | FileCheck %s
+
+# Check that this doesn't crash.
+# CHECK: $w2 = V6_vccombine $p0, $v1, $v0
+# CHECK: $w2 = V6_vnccombine killed $p0, $v3, $v2, implicit $w2
+
+name: fred
+tracksRegLiveness: true
+body: |
+ bb.0:
+ liveins: $p0, $w0, $w1
+ $w2 = PS_wselect killed $p0, killed $w0, killed $w1
+---
More information about the llvm-commits
mailing list