Nick Lewycky
389fa6c38d
Silence tsan false-positives (tsan can't track things which are only safe due to
...
memory fences) in statistics registration, which works the same way that
ManagedStatic registration does.
llvm-svn: 145869
2011-12-05 23:07:05 +00:00
Benjamin Kramer
6009b2df99
Let printf do the formatting instead aligning strings ourselves.
...
While at it, merge some format strings.
llvm-svn: 142140
2011-10-16 16:30:34 +00:00
Daniel Dunbar
d4a7704765
Support: Add llvm::AreStatisticsEnabled().
...
llvm-svn: 126558
2011-02-26 23:17:12 +00:00
Michael J. Spencer
d5ec932c3a
Merge System into Support.
...
llvm-svn: 120298
2010-11-29 18:16:10 +00:00
Jim Grosbach
4cf3acbde6
remove trailing whitespace
...
llvm-svn: 111254
2010-08-17 17:37:22 +00:00
Douglas Gregor
63f8158cff
Introduce namespace-scope functions to enable LLVM statistics without
...
passing the command-line parameter "-stats" and to print the resulting
statistics without calling llvm_shutdown().
llvm-svn: 99893
2010-03-30 17:32:08 +00:00
Chris Lattner
76a4736a55
rename GetLibSupportInfoOutputFile -> CreateInfoOutputFile and
...
have it always return a new stream to simplify clients.
llvm-svn: 99874
2010-03-30 05:01:08 +00:00
Chris Lattner
3e11ba35b0
if a timergroup is destroyed before its timers, print times.
...
llvm-svn: 99873
2010-03-30 04:58:26 +00:00
David Greene
d36fd269e1
Change errs() to dbgs().
...
llvm-svn: 92642
2010-01-05 01:28:47 +00:00
Torok Edwin
dd5b0b7cda
Avoid using mutex locks if not in multithreaded mode by using a SmartScopedMutex
...
in RegisterStatistic.
llvm-svn: 82896
2009-09-27 11:08:03 +00:00
Chris Lattner
e22a1d941e
remove some uses of llvm/Support/Streams.h
...
llvm-svn: 79842
2009-08-23 08:43:55 +00:00
Owen Anderson
75f0f1cc6c
Have scoped mutexes take referenes instead of pointers.
...
llvm-svn: 74931
2009-07-07 18:33:04 +00:00
Owen Anderson
2d65e89f30
Use atomic operations when accessing statistics, and make the lazy initialization of statistics actually threadsafe.
...
llvm-svn: 74005
2009-06-23 21:19:38 +00:00
Owen Anderson
9826df9126
Guard the statistics table.
...
llvm-svn: 73916
2009-06-22 23:08:27 +00:00
Dan Gohman
bab18cae46
Clean up the use of static and anonymous namespaces. This turned up
...
several things that were neither in an anonymous namespace nor static
but not intended to be global.
llvm-svn: 51017
2008-05-13 00:00:25 +00:00
Evan Cheng
d9353009b7
Fix more -Wshorten-64-to-32 warnings.
...
llvm-svn: 50659
2008-05-05 18:30:58 +00:00
Anton Korobeynikov
0c5e186924
Unbreak build with gcc 4.3: provide missed includes and silence most annoying warnings.
...
llvm-svn: 47367
2008-02-20 11:08:44 +00:00
Chris Lattner
ad9a6ccb83
Remove attribution from file headers, per discussion on llvmdev.
...
llvm-svn: 45418
2007-12-29 20:36:04 +00:00
Chris Lattner
87e0f0787e
eliminate constructor from Statistic class. It is now impossible to get a
...
static constructor for them :). Transition complete.
llvm-svn: 32710
2006-12-19 23:17:40 +00:00
Chris Lattner
c18ec8716e
Refactor statistic a big and introduce a horrible-but-necessary macro
...
(STATISTIC), which allows us to define statistics that don't introduce
static ctors into the .o files. I'm migrating code over to use this
incrementally.
llvm-svn: 32687
2006-12-19 21:27:47 +00:00
Chris Lattner
9c52dc6c34
Change the implementation of statistic to not need destructors at all.
...
Instead, the stat info is printed when llvm_shutdown() is called.
These also don't need static ctors, but getting rid of them is uglier:
still investigating. This reduces the number of static dtors in llvm from
~1400 to ~750.
llvm-svn: 32372
2006-12-08 20:00:42 +00:00
Bill Wendling
fe0af72bc4
Don't use <sstream> in Streams.h but <iosfwd> instead.
...
llvm-svn: 32340
2006-12-07 23:41:45 +00:00
Bill Wendling
4d1444725b
Removed more <iostream> includes
...
llvm-svn: 32321
2006-12-07 20:28:15 +00:00
Chris Lattner
e626f6de68
merge the Statistic and StatisticBase classes, eliminating virtual methods
...
and eliminating #includes from the Statistic.h file.
llvm-svn: 32282
2006-12-06 18:20:44 +00:00
Chris Lattner
a531ce882e
Detemplatize the Statistic class. The only type it is instantiated with
...
is 'unsigned'.
llvm-svn: 32279
2006-12-06 17:46:33 +00:00
Chris Lattner
e84b1b8352
Instantiate Statistic<> in one place, not in every .o file that uses it.
...
llvm-svn: 29971
2006-08-30 04:17:00 +00:00
Chris Lattner
a396e6d9ba
Add some out-of-line virtual dtors so that the class has a "home", preventing
...
vtables for (e.g.) Instruction from being emitted into every .o file.
llvm-svn: 28898
2006-06-21 16:53:47 +00:00
Misha Brukman
933cdaf254
Remove trailing whitespace
...
llvm-svn: 21422
2005-04-21 22:55:34 +00:00
Reid Spencer
c4abcbefb1
Changes For Bug 352
...
Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.
llvm-svn: 16137
2004-09-01 22:55:40 +00:00
Alkis Evlogimenos
ac49a51bac
Pass std::string to constructor as const reference to avoid multiple
...
copies.
llvm-svn: 10705
2004-01-06 09:16:02 +00:00
Chris Lattner
30ae898eb7
Finegrainify namespacification
...
Make the Timer code give correct user/system/user+system times when -track-memory is enabled
llvm-svn: 10463
2003-12-14 21:27:33 +00:00
Brian Gaeke
d25f86d683
Put all LLVM code into the llvm namespace, as per bug 109.
...
llvm-svn: 9903
2003-11-11 22:41:34 +00:00
John Criswell
b402729b30
Added LLVM project notice to the top of every C++ source file.
...
Header files will be on the way.
llvm-svn: 9298
2003-10-20 19:43:21 +00:00
Chris Lattner
54ccdd9b17
This file uses stable_sort
...
llvm-svn: 7831
2003-08-13 21:32:37 +00:00
Chris Lattner
ef90e1b189
Move debug functionality to Debug.cpp/Debug.h
...
llvm-svn: 7494
2003-08-01 22:15:41 +00:00
Chris Lattner
805f8d646e
Add a new info-output-file option (hidden from --help) which is to be used by
...
the testing scripts to avoid breaking diffs while still gathering stats.
llvm-svn: 6067
2003-05-09 20:05:44 +00:00
Chris Lattner
ae91295cfa
Remove the -debug option from release executables
...
llvm-svn: 5521
2003-02-09 21:13:57 +00:00
Chris Lattner
8f38efd9dd
Add #include
...
llvm-svn: 4291
2002-10-27 19:08:03 +00:00
Anand Shukla
02acbe2c93
added cast to unsigned to compile with gcc3.2 (sparc)
...
llvm-svn: 4041
2002-10-04 23:56:18 +00:00
Chris Lattner
c2322d5fac
- Rework Statistics:
...
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
* Broke constructor to take two const char * arguments instead of one, so
that indendation can be taken care of automatically.
* Sort the list by pass name when printing
* Make sure to print all statistics as a group, instead of randomly when
the statistics dtors are called.
llvm-svn: 3999
2002-10-01 22:35:45 +00:00
Chris Lattner
99ad379582
*** empty log message ***
...
llvm-svn: 2985
2002-07-22 02:10:13 +00:00
Chris Lattner
7f8f0b5863
Implement a new command line option, -debug, which is meant to unify all of
...
the random debugging macros scattered throughout llvm.
The new DEBUG(x) macro should be used instead of special purpose debug macros.
llvm-svn: 2709
2002-05-22 17:06:20 +00:00
Chris Lattner
8c131ef721
Initial checkin of Statistic class.
...
llvm-svn: 2598
2002-05-10 15:36:46 +00:00