Subzero: Use C++11 member initializers where practical.
Also change the pattern "foo() {}" into "foo() = default;" for ctors and dtors.
Generally avoids initializing unique_ptr<> members to nullptr in a .h file, because that requires knowing the definition of the underlying class which may not be available to all includers.
BUG= none
R=jpp@chromium.org
Review URL: https://codereview.chromium.org/1197223002
diff --git a/src/IceTargetLoweringX8632.cpp b/src/IceTargetLoweringX8632.cpp
index 13af9d7..6e80a8f 100644
--- a/src/IceTargetLoweringX8632.cpp
+++ b/src/IceTargetLoweringX8632.cpp
@@ -265,8 +265,7 @@
} // end of anonymous namespace
BoolFoldingEntry::BoolFoldingEntry(Inst *I)
- : Instr(I), IsComplex(BoolFolding::hasComplexLowering(I)), IsLiveOut(true),
- NumUses(0) {}
+ : Instr(I), IsComplex(BoolFolding::hasComplexLowering(I)) {}
BoolFolding::BoolFoldingProducerKind
BoolFolding::getProducerKind(const Inst *Instr) {
@@ -410,10 +409,7 @@
FoldingInfo.dump(Func);
}
-TargetX8632::TargetX8632(Cfg *Func)
- : TargetLowering(Func), InstructionSet(X86InstructionSet::Begin),
- IsEbpBasedFrame(false), NeedsStackAlignment(false), SpillAreaSizeBytes(0),
- RandomizationPoolingPaused(false) {
+TargetX8632::TargetX8632(Cfg *Func) : TargetLowering(Func) {
static_assert((X86InstructionSet::End - X86InstructionSet::Begin) ==
(TargetInstructionSet::X86InstructionSet_End -
TargetInstructionSet::X86InstructionSet_Begin),