1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00
Commit Graph

67 Commits

Author SHA1 Message Date
Philip Reames
b28303ef74 [PassManager] Tuning Memory Usage of AnalysisUsage
We were using unneccessarily large initial sizes for these SmallVectors.  This was wasting around 50kb of memory for the O3 pipeline, even after the uniquing changes.  We're still using around 20kb which is a bit much, but it's definitely better.  This is about a 6% improvement in total O3 memory usage.

Note: The raw data on structure size which were used to pick these thresholds can be found in the review thread.

Differential Revision: http://reviews.llvm.org/D15244

llvm-svn: 254974
2015-12-08 00:10:56 +00:00
Chandler Carruth
2eeb3460a8 [LPM] Teach the legacy pass manager to support *using* an analysis
without *requiring* it.

This allows a pass indicate that it will use an analysis if available
(through getAnalysisIfAvailable). When the pass manager knows this, it
will refrain from deleting that analysis if it can. Naturally, it will
still get invalidated at the correct time. These passes are not
considered when scheduling the pass pipeline, so typically they will
require manual scheduling, but this may also allow passes with
getAnalysisIfAvailable to find the analysis more often if nothing after
them requires that analysis and it wasn't invalidated.

I don't have a particular use case with the current passes, but with my
new structure for alias analyses, this will be very useful. We want to
allow people to customize the set of AAs available by scheduling
additional passes. These's aren't ever *required* for obvious reasons.
So we need some way to mark in the legacy pass manager that they will
still be used if available.

This is essentially how analysis groups already work. But this makes the
feature generally available and more explicit. It should allow the AA
change to not impact how people trigger a custom alias analysis being
available at a certain point in compilation.

Differential Revision: http://reviews.llvm.org/D12114

llvm-svn: 245409
2015-08-19 03:02:12 +00:00
Chandler Carruth
0fe68f020c [LPM] Group the addPreserved template with the non-template variants,
NFC.

llvm-svn: 245324
2015-08-18 18:18:37 +00:00
Jonathan Roelofs
cfaba2da23 Doxygen-ify a few comments. NFC
llvm-svn: 240647
2015-06-25 15:06:47 +00:00
Alexander Kornienko
f993659b8f Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC)
Apparently, the style needs to be agreed upon first.

llvm-svn: 240390
2015-06-23 09:49:53 +00:00
Alexander Kornienko
40cb19d802 Fixed/added namespace ending comments using clang-tidy. NFC
The patch is generated using this command:

tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \
  -checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \
  llvm/lib/


Thanks to Eugene Kosov for the original patch!

llvm-svn: 240137
2015-06-19 15:57:42 +00:00
Aaron Ballman
0b45511a2e Removing LLVM_DELETED_FUNCTION, as MSVC 2012 was the last reason for requiring the macro. NFC; LLVM edition.
llvm-svn: 229340
2015-02-15 22:54:22 +00:00
Craig Topper
30281a67fb [C++11] More 'nullptr' conversion. In some cases just using a boolean check instead of comparing to nullptr.
llvm-svn: 206142
2014-04-14 00:51:57 +00:00
Craig Topper
457de03c6e [C++11] More 'nullptr' conversion or in some cases just using a boolean check instead of comparing to nullptr.
llvm-svn: 205831
2014-04-09 06:08:46 +00:00
Jakub Staszak
f1ea1a7f37 Fix include guards so they exactly match file names.
llvm-svn: 172025
2013-01-10 00:45:19 +00:00
Chandler Carruth
ca305491f6 Sort the #include lines for the include/... tree with the script.
AKA: Recompile *ALL* the source code!

This one went much better. No manual edits here. I spot-checked for
silliness and grep-checked for really broken edits and everything seemed
good. It all still compiles. Yell if you see something that looks goofy.

llvm-svn: 169133
2012-12-03 17:02:12 +00:00
Sylvestre Ledru
b77340e506 Revert 'Fix a typo 'iff' => 'if''. iff is an abreviation of if and only if. See: http://en.wikipedia.org/wiki/If_and_only_if Commit 164767
llvm-svn: 164768
2012-09-27 10:14:43 +00:00
Sylvestre Ledru
1c5e7904de Fix a typo 'iff' => 'if'
llvm-svn: 164767
2012-09-27 09:59:43 +00:00
Craig Topper
e65078e3c3 Mark constructors, destructors, and operator new commented as 'do not implement' with LLVM_DELETED_FUNCTION instead.
llvm-svn: 164091
2012-09-18 02:05:45 +00:00
Eli Friedman
ef8abc0e6d Add a couple missing includes; found while analyzing LLVM headers.
llvm-svn: 143716
2011-11-04 18:19:43 +00:00
Jakob Stoklund Olesen
b5c875d574 Don't add the same analysis implementation pair twice.
Prevent infinite growth of the list.

Patch by José Fonseca!

llvm-svn: 128568
2011-03-30 18:32:53 +00:00
Dan Gohman
48a98809af More #include cleanups.
llvm-svn: 110499
2010-08-07 01:18:18 +00:00
Dan Gohman
1637747481 Make AnalysisImpls private.
llvm-svn: 110492
2010-08-07 00:34:52 +00:00
Owen Anderson
f2fea95f2f Reapply r110396, with fixes to appease the Linux buildbot gods.
llvm-svn: 110460
2010-08-06 18:33:48 +00:00
Owen Anderson
aadd8a89ca Revert r110396 to fix buildbots.
llvm-svn: 110410
2010-08-06 00:23:35 +00:00
Owen Anderson
b9762c07cb Don't use PassInfo* as a type identifier for passes. Instead, use the address of the static
ID member as the sole unique type identifier.  Clean up APIs related to this change.

llvm-svn: 110396
2010-08-05 23:42:04 +00:00
Owen Anderson
5f218b8612 Speculatively revert r108813, in an attempt to get the self-host buildbots working again. I don't see why this patch
would cause them to fail the way they are, but none of the other intervening patches seem likely either.

llvm-svn: 108818
2010-07-20 08:26:15 +00:00
Owen Anderson
cf625d0179 Reapply r108794, a fix for the failing test from last time.
llvm-svn: 108813
2010-07-20 06:52:42 +00:00
Daniel Dunbar
3280e3aebf Revert r108794, "Separate PassInfo into two classes: a constructor-free
superclass (StaticPassInfo) and a constructor-ful subclass (PassInfo).", it is
breaking teh everything.

llvm-svn: 108805
2010-07-20 03:06:07 +00:00
Owen Anderson
3502f9a91b Separate PassInfo into two classes: a constructor-free superclass (StaticPassInfo) and a constructor-ful subclass (PassInfo).
llvm-svn: 108794
2010-07-20 01:19:58 +00:00
Dan Gohman
745765d0b8 Move several non-performance-critical member functinos out of line.
llvm-svn: 106444
2010-06-21 18:46:45 +00:00
Chris Lattner
309cca906a eliminate dynamic_cast from the pass manager.
llvm-svn: 94060
2010-01-21 02:07:07 +00:00
Daniel Dunbar
4daaf9d3f4 Pass StringRef by value.
llvm-svn: 86251
2009-11-06 10:58:06 +00:00
Daniel Dunbar
89e9f2b1c1 Add another required #include for freestanding .h files.
llvm-svn: 84322
2009-10-17 08:12:36 +00:00
Dan Gohman
68e044e81a Add a form of addPreserved which takes a string argument, to allow passes
to declare that they preserve other passes without needing to pull in
additional header file or library dependencies. Convert MachineFunctionPass
and CodeGenLICM to make use of this.

llvm-svn: 83555
2009-10-08 17:00:02 +00:00
Devang Patel
a485e31081 Simplify assertion message to avoid confusion.
llvm-svn: 72731
2009-06-02 17:26:29 +00:00
Devang Patel
18da189d4d Clean up pass manager cache after each run.
llvm-svn: 68254
2009-04-01 22:34:41 +00:00
Devang Patel
e182bc0c48 Remove dead code.
llvm-svn: 68246
2009-04-01 21:27:08 +00:00
Duncan Sands
aee16d4916 Rename getAnalysisToUpdate to getAnalysisIfAvailable.
llvm-svn: 63198
2009-01-28 13:14:17 +00:00
Chris Lattner
c1ca63307d Speed up the passmgr by avoiding heap thrashing on vectors.
llvm-svn: 54515
2008-08-08 05:33:04 +00:00
Chris Lattner
e0b1ee937a Don't attribute in file headers anymore. See llvmdev for the
discussion of this change.  Boy are my fingers tired. ;-)

llvm-svn: 45411
2007-12-29 19:59:42 +00:00
Dan Gohman
1fba6fb9a8 Add a addRequiredTransitiveID member function, which is to
addRequiredTransitive as addRequiredID is to addRequired.

llvm-svn: 37031
2007-05-14 14:21:46 +00:00
Devang Patel
af0b4b4191 Proivde getAnalysis<FPAnalysis>(Func) support.
llvm-svn: 36159
2007-04-16 20:56:24 +00:00
Dan Gohman
42a3f4e16e Add the 'explicit' keyword to several constructors that accept one
argument that don't appear intended as implicit-conversion operators.

llvm-svn: 35280
2007-03-23 18:44:11 +00:00
Devang Patel
c1627f6538 1) Remove old AnalysisResolver.
2) Rename AnalysisResolver_New as AnalysisResolver

llvm-svn: 32938
2007-01-05 22:47:07 +00:00
Devang Patel
fcddd83bfc Remove old pass manager.
llvm-svn: 32927
2007-01-05 20:16:23 +00:00
Chris Lattner
e8d97c0b07 fit in 80 cols
llvm-svn: 32563
2006-12-13 21:56:10 +00:00
Devang Patel
3c8836df17 Add #ifdef switch toggle between old and new pass manager. However,
continue to use old pass manager at the moment. To use new manager
remove #define USE_OLD_PASSMANAGER 1 from Pass.h

llvm-svn: 32525
2006-12-13 02:36:01 +00:00
Devang Patel
cdb802ee01 Move getAnalysis() and getAnalysisID() definitions from Pass.h to
PassAnalysisSupport.h

llvm-svn: 32518
2006-12-13 00:23:44 +00:00
Devang Patel
6f0bb6fbed Add AnalysisResolver_New. It is a replacement for existing
AnalysisResolver.

llvm-svn: 32383
2006-12-08 23:28:54 +00:00
Chris Lattner
ed45ad33b7 Make the LLVM headers "-ansi -pedantic -Wno-long-long" clean.
Patch by Martin Partel!

llvm-svn: 26313
2006-02-22 16:23:43 +00:00
Reid Spencer
27134f31f2 Older compilers won't like the inline virtual destructor in the header file
so we put the destructor in Pass.cpp and make it non-inline.

llvm-svn: 21520
2005-04-25 01:01:35 +00:00
Reid Spencer
2a1b7a35ea Shut GCC 4.0 up when it complains about classes with virtual functions that
don't have virtual destructors.

llvm-svn: 21507
2005-04-24 22:20:32 +00:00
Misha Brukman
3f0aa3dbf8 Remove trailing whitespace
llvm-svn: 21408
2005-04-21 20:19:05 +00:00
Misha Brukman
50aeb0a322 Add AnalysisUsage::addRequiredTransitive() to keep analysis info alive for
future queries by clients.

llvm-svn: 12329
2004-03-12 06:13:15 +00:00