diff options
author | Derek Schuff <dschuff@google.com> | 2016-04-21 22:19:24 +0000 |
---|---|---|
committer | Derek Schuff <dschuff@google.com> | 2016-04-21 22:19:24 +0000 |
commit | 025191d42feb2636026efeb93d9f5b05de0571ea (patch) | |
tree | 1b64471cb369c85d1df1ccfa4bb69c4326ed42c3 /llvm/lib/CodeGen/MachineFunction.cpp | |
parent | d46e58d38e770b967632fe6e6c16fd4d561c7cb7 (diff) | |
download | llvm-025191d42feb2636026efeb93d9f5b05de0571ea.zip llvm-025191d42feb2636026efeb93d9f5b05de0571ea.tar.gz llvm-025191d42feb2636026efeb93d9f5b05de0571ea.tar.bz2 |
Improve error message reporting for MachineFunctionProperties
When printing the properties required by a pass, only print the
properties that are set, and not those that are clear (only properties
that are set are verified, clear properties are "don't-care").
llvm-svn: 267070
Diffstat (limited to 'llvm/lib/CodeGen/MachineFunction.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineFunction.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineFunction.cpp b/llvm/lib/CodeGen/MachineFunction.cpp index da6b778..641ec74 100644 --- a/llvm/lib/CodeGen/MachineFunction.cpp +++ b/llvm/lib/CodeGen/MachineFunction.cpp @@ -54,11 +54,13 @@ static cl::opt<unsigned> void MachineFunctionInitializer::anchor() {} -void MachineFunctionProperties::print(raw_ostream &ROS) const { +void MachineFunctionProperties::print(raw_ostream &ROS, bool OnlySet) const { // Leave this function even in NDEBUG as an out-of-line anchor. #if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP) for (BitVector::size_type i = 0; i < Properties.size(); ++i) { bool HasProperty = Properties[i]; + if (OnlySet && !HasProperty) + continue; switch(static_cast<Property>(i)) { case Property::IsSSA: ROS << (HasProperty ? "SSA, " : "Post SSA, "); |