[llvm] r267774 - Fix build failure under NDEBUG.
Justin Bogner via llvm-commits
llvm-commits at lists.llvm.org
Sun May 1 23:15:48 PDT 2016
Than McIntosh via llvm-commits <llvm-commits at lists.llvm.org> writes:
> Author: thanm
> Date: Wed Apr 27 15:07:02 2016
> New Revision: 267774
>
> URL: http://llvm.org/viewvc/llvm-project?rev=267774&view=rev
> Log:
> Fix build failure under NDEBUG.
I don't think this is the right change. The point of LLVM_DUMP_METHOD is
that it can be controlled independently of NDEBUG, isn't it?
I suspect that the correct fix is to drop the DEBUG() macros inside the
dump methods, but I haven't actually tried it.
> Modified:
> llvm/trunk/lib/CodeGen/StackColoring.cpp
>
> Modified: llvm/trunk/lib/CodeGen/StackColoring.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/StackColoring.cpp?rev=267774&r1=267773&r2=267774&view=diff
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/StackColoring.cpp (original)
> +++ llvm/trunk/lib/CodeGen/StackColoring.cpp Wed Apr 27 15:07:02 2016
> @@ -190,6 +190,8 @@ void StackColoring::getAnalysisUsage(Ana
> MachineFunctionPass::getAnalysisUsage(AU);
> }
>
> +#ifndef NDEBUG
> +
> LLVM_DUMP_METHOD void StackColoring::dumpBV(const char *tag,
> const BitVector &BV) const {
> DEBUG(dbgs() << tag << " : { ");
> @@ -224,6 +226,8 @@ LLVM_DUMP_METHOD void StackColoring::dum
> }
> }
>
> +#endif // not NDEBUG
> +
> unsigned StackColoring::collectMarkers(unsigned NumSlot) {
> unsigned MarkersFound = 0;
> // Scan the function to find all lifetime markers.
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list