[PATCH] D72069: [NFC] Put implementation of releaseNode into header file
Qiu Chaofan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 2 00:07:30 PST 2020
qiucf created this revision.
qiucf added reviewers: DoktorC, fhahn.
Herald added subscribers: llvm-commits, javed.absar, hiraditya, MatzeB.
Herald added a project: LLVM.
This patch resolves a build failure about undefined symbols introduced by f9f78cf <https://reviews.llvm.org/rGf9f78cf6ac73d9148be9b626f418bf6770e512f6>, when building with older versions of GCC.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D72069
Files:
llvm/include/llvm/CodeGen/MachineScheduler.h
llvm/lib/CodeGen/MachineScheduler.cpp
Index: llvm/lib/CodeGen/MachineScheduler.cpp
===================================================================
--- llvm/lib/CodeGen/MachineScheduler.cpp
+++ llvm/lib/CodeGen/MachineScheduler.cpp
@@ -2088,8 +2088,8 @@
return OtherCritCount;
}
-template <bool InPQueue>
-void SchedBoundary::releaseNode(SUnit *SU, unsigned ReadyCycle, unsigned Idx) {
+void SchedBoundary::releaseNodeImpl(SUnit *SU, unsigned ReadyCycle,
+ unsigned Idx, bool InPQueue) {
assert(SU->getInstr() && "Scheduled SUnit must have instr");
#ifndef NDEBUG
Index: llvm/include/llvm/CodeGen/MachineScheduler.h
===================================================================
--- llvm/include/llvm/CodeGen/MachineScheduler.h
+++ llvm/include/llvm/CodeGen/MachineScheduler.h
@@ -758,7 +758,9 @@
unsigned getOtherResourceCount(unsigned &OtherCritIdx);
template <bool InPQueue>
- void releaseNode(SUnit *SU, unsigned ReadyCycle, unsigned Idx = 0);
+ void releaseNode(SUnit *SU, unsigned ReadyCycle, unsigned Idx = 0) {
+ releaseNodeImpl(SU, ReadyCycle, Idx, InPQueue);
+ }
void bumpCycle(unsigned NextCycle);
@@ -778,6 +780,10 @@
SUnit *pickOnlyChoice();
void dumpScheduledState() const;
+
+private:
+ void releaseNodeImpl(SUnit *SU, unsigned ReadyCycle, unsigned Idx,
+ bool InPQueue);
};
/// Base class for GenericScheduler. This class maintains information about
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72069.235832.patch
Type: text/x-patch
Size: 1439 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200102/d0ed81ae/attachment.bin>
More information about the llvm-commits
mailing list