summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-08-15 16:07:47 +0000
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-08-15 16:07:47 +0000
commit46ce441df678c48d2708bb7cceb55fccba4f5884 (patch)
tree51fe3d1e0cdf3bd1f854fce1b839df67f76b31fd /llvm/lib
parent46fc95923c08f38b74e3edc5593fa471a9017fa4 (diff)
downloadbcm5719-llvm-46ce441df678c48d2708bb7cceb55fccba4f5884.tar.gz
bcm5719-llvm-46ce441df678c48d2708bb7cceb55fccba4f5884.zip
[RegAlloc] Check that subreg liveness tracking applies to given virtual reg
Subregister liveness applies selectively to register classes with certain properties. Make sure that when it's enabled, it applies to a given virtual register (in virtual register rewriter). llvm-svn: 339784
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/VirtRegMap.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/VirtRegMap.cpp b/llvm/lib/CodeGen/VirtRegMap.cpp
index 0ead2b8340a..ed7bef667e7 100644
--- a/llvm/lib/CodeGen/VirtRegMap.cpp
+++ b/llvm/lib/CodeGen/VirtRegMap.cpp
@@ -525,7 +525,7 @@ void VirtRegRewriter::rewrite() {
// Preserve semantics of sub-register operands.
unsigned SubReg = MO.getSubReg();
if (SubReg != 0) {
- if (NoSubRegLiveness) {
+ if (NoSubRegLiveness || !MRI->shouldTrackSubRegLiveness(VirtReg)) {
// A virtual register kill refers to the whole register, so we may
// have to add implicit killed operands for the super-register. A
// partial redef always kills and redefines the super-register.
OpenPOWER on IntegriCloud