diff options
author | Nicola Zaghen <nicola.zaghen@imgtec.com> | 2018-05-14 12:53:11 +0000 |
---|---|---|
committer | Nicola Zaghen <nicola.zaghen@imgtec.com> | 2018-05-14 12:53:11 +0000 |
commit | d34e60ca8532511acb8c93ef26297e349fbec86a (patch) | |
tree | 1a095bc8694498d94232e81b95c1da05d462d3ec /llvm/lib/CodeGen/RegUsageInfoPropagate.cpp | |
parent | affbc99bea94e77f7ebccd8ba887e33051bd04ee (diff) | |
download | llvm-d34e60ca8532511acb8c93ef26297e349fbec86a.zip llvm-d34e60ca8532511acb8c93ef26297e349fbec86a.tar.gz llvm-d34e60ca8532511acb8c93ef26297e349fbec86a.tar.bz2 |
Rename DEBUG macro to LLVM_DEBUG.
The DEBUG() macro is very generic so it might clash with other projects.
The renaming was done as follows:
- git grep -l 'DEBUG' | xargs sed -i 's/\bDEBUG\s\?(/LLVM_DEBUG(/g'
- git diff -U0 master | ../clang/tools/clang-format/clang-format-diff.py -i -p1 -style LLVM
- Manual change to APInt
- Manually chage DOCS as regex doesn't match it.
In the transition period the DEBUG() macro is still present and aliased
to the LLVM_DEBUG() one.
Differential Revision: https://reviews.llvm.org/D43624
llvm-svn: 332240
Diffstat (limited to 'llvm/lib/CodeGen/RegUsageInfoPropagate.cpp')
-rw-r--r-- | llvm/lib/CodeGen/RegUsageInfoPropagate.cpp | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp b/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp index 5b12d00..7eaeea2 100644 --- a/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp +++ b/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp @@ -105,9 +105,9 @@ bool RegUsageInfoPropagationPass::runOnMachineFunction(MachineFunction &MF) { const Module *M = MF.getFunction().getParent(); PhysicalRegisterUsageInfo *PRUI = &getAnalysis<PhysicalRegisterUsageInfo>(); - DEBUG(dbgs() << " ++++++++++++++++++++ " << getPassName() - << " ++++++++++++++++++++ \n"); - DEBUG(dbgs() << "MachineFunction : " << MF.getName() << "\n"); + LLVM_DEBUG(dbgs() << " ++++++++++++++++++++ " << getPassName() + << " ++++++++++++++++++++ \n"); + LLVM_DEBUG(dbgs() << "MachineFunction : " << MF.getName() << "\n"); const MachineFrameInfo &MFI = MF.getFrameInfo(); if (!MFI.hasCalls() && !MFI.hasTailCall()) @@ -119,9 +119,10 @@ bool RegUsageInfoPropagationPass::runOnMachineFunction(MachineFunction &MF) { for (MachineInstr &MI : MBB) { if (!MI.isCall()) continue; - DEBUG(dbgs() - << "Call Instruction Before Register Usage Info Propagation : \n"); - DEBUG(dbgs() << MI << "\n"); + LLVM_DEBUG( + dbgs() + << "Call Instruction Before Register Usage Info Propagation : \n"); + LLVM_DEBUG(dbgs() << MI << "\n"); auto UpdateRegMask = [&](const Function *F) { const auto *RegMask = PRUI->getRegUsageInfo(F); @@ -134,15 +135,17 @@ bool RegUsageInfoPropagationPass::runOnMachineFunction(MachineFunction &MF) { if (const Function *F = findCalledFunction(*M, MI)) { UpdateRegMask(F); } else { - DEBUG(dbgs() << "Failed to find call target function\n"); + LLVM_DEBUG(dbgs() << "Failed to find call target function\n"); } - DEBUG(dbgs() << "Call Instruction After Register Usage Info Propagation : " - << MI << '\n'); + LLVM_DEBUG( + dbgs() << "Call Instruction After Register Usage Info Propagation : " + << MI << '\n'); } } - DEBUG(dbgs() << " +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++" - "++++++ \n"); + LLVM_DEBUG( + dbgs() << " +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++" + "++++++ \n"); return Changed; } |