MachineVerifier: Allow undef reads if a matching superreg is defined.
authorMatthias Braun <matze@braunis.de>
Wed, 14 Jan 2015 22:25:14 +0000 (22:25 +0000)
committerMatthias Braun <matze@braunis.de>
Wed, 14 Jan 2015 22:25:14 +0000 (22:25 +0000)
commitde8202b0840dcd5c58b9d17d751ef9bf9215892c
tree37bf9e277c7c4f315ecc8df6f7b2a67880703f09
parentbf13dd03e71d1e5ccd30eb4d18e74db221210a61
MachineVerifier: Allow undef reads if a matching superreg is defined.

Summary:
Some pseudo instruction expansions break down a wide register use into
multiple uses of smaller sub registers. If the super register was
partially undefined the broken down sub registers may be completely
undefined now leading to MachineVerifier complaints. Unfortunately
liveness information to add the required dead flags is not easily
(cheaply) available when expanding pseudo instructions.

This commit changes the verifier to be quiet if there is an additional
implicit use of a super register. Pseudo instruction expanders can use
this to mark cases where partially defined values get potentially broken
into completely undefined ones.

Differential Revision: http://reviews.llvm.org/D6973

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226047 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/MachineVerifier.cpp