@@ -57,10 +57,8 @@ using namespace PatternMatch;
5757#define DEBUG_TYPE " lower-matrix-intrinsics"
5858
5959STATISTIC (FlattenedMatrices, " Number of matrix flattenings" );
60- #ifndef NDEBUG
6160STATISTIC (ReshapedMatrices, " Number of matrix reshapes" );
6261STATISTIC (SplitMatrices, " Number of matrix splits" );
63- #endif
6462
6563static cl::opt<bool >
6664 FuseMatrix (" fuse-matrix" , cl::init(true ), cl::Hidden,
@@ -627,27 +625,29 @@ class LowerMatrixIntrinsics {
627625 SplitVecs.push_back (V);
628626 }
629627
630- LLVM_DEBUG ( if (Instruction *Inst = dyn_cast<Instruction>(MatrixVal)) {
628+ if (Instruction *Inst = dyn_cast<Instruction>(MatrixVal)) {
631629 if (Found != Inst2ColumnMatrix.end ()) {
632630 // FIXME: re: "at least": SplitVecs.size() doesn't count the shuffles
633631 // that embedInVector created.
634- dbgs () << " matrix reshape from " << Found->second .shape () << " to "
635- << SI << " using at least " << SplitVecs. size ()
636- << " shuffles on behalf of:\n "
637- << *Inst << ' \n ' ;
632+ LLVM_DEBUG ( dbgs () << " matrix reshape from " << Found->second .shape ()
633+ << " to " << SI << " using at least "
634+ << SplitVecs. size () << " shuffles on behalf of:\n "
635+ << *Inst << ' \n ' ) ;
638636 ReshapedMatrices++;
639637 } else if (!ShapeMap.contains (MatrixVal)) {
640- dbgs () << " splitting a " << SI << " matrix with " << SplitVecs.size ()
641- << " shuffles beacuse we do not have a shape-aware lowering for "
642- " its def:\n "
643- << *Inst << ' \n ' ;
638+ LLVM_DEBUG (
639+ dbgs ()
640+ << " splitting a " << SI << " matrix with " << SplitVecs.size ()
641+ << " shuffles beacuse we do not have a shape-aware lowering for "
642+ " its def:\n "
643+ << *Inst << ' \n ' );
644644 SplitMatrices++;
645645 } else {
646646 // The ShapeMap has it, so it's a case where we're being lowered
647647 // before the def, and we expect that InstCombine will clean things up
648648 // afterward.
649649 }
650- });
650+ }
651651
652652 return {SplitVecs};
653653 }
0 commit comments