[llvm] r311075 - [SystemZ] Also wrap TII with #ifndef NDEBUG in constructor initilizer list.

Jonas Paulsson via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 17 02:18:02 PDT 2017


Author: jonpa
Date: Thu Aug 17 02:18:02 2017
New Revision: 311075

URL: http://llvm.org/viewvc/llvm-project?rev=311075&view=rev
Log:
[SystemZ]  Also wrap TII with #ifndef NDEBUG in constructor initilizer list.

TII needs to be wrapped with #ifndef NDEBUG to silece compiler warnings.

Modified:
    llvm/trunk/lib/Target/SystemZ/SystemZHazardRecognizer.h

Modified: llvm/trunk/lib/Target/SystemZ/SystemZHazardRecognizer.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/SystemZ/SystemZHazardRecognizer.h?rev=311075&r1=311074&r2=311075&view=diff
==============================================================================
--- llvm/trunk/lib/Target/SystemZ/SystemZHazardRecognizer.h (original)
+++ llvm/trunk/lib/Target/SystemZ/SystemZHazardRecognizer.h Thu Aug 17 02:18:02 2017
@@ -103,9 +103,15 @@ class SystemZHazardRecognizer : public S
 public:
   SystemZHazardRecognizer(const SystemZInstrInfo *tii,
                           const TargetSchedModel *SM)
-    : TII(tii), SchedModel(SM) { Reset(); }
+      :
+#ifndef NDEBUG
+        TII(tii),
+#endif
+        SchedModel(SM) {
+    Reset();
+  }
 
-  HazardType getHazardType(SUnit *m, int Stalls = 0) override;    
+  HazardType getHazardType(SUnit *m, int Stalls = 0) override;
   void Reset() override;
   void EmitInstruction(SUnit *SU) override;
 




More information about the llvm-commits mailing list