[PATCH] D117451: [MCA] Proposing the InstrPostProcess:modifyInstrDesc() method.
Min-Yih Hsu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jan 16 21:46:10 PST 2022
myhsu added a comment.
> For example, should:
>
> static void debugPrintExplicitWrite(const WriteDescriptor &Write) {
>
> assert(!Write.isImplicitWrite() && !Write.IsVariadicDef &&
> "This function should only be called for non-variadic explicit "
> "writes."); // Negative integer for implicit writes
>
> LLVM_DEBUG({
> dbgs() << "\t\t[Def] OpIdx=" << Write.OpIndex
> << ", Latency=" << Write.Latency
> << ", WriteResourceID=" << Write.SClassOrWriteResourceID << '\n';
> });
>
> }
> be:
>
> LLVM_DEBUG({
>
> static void debugPrintExplicitWrite(const WriteDescriptor &Write) {
> assert(!Write.isImplicitWrite() && !Write.IsVariadicDef &&
> "This function should only be called for non-variadic explicit "
> "writes."); // Negative integer for implicit writes
>
> dbgs() << "\t\t[Def] OpIdx=" << Write.OpIndex
> << ", Latency=" << Write.Latency
> << ", WriteResourceID=" << Write.SClassOrWriteResourceID << '\n';
> }
>
> });
> or something else entirely?
I think in this case, you can simply wrap the entire function with `#ifndef NDEBUG / #endif`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D117451/new/
https://reviews.llvm.org/D117451
More information about the llvm-commits
mailing list