diff options
Diffstat (limited to 'lib/CodeGen/StackMaps.cpp')
-rw-r--r-- | lib/CodeGen/StackMaps.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/lib/CodeGen/StackMaps.cpp b/lib/CodeGen/StackMaps.cpp index e66a25bec911..19a191c01db9 100644 --- a/lib/CodeGen/StackMaps.cpp +++ b/lib/CodeGen/StackMaps.cpp @@ -268,11 +268,11 @@ StackMaps::parseRegisterLiveOutMask(const uint32_t *Mask) const { // in the list. Merge entries that refer to the same dwarf register and use // the maximum size that needs to be spilled. - std::sort(LiveOuts.begin(), LiveOuts.end(), - [](const LiveOutReg &LHS, const LiveOutReg &RHS) { - // Only sort by the dwarf register number. - return LHS.DwarfRegNum < RHS.DwarfRegNum; - }); + llvm::sort(LiveOuts.begin(), LiveOuts.end(), + [](const LiveOutReg &LHS, const LiveOutReg &RHS) { + // Only sort by the dwarf register number. + return LHS.DwarfRegNum < RHS.DwarfRegNum; + }); for (auto I = LiveOuts.begin(), E = LiveOuts.end(); I != E; ++I) { for (auto II = std::next(I); II != E; ++II) { @@ -420,13 +420,13 @@ void StackMaps::emitStackmapHeader(MCStreamer &OS) { OS.EmitIntValue(0, 2); // Reserved. // Num functions. - DEBUG(dbgs() << WSMP << "#functions = " << FnInfos.size() << '\n'); + LLVM_DEBUG(dbgs() << WSMP << "#functions = " << FnInfos.size() << '\n'); OS.EmitIntValue(FnInfos.size(), 4); // Num constants. - DEBUG(dbgs() << WSMP << "#constants = " << ConstPool.size() << '\n'); + LLVM_DEBUG(dbgs() << WSMP << "#constants = " << ConstPool.size() << '\n'); OS.EmitIntValue(ConstPool.size(), 4); // Num callsites. - DEBUG(dbgs() << WSMP << "#callsites = " << CSInfos.size() << '\n'); + LLVM_DEBUG(dbgs() << WSMP << "#callsites = " << CSInfos.size() << '\n'); OS.EmitIntValue(CSInfos.size(), 4); } @@ -439,11 +439,11 @@ void StackMaps::emitStackmapHeader(MCStreamer &OS) { /// } void StackMaps::emitFunctionFrameRecords(MCStreamer &OS) { // Function Frame records. - DEBUG(dbgs() << WSMP << "functions:\n"); + LLVM_DEBUG(dbgs() << WSMP << "functions:\n"); for (auto const &FR : FnInfos) { - DEBUG(dbgs() << WSMP << "function addr: " << FR.first - << " frame size: " << FR.second.StackSize - << " callsite count: " << FR.second.RecordCount << '\n'); + LLVM_DEBUG(dbgs() << WSMP << "function addr: " << FR.first + << " frame size: " << FR.second.StackSize + << " callsite count: " << FR.second.RecordCount << '\n'); OS.EmitSymbolValue(FR.first, 8); OS.EmitIntValue(FR.second.StackSize, 8); OS.EmitIntValue(FR.second.RecordCount, 8); @@ -455,9 +455,9 @@ void StackMaps::emitFunctionFrameRecords(MCStreamer &OS) { /// int64 : Constants[NumConstants] void StackMaps::emitConstantPoolEntries(MCStreamer &OS) { // Constant pool entries. - DEBUG(dbgs() << WSMP << "constants:\n"); + LLVM_DEBUG(dbgs() << WSMP << "constants:\n"); for (const auto &ConstEntry : ConstPool) { - DEBUG(dbgs() << WSMP << ConstEntry.second << '\n'); + LLVM_DEBUG(dbgs() << WSMP << ConstEntry.second << '\n'); OS.EmitIntValue(ConstEntry.second, 8); } } @@ -492,7 +492,7 @@ void StackMaps::emitConstantPoolEntries(MCStreamer &OS) { /// 0x4, Constant, Offset (small constant) /// 0x5, ConstIndex, Constants[Offset] (large constant) void StackMaps::emitCallsiteEntries(MCStreamer &OS) { - DEBUG(print(dbgs())); + LLVM_DEBUG(print(dbgs())); // Callsite entries. for (const auto &CSI : CSInfos) { const LocationVec &CSLocs = CSI.Locations; @@ -569,7 +569,7 @@ void StackMaps::serializeToStackMapSection() { OS.EmitLabel(OutContext.getOrCreateSymbol(Twine("__LLVM_StackMaps"))); // Serialize data. - DEBUG(dbgs() << "********** Stack Map Output **********\n"); + LLVM_DEBUG(dbgs() << "********** Stack Map Output **********\n"); emitStackmapHeader(OS); emitFunctionFrameRecords(OS); emitConstantPoolEntries(OS); |