summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2014-04-18 17:35:08 +0000
committerAndrew Trick <atrick@apple.com>2014-04-18 17:35:08 +0000
commit939bc92c041d373b2b0a6610ed3b7b211d563cbb (patch)
treeb9c149752c03d0be357bb9995b22ea2a7b3b6094 /lib
parentfe030f3dcdb5134c9b691c5a65977752d0b7addc (diff)
downloadllvm-939bc92c041d373b2b0a6610ed3b7b211d563cbb.tar.gz
llvm-939bc92c041d373b2b0a6610ed3b7b211d563cbb.tar.bz2
llvm-939bc92c041d373b2b0a6610ed3b7b211d563cbb.tar.xz
Better comments to explain buffered/unbuffered processor resources.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206625 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/ScheduleDAGInstrs.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/CodeGen/ScheduleDAGInstrs.cpp b/lib/CodeGen/ScheduleDAGInstrs.cpp
index 9c516c6edd..4ac2a3c5bf 100644
--- a/lib/CodeGen/ScheduleDAGInstrs.cpp
+++ b/lib/CodeGen/ScheduleDAGInstrs.cpp
@@ -699,10 +699,14 @@ void ScheduleDAGInstrs::initSUnits() {
// Assign the Latency field of SU using target-provided information.
SU->Latency = SchedModel.computeInstrLatency(SU->getInstr());
- // If this SUnit uses an unbuffered resource, mark it as such.
- // These resources are used for in-order execution pipelines within an
- // out-of-order core and are identified by BufferSize=1. BufferSize=0 is
- // used for dispatch/issue groups and is not considered here.
+ // If this SUnit uses a reserved or unbuffered resource, mark it as such.
+ //
+ // Reserved resources block an instruction from issueing and stall the
+ // entire pipeline. These are identified by BufferSize=0.
+ //
+ // Unbuffered resources prevent execution of subsequeny instructions that
+ // require the same resources. This is used for in-order execution pipelines
+ // within an out-of-order core. These are identified by BufferSize=1.
if (SchedModel.hasInstrSchedModel()) {
const MCSchedClassDesc *SC = getSchedClass(SU);
for (TargetSchedModel::ProcResIter