- Mar 21, 2012
-
-
Gregory Szorc authored
This gives a lot of love to the docs for the C API. Like Clang's documentation, the C API is now organized into a Doxygen "module" (LLVMC). Each C header file is a child of the main module. Some modules (like Core) have a hierarchy of there own. The produced documentation is thus better organized (before everything was in one monolithic list). This patch also includes a lot of new documentation for APIs in Core.h. It doesn't document them all, but is better than none. Function docs are missing @param and @return annotation, but the documentation body now commonly provides help details (like the expected llvm::Value sub-type to expect). llvm-svn: 153157
-
- Mar 20, 2012
-
-
Anna Zaks authored
ImmutAVLTree uses random unsigned values as keys into a DenseMap, which could possibly happen to be the same value as the Tombstone or Entry keys in the DenseMap. Test case is hard to come up with. We randomly get failures on the internal static analyzer bot, which most likely hits this issue (hard to be 100% sure without the full stack). llvm-svn: 153148
-
- Mar 19, 2012
-
-
Michael J. Spencer authored
llvm-svn: 153051
-
Michael J. Spencer authored
Also add some documentation. llvm-svn: 153050
-
Chandler Carruth authored
violations I introduced. Also sort some of the instructions to get a more consistent ordering. Suggestions on still better / more consistent formatting would be welcome. I'm actually tempted to use a macro to define all of the delegate methods... llvm-svn: 153030
-
Chandler Carruth authored
type hierarchy. I wanted to use this for the inline cost rewrite, and found it was missing. llvm-svn: 153029
-
- Mar 17, 2012
-
-
Benjamin Kramer authored
This is particularly helpful as both arguments tend to be constants. llvm-svn: 152991
-
- Mar 16, 2012
-
-
Benjamin Kramer authored
Saves one machine word on MachineInstr (88->80 bytes on x86_64, 48->44 on i386). llvm-svn: 152930
-
Chandler Carruth authored
directly query the function information which this set was representing. This simplifies the interface of the inline cost analysis, and makes the always-inline pass significantly more efficient. Previously, always-inline would first make a single set of every function in the module *except* those marked with the always-inline attribute. It would then query this set at every call site to see if the function was a member of the set, and if so, refuse to inline it. This is quite wasteful. Instead, simply check the function attribute directly when looking at the callsite. The normal inliner also had similar redundancy. It added every function in the module with the noinline attribute to its set to ignore, even though inside the cost analysis function we *already tested* the noinline attribute and produced the same result. The only tricky part of removing this is that we have to be able to correctly remove only the functions inlined by the always-inline pass when finalizing, which requires a bit of a hack. Still, much less of a hack than the set of all non-always-inline functions was. While I was touching this function, I switched a heavy-weight set to a vector with sort+unique. The algorithm already had a two-phase insert and removal pattern, we were just needlessly paying the uniquing cost on every insert. This probably speeds up some compiles by a small amount (-O0 compiles with lots of always-inline, so potentially heavy libc++ users), but I've not tried to measure it. I believe there is no functional change here, but yell if you spot one. None are intended. Finally, the direction this is going in is to greatly simplify the inline cost query interface so that we can replace its implementation with a much more clever one. Along the way, all the APIs get simplified, so it seems incrementally good. llvm-svn: 152903
-
Chandler Carruth authored
analysis implementation. The header was already separated. Also cleanup all the comments in the header to follow a nice modern doxygen form. There is still plenty of cruft here, but some of that will fall out in subsequent refactorings and this was an easy step in the right direction. No functionality changed here. llvm-svn: 152898
-
Andrew Trick authored
Only record IVUsers that are dominated by simplified loop headers. Otherwise SCEVExpander will crash while looking for a preheader. I previously tried to work around this in LSR itself, but that was insufficient. This way, LSR can continue to run if some uses are not in simple loops, as long as we don't attempt to analyze those users. Fixes <rdar://problem/11049788> Segmentation fault: 11 in LoopStrengthReduce llvm-svn: 152892
-
NAKAMURA Takumi authored
Revert r152613 (and r152614), "Inline the d'tor and add an anchor instead." for workaround of g++-4.4's miscompilation. It caused MSP430DAGToDAGISel::SelectIndexedBinOp() to be miscompiled. When two ReplaceUses()'s are expanded as inline, vtable in base class is stored to latter (ISelUpdater)ISU. llvm-svn: 152877
-
- Mar 15, 2012
-
-
Jakob Stoklund Olesen authored
We cannot limit the concatenated instruction names to 64K. ARM is already at 32K, and it is easy to imagine a target with more instructions. llvm-svn: 152817
-
Chandler Carruth authored
changed since. No one was using it. It is yet another consumer of the InlineCost interface that I'd like to change. llvm-svn: 152769
-
Chandler Carruth authored
side of things. This is all dead code. llvm-svn: 152759
-
Chandler Carruth authored
correlated pairs of pointer arguments at the callsite. This is designed to recognize the common C++ idiom of begin/end pointer pairs when the end pointer is a constant offset from the begin pointer. With the C-based idiom of a pointer and size, the inline cost saw the constant size calculation, and this provides the same level of information for begin/end pairs. In order to propagate this information we have to search for candidate operations on a pair of pointer function arguments (or derived from them) which would be simplified if the pointers had a known constant offset. Then the callsite analysis looks for such pointer pairs in the argument list, and applies the appropriate bonus. This helps LLVM detect that half of bounds-checked STL algorithms (such as hash_combine_range, and some hybrid sort implementations) disappear when inlined with a constant size input. However, it's not a complete fix due the inaccuracy of our cost metric for constants in general. I'm looking into that next. Benchmarks showed no significant code size change, and very minor performance changes. However, specific code such as hashing is showing significantly cleaner inlining decisions. llvm-svn: 152752
-
- Mar 14, 2012
-
-
Francois Pichet authored
Commit r152704 exposed a latent MSVC limitation (aka bug). Both ilist and and iplist contains the same function: template<class InIt> void insert(iterator where, InIt first, InIt last) { for (; first != last; ++first) insert(where, *first); } Also ilist inherits from iplist and ilist contains a "using iplist<NodeTy>::insert". MSVC doesn't know which one to pick and complain with an error. I think it is safe to delete ilist::insert since it is redundant anyway. llvm-svn: 152746
-
Andrew Trick authored
New flags: -misched-topdown, -misched-bottomup. They can be used with the default scheduler or with -misched=shuffle. Without either topdown/bottomup flag -misched=shuffle now alternates scheduling direction. LiveIntervals update is unimplemented with bottom-up scheduling, so only -misched-topdown currently works. Capped the ScheduleDAG hierarchy with a concrete ScheduleDAGMI class. ScheduleDAGMI is aware of the top and bottom of the unscheduled zone within the current region. Scheduling policy can be plugged into the ScheduleDAGMI driver by implementing MachineSchedStrategy. ConvergingScheduler is now the default scheduling algorithm. It exercises the new driver but still does no reordering. llvm-svn: 152700
-
Benjamin Kramer authored
llvm-svn: 152692
-
Benjamin Kramer authored
llvm-svn: 152688
-
- Mar 13, 2012
-
-
Pete Cooper authored
Target override to allow CodeGenPrepare to sink address operands to intrinsics in the same way it current does for loads and stores llvm-svn: 152666
-
Benjamin Kramer authored
llvm-svn: 152659
-
Bill Wendling authored
No functionality change. llvm-svn: 152658
-
Chris Lattner authored
fixing rdar://11039258, an issue that came up when inspecting clang's bootstrapped codegen. llvm-svn: 152635
-
Duncan Sands authored
trunc(ptrtoint(x-y))" optimization introduced by Chandler. llvm-svn: 152626
-
Stepan Dyatkovskiy authored
llvm-svn: 152624
-
Duncan Sands authored
take a TargetLibraryInfo parameter. Internally, rather than passing TD, TLI and DT parameters around all over the place, introduce a struct for holding them. llvm-svn: 152623
-
Eli Bendersky authored
Also refactor the existing OProfile profiling code to reuse the same interfaces with the VTune profiling code. In addition, unit tests for the profiling interfaces were added. This patch was prepared by Andrew Kaylor and Daniel Malea, and reviewed in the llvm-commits list by Jim Grosbach llvm-svn: 152620
-
Bill Wendling authored
llvm-svn: 152613
-
- Mar 11, 2012
-
-
Craig Topper authored
llvm-svn: 152538
-
Stepan Dyatkovskiy authored
Renamed methods caseBegin, caseEnd and caseDefault with case_begin, case_end, and case_default. Added some notes relative to case iterators. llvm-svn: 152532
-
Douglas Gregor authored
llvm-svn: 152525
-
Craig Topper authored
Shrink and reorder some fields in MCOperandInfo to fit it in 8 bytes to reduce size of static tables. llvm-svn: 152524
-
Michael J. Spencer authored
llvm-svn: 152523
-
Aaron Ballman authored
llvm-svn: 152518
-
Michael J. Spencer authored
it would fail with {,u}int64_t on x86-64 Linux. This also removes code duplication. llvm-svn: 152517
-
- Mar 10, 2012
-
-
Chandler Carruth authored
a common collection of methods on Value, and share their implementation. We had two variations in two different places already, and I need the third variation for inline cost estimation. Reviewed by Duncan Sands on IRC, but further comments here welcome. llvm-svn: 152490
-
- Mar 09, 2012
-
-
David Meyer authored
* Add enums and structures for GNU version information. * Implement extraction of that information on a per-symbol basis (ELFObjectFile::getSymbolVersion). * Implement a generic interface, GetELFSymbolVersion(), for getting the symbol version from the ObjectFile (hides the templating). * Have llvm-readobj print out the version, when available. * Add a test for the new feature: readobj-elf-versioning.test llvm-svn: 152436
-
David Meyer authored
Make Binary::TypeID more granular, to distinguish between ELF 32/64 little/big llvm-svn: 152435
-
Daniel Dunbar authored
names. llvm-svn: 152413
-