History log of /external/llvm/lib/CodeGen/ScheduleDAG.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
dce4a407a24b04eebc6a376f8e62b41aaa7b071f 29-May-2014 Stephen Hines <srhines@google.com> Update LLVM for 3.5 rebase (r209712).

Change-Id: I149556c940fb7dc92d075273c87ff584f400941f
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
36b56886974eae4f9c5ebc96befd3e7bfe5de338 24-Apr-2014 Stephen Hines <srhines@google.com> Update to LLVM 3.5a.

Change-Id: Ifadecab779f128e62e430c2b4f6ddd84953ed617
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
f22fd3f7b557a967b1edc1fa9ae770006a39e97c 03-Jul-2013 Craig Topper <craig.topper@gmail.com> Use SmallVectorImpl instead of SmallVector for iterators and references to avoid specifying the vector size unnecessarily.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185512 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
838038d3e16d0c319c94fec246d1141b27e0046a 01-Mar-2013 Andrew Trick <atrick@apple.com> Scheduler diagnostics. Print the register name.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176316 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
bf32b7f8446334b4a8fab0cc4153ed02046271b2 01-Mar-2013 Andrew Trick <atrick@apple.com> Instructions schedulers should report correct height/depth.

We avoided computing DAG height/depth during Node printing because it
shouldn't depend on an otherwise valid DAG. But this has become far
too annoying for the common case of a valid DAG where we want to see
valid values. If doing the computation on-the-fly turns out to be a
problem in practice, then I'll add a mode to the diagnostics to only
force it when we're likely to have a valid DAG, otherwise explicitly
print INVALID instead of bogus numbers. For now, just go for it all
the time.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176314 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
81474e98e10565e2ee0ad257ddc9469217520711 16-Feb-2013 Benjamin Kramer <benny.kra@googlemail.com> Replace loop with std::find.

No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
66658dd9a1ffe00a5f6e0afca7afb16ec6704ed3 24-Jan-2013 Andrew Trick <atrick@apple.com> MIsched: Added biasCriticalPath.

Allow schedulers to order DAG edges by critical path. This makes
DFS-based heuristics more stable and effective.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173317 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
d04a8d4b33ff316ca4cf961e06c9e312eff8e64f 03-Dec-2012 Chandler Carruth <chandlerc@gmail.com> Use the new script to sort the includes of every file under lib.

Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module
include to be the nearest plausible thing I could find. If you own or
care about any of these source files, I encourage you to take some time
and check that these edits were sensible. I can't have broken anything
(I strictly added headers, and reordered them, never removed), but they
may not be the headers you'd really like to identify as containing the
API being implemented.

Many forward declarations and missing includes were added to a header
files to allow them to parse cleanly when included first. The main
module rule does in fact have its merits. =]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169131 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
cf6b6131dd0da37903a6e3a5173ea12aa8263713 13-Nov-2012 Andrew Trick <atrick@apple.com> misched: Don't consider artificial edges weak edges.

For now be more conservative in case other out-of-tree schedulers rely
on the old behavior of artificial edges.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167808 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
ae692f2baedf53504af2715993b166950e185a55 12-Nov-2012 Andrew Trick <atrick@apple.com> misched: Infrastructure for weak DAG edges.

This adds support for weak DAG edges to the general scheduling
infrastructure in preparation for MachineScheduler support for
heuristics based on weak edges.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167738 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
b720be6a50f4e1b3280d2b029ee38dda14577525 12-Sep-2012 Manman Ren <mren@apple.com> Release build: guard dump functions with
"#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)"

No functional change. Update r163339.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163653 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
77e300e8f0b8db8eec448cae9c87d7c5bfad9757 06-Sep-2012 Manman Ren <mren@apple.com> Release build: guard dump functions with "ifndef NDEBUG"

No functional change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163339 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
9df55eed0470c898c4003dc433c4479bdb0e0aac 13-Jun-2012 Andrew Trick <atrick@apple.com> sched: Avoid trivially redundant DAG edges. Take the one with higher latency.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158379 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
47c144505b9be28ed22c626b3a407c11dba2fec5 07-Mar-2012 Andrew Trick <atrick@apple.com> misched preparation: clarify ScheduleDAG and ScheduleDAGInstrs roles.

ScheduleDAG is responsible for the DAG: SUnits and SDeps. It provides target hooks for latency computation.

ScheduleDAGInstrs extends ScheduleDAG and defines the current scheduling region in terms of MachineInstr iterators. It has access to the target's scheduling itinerary data. ScheduleDAGInstrs provides the logic for building the ScheduleDAG for the sequence of MachineInstrs in the current region. Target's can implement highly custom schedulers by extending this class.

ScheduleDAGPostRATDList provides the driver and diagnostics for current postRA scheduling. It maintains a current Sequence of scheduled machine instructions and logic for splicing them into the block. During scheduling, it uses the ScheduleHazardRecognizer provided by the target.

Specific changes:
- Removed driver code from ScheduleDAG. clearDAG is the only interface needed.

- Added enterRegion/exitRegion hooks to ScheduleDAGInstrs to delimit the scope of each scheduling region and associated DAG. They should be used to setup and cleanup any region-specific state in addition to the DAG itself. This is necessary because we reuse the same ScheduleDAG object for the entire function. The target may extend these hooks to do things at regions boundaries, like bundle terminators. The hooks are called even if we decide not to schedule the region. So all instructions in a block are "covered" by these calls.

- Added ScheduleDAGInstrs::begin()/end() public API.

- Moved Sequence into the driver layer, which is specific to the scheduling algorithm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152208 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
73ba69b6843f7f23345b1e8745cb328952cae0d8 07-Mar-2012 Andrew Trick <atrick@apple.com> misched preparation: modularize schedule printing.

ScheduleDAG will not refer to the scheduled instruction sequence.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152205 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
4c727204271067f3dbf50bd23098b2df8e1cc47a 07-Mar-2012 Andrew Trick <atrick@apple.com> misched preparation: modularize schedule verification.

ScheduleDAG will not refer to the scheduled instruction sequence.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152204 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
0b923d9ee9e406c7dadc0803106656391a0ffd68 17-Feb-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Don't print out pointer values in SUnit::dump().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150842 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
3c58ba8ea7ec097d69d7f7be5930a4a4d7405a18 14-Jan-2012 Andrew Trick <atrick@apple.com> misched: Initial code for building an MI level scheduling DAG

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148174 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
2d24e2a396a1d211baaeedf32148a3b657240170 20-Dec-2011 David Blaikie <dblaikie@gmail.com> Unweaken vtables as per http://llvm.org/docs/CodingStandards.html#ll_virtual_anch

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146960 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
a67f14bf53737f9bb0afefa28e08c4aac6ec4804 19-Aug-2011 Benjamin Kramer <benny.kra@googlemail.com> Make a bunch of symbols private.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138025 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
1f6a329f79b3568d379142f921f59c4143ddaa14 12-Aug-2011 Duncan Sands <baldrick@free.fr> Silence a bunch (but not all) "variable written but not read" warnings
when building with assertions disabled.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137460 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
e837dead3c8dc3445ef6a0e2322179c57e264a13 28-Jun-2011 Evan Cheng <evan.cheng@apple.com> - Rename TargetInstrDesc, TargetOperandInfo to MCInstrDesc and MCOperandInfo and
sink them into MC layer.
- Added MCInstrInfo, which captures the tablegen generated static data. Chang
TargetInstrInfo so it's based off MCInstrInfo.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134021 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
4cb971ce1c8b254f29365c988b55f6dcfe86d21e 15-Jun-2011 Andrew Trick <atrick@apple.com> Added -stress-sched flag in the Asserts build.
Added a test case for handling physreg aliases during pre-RA-sched.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133063 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
7a2bdde0a0eebcd2125055e0eacaca040f0b766c 15-Apr-2011 Chris Lattner <sabre@nondot.org> Fix a ton of comment typos found by codespell. Patch by
Luis Felipe Strano Moraes!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129558 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
92e946630d5f9bb092853b93501387dd216899b9 04-Feb-2011 Andrew Trick <atrick@apple.com> Introducing a new method of tracking register pressure. We can't
precisely track pressure on a selection DAG, but we can at least keep
it balanced. This design accounts for various interesting aspects of
selection DAGS: register and subregister copies, glued nodes, dead
nodes, unused registers, etc.

Added SUnit::NumRegDefsLeft and ScheduleDAGSDNodes::RegDefIter.

Note: I disabled PrescheduleNodesWithMultipleUses when register
pressure is enabled, based on no evidence other than I don't think it
makes sense to have both enabled.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124853 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
24312230ada6f4cfa8776351dafb12eea8a81b33 24-Dec-2010 Andrew Trick <atrick@apple.com> Fix a few cases where the scheduler is not checking for phys reg copies. The scheduling node may have a NULL DAG node, yuck.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122544 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
2da8bc8a5f7705ac131184cd247f48500da0d74e 24-Dec-2010 Andrew Trick <atrick@apple.com> Various bits of framework needed for precise machine-level selection
DAG scheduling during isel. Most new functionality is currently
guarded by -enable-sched-cycles and -enable-sched-hazard.

Added InstrItineraryData::IssueWidth field, currently derived from
ARM itineraries, but could be initialized differently on other targets.

Added ScheduleHazardRecognizer::MaxLookAhead to indicate whether it is
active, and if so how many cycles of state it holds.

Added SchedulingPriorityQueue::HasReadyFilter to allowing gating entry
into the scheduler's available queue.

ScoreboardHazardRecognizer now accesses the ScheduleDAG in order to
get information about it's SUnits, provides RecedeCycle for bottom-up
scheduling, correctly computes scoreboard depth, tracks IssueCount, and
considers potential stall cycles when checking for hazards.

ScheduleDAGRRList now models machine cycles and hazards (under
flags). It tracks MinAvailableCycle, drives the hazard recognizer and
priority queue's ready filter, manages a new PendingQueue, properly
accounts for stall cycles, etc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122541 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
5078293cc28dd03236384fa0a3b6c8347e0701fb 20-Dec-2010 Chris Lattner <sabre@nondot.org> reduce indentation, no functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122208 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
9f71f801b51cdc7df388b2693398cfea69fe67c7 30-Jun-2010 John Mosby <ojomojo@gmail.com> Remove trailing whitespace, no functionality changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107244 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
bae5210321e0c3ea28723334841555135a61e915 17-May-2010 Zhongxing Xu <xuzhongxing@gmail.com> Remove unused member variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103936 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
5c982949bf87ffda129fb7fe372e414e255f4630 13-Apr-2010 Dan Gohman <gohman@apple.com> Delete an unused member variable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101143 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
4b134d1661214427834bf89ef1183f458919837e 05-Jan-2010 David Greene <greened@obbligato.org> Change errs() to dbgs().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92585 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
557bbe6b5d13faaec38f85a266db457c7cb09ff2 20-Nov-2009 David Goodwin <david_goodwin@apple.com> Remove some old experimental code that is no longer needed. Remove additional, speculative scheduling pass as its cost did not translate into significant performance improvement. Minor tweaks.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89471 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
12dd99dc308150a6beff32aafc824e1d6fec1139 12-Nov-2009 David Goodwin <david_goodwin@apple.com> Rename registers to break output dependencies in addition to anti-dependencies.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87015 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
4de099d8ca651e00fa5fac22bace4f4dba2d0292 03-Nov-2009 David Goodwin <david_goodwin@apple.com> Do a scheduling pass ignoring anti-dependencies to identify candidate registers that should be renamed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85939 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
c277ab08a24d2dbe9b4ff1a9154ea6115ed6a4e3 30-Sep-2009 Reid Kleckner <reid@kleckner.net> Fix integer overflow in instruction scheduling. This can happen if we have
basic blocks that are so long that their size overflows a short.

Also assert that overflow does not happen in the future, as requested by Evan.

This fixes PR4401.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83159 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
960bb85b2165bd69feea3fc07d9cadd2da821c72 22-Aug-2009 Bill Wendling <isanbard@gmail.com> Convert DOUT to DEBUG(errs()...).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79760 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
c93d8373c93159c590838957b3194900caeb8a03 11-Aug-2009 David Goodwin <david_goodwin@apple.com> Add some debug output.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78687 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
3f0e83067d7938f742d21e14fc87c006d2fc3161 24-Jul-2009 Daniel Dunbar <daniel@zuster.org> Move to raw_ostream.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76963 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
47ac0f0c7c39289f5970688154e385be22b7f293 11-Feb-2009 Dan Gohman <gohman@apple.com> When scheduling a block in parts, keep track of the overall
instruction index across each part. Instruction indices are used
to make live range queries, and live ranges can extend beyond
scheduling region boundaries.

Refactor the ScheduleDAGSDNodes class some more so that it
doesn't have to worry about this additional information.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64288 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
5cffa6fe271351a8fd80e7767b5d61a999acfa9b 11-Feb-2009 Dan Gohman <gohman@apple.com> Use iterators to iterate through the Preds array instead of
an index. This code is on the hot-path because the current
way SDep edges are uniqued has quadratic complexity.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64262 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
9e64bbb322417c09f27afdf08e3946287c9df5aa 11-Feb-2009 Dan Gohman <gohman@apple.com> Factor out more code for computing register live-range informationfor
scheduling, and generalize is so that preserves state across
scheduling regions. This fixes incorrect live-range information around
terminators and labels, which are effective region boundaries.

In place of looking for terminators to anchor inter-block dependencies,
introduce special entry and exit scheduling units for this purpose.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64254 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
f7119393a97c2a10757084b6bc186380f8c19a73 16-Jan-2009 Dan Gohman <gohman@apple.com> Instead of adding dependence edges between terminator instructions
and every other instruction in their blocks to keep the terminator
instructions at the end, teach the post-RA scheduler how to operate
on ranges of instructions, and exclude terminators from the range
of instructions that get scheduled.

Also, exclude mid-block labels, such as EH_LABEL instructions, and
schedule code before them separately from code after them. This
fixes problems with the post-RA scheduler moving code past
EH_LABELs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
fc54c552963545a81e4ea38e60460590afb2d5ae 15-Jan-2009 Dan Gohman <gohman@apple.com> Generalize the HazardRecognizer interface so that it can be used
to support MachineInstr-based scheduling in addition to
SDNode-based scheduling.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62284 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
79ce276083ced01256a0eb7d80731e4948ca6e87 15-Jan-2009 Dan Gohman <gohman@apple.com> Move a few containers out of ScheduleDAGInstrs::BuildSchedGraph
and into the ScheduleDAGInstrs class, so that they don't get
destructed and re-constructed for each block. This fixes a
compile-time hot spot in the post-pass scheduler.

To help facilitate this, tidy and do some minor reorganization
in the scheduler constructor functions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62275 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
a1f50e2c2cad12dd8fe7ef80e394ee7a96654021 13-Jan-2009 Dan Gohman <gohman@apple.com> Avoid referring to edge D after the Succs or Preds arrays have
been modified, to avoid trouble in the (unlikely) scenario that
D is a reference to an element in one of those arrays.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62173 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
a80c859df377908c687d59e9c0fc65006796b719 05-Jan-2009 Dan Gohman <gohman@apple.com> Don't call setDepthDirty/setHeightDirty when adding an edge
with latency 0, since it doesn't affect the depth or height.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61762 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
1578f8486d401a16bdfbe7f27cd4d644920000bf 23-Dec-2008 Dan Gohman <gohman@apple.com> Minor code simplifications.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61371 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
8044e9b3af6e62afe89cd60bf76de22ae7138306 22-Dec-2008 Dan Gohman <gohman@apple.com> Optimize setDepthDirty and setHeightDirty a little, as they showed
up on a profile.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61344 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
e19c6362d21c872abaf2f71ea9a0f859f33ee9b5 20-Dec-2008 Dan Gohman <gohman@apple.com> Use SmallVector's pop_back_val.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61277 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
f89e6e65770edccd8cc3baf2314b89ba894ffa4f 20-Dec-2008 Dan Gohman <gohman@apple.com> Use the correct Preds and Succs lists in setHeightDirty()
and setDepthDirty(), respectively. This fixes PR3241.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61276 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
fccf6dd377959560aafdde40b92fc749471eeae5 17-Dec-2008 Dan Gohman <gohman@apple.com> Use getDepth() and getHeight() instead of accessing the
Depth and Height members directly, as they may not be
current.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61121 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
3f23744df4809eba94284e601e81489212c974d4 16-Dec-2008 Dan Gohman <gohman@apple.com> Fix some register-alias-related bugs in the post-RA scheduler liveness
computation code. Also, avoid adding output-depenency edges when both
defs are dead, which frequently happens with EFLAGS defs.

Compute Depth and Height lazily, and always in terms of edge latency
values. For the schedulers that don't care about latency, edge latencies
are set to 1.

Eliminate Cycle and CycleBound, and LatencyPriorityQueue's Latencies array.
These are all subsumed by the Depth and Height fields.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61073 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
c6b680eee58d27f4d38684c95e8fbfef61eb6558 16-Dec-2008 Dan Gohman <gohman@apple.com> Move addPred and removePred out-of-line.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61067 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
54e4c36a7349e94a84773afb56eccd4ca65b49e9 09-Dec-2008 Dan Gohman <gohman@apple.com> Rewrite the SDep class, and simplify some of the related code.

The Cost field is removed. It was only being used in a very limited way,
to indicate when the scheduler should attempt to protect a live register,
and it isn't really needed to do that. If we ever want the scheduler to
start inserting copies in non-prohibitive situations, we'll have to
rethink some things anyway.

A Latency field is added. Instead of giving each node a single
fixed latency, each edge can have its own latency. This will eventually
be used to model various micro-architecture properties more accurately.

The PointerIntPair class and an internal union are now used, which
reduce the overall size.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60806 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
e3a49cd944ad41eba5a594f1de773d531ad25403 09-Dec-2008 Dan Gohman <gohman@apple.com> Whitespace cleanups.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60769 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
21d9003087c9a707e6cd95460136b499df358fb8 25-Nov-2008 Dan Gohman <gohman@apple.com> Initial support for anti-dependence breaking. Currently this code does not
introduce any new spilling; it just uses unused registers.

Refactor the SUnit topological sort code out of the RRList scheduler and
make use of it to help with the post-pass scheduler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59999 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
98adea11496400c8385b774b4d9f9acd4c99d254 21-Nov-2008 Dan Gohman <gohman@apple.com> Rename SDep's isSpecial to isArtificial, to make this field a little
less mysterious.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59782 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
40362067de30a493951e084ba59d9b4fb1654a20 20-Nov-2008 Dan Gohman <gohman@apple.com> Add #include <climits> to get the definition of INT_MAX.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59692 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
a1e6d363e5efa9eb1a2e7ac21a0394c870bef5ad 20-Nov-2008 Dan Gohman <gohman@apple.com> Factor out the code for verifying the work of the scheduler,
extend it a bit, and make use of it in all schedulers, to
ensure consistent checking.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59689 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp
343f0c046702831a4a6aec951b6a297a23241a55 20-Nov-2008 Dan Gohman <gohman@apple.com> Experimental post-pass scheduling support. Post-pass scheduling
is currently off by default, and can be enabled with
-disable-post-RA-scheduler=false.

This doesn't have a significant impact on most code yet because it doesn't
yet do anything to address anti-dependencies and it doesn't attempt to
disambiguate memory references. Also, several popular targets
don't have pipeline descriptions yet.

The majority of the changes here are splitting the SelectionDAG-specific
code out of ScheduleDAG, so that ScheduleDAG can be moved to
libLLVMCodeGen.a. The interface between ScheduleDAG-using code and
the rest of the scheduling code is somewhat rough and will evolve.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59676 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/ScheduleDAG.cpp