| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
This commit completely removes what is left of the simplify-libcalls
pass. All of the functionality has now been migrated to the instcombine
and functionattrs passes. The following C API functions are now NOPs:
1. LLVMAddSimplifyLibCallsPass
2. LLVMPassManagerBuilderSetDisableSimplifyLibCalls
llvm-svn: 184459
|
|
|
|
|
|
|
| |
The 'Modified' variable should have been removed from SimplifyLibCalls
in r177619, but was missed. This commit removes it.
llvm-svn: 177622
|
|
|
|
|
|
|
|
|
|
|
|
| |
The simplify-libcalls pass implemented a doInitialization hook to infer
function prototype attributes for well-known functions. Given that the
simplify-libcalls pass is going away *and* that the functionattrs pass
is already in place to deduce function attributes, I am moving this logic
to the functionattrs pass. This approach was discussed during patch
review:
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20121126/157465.html.
llvm-svn: 177619
|
|
|
|
|
|
|
|
| |
The 'nobuiltin' attribute is applied to call sites to indicate that LLVM should
not treat the callee function as a built-in function. I.e., it shouldn't try to
replace that function with different code.
llvm-svn: 175835
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
into their new header subdirectory: include/llvm/IR. This matches the
directory structure of lib, and begins to correct a long standing point
of file layout clutter in LLVM.
There are still more header files to move here, but I wanted to handle
them in separate commits to make tracking what files make sense at each
layer easier.
The only really questionable files here are the target intrinsic
tablegen files. But that's a battle I'd rather not fight today.
I've updated both CMake and Makefile build systems (I think, and my
tests think, but I may have missed something).
I've also re-sorted the includes throughout the project. I'll be
committing updates to Clang, DragonEgg, and Polly momentarily.
llvm-svn: 171366
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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. =]
llvm-svn: 169131
|
|
|
|
|
|
|
|
|
| |
The simplify-libcalls pass maintained a statistic to count the number
of library calls that have been simplified. Now that library call
simplification is being carried out in instcombine the statistic should
be moved to there.
llvm-svn: 168975
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch migrates the puts optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
All the simplifiers from simplify-libcalls have now been migrated to
instcombine. Yay! Just a few other bits to migrate (prototype attribute
inference and a few statistics) and simplify-libcalls can finally be put
to rest.
llvm-svn: 168925
|
|
|
|
|
|
|
| |
This patch migrates the fputs optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168893
|
|
|
|
|
|
|
| |
This patch migrates the fwrite optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168892
|
|
|
|
|
|
|
| |
This patch migrates the fprintf optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168891
|
|
|
|
|
|
|
| |
This patch migrates the sprintf optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168677
|
|
|
|
|
|
|
| |
This patch migrates the printf optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168604
|
|
|
|
|
|
|
| |
This patch migrates the toascii optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168580
|
|
|
|
|
|
|
| |
This patch migrates the isascii optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168579
|
|
|
|
|
|
|
| |
This patch migrates the isdigit optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168578
|
|
|
|
|
|
|
| |
This patch migrates the *abs optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168574
|
|
|
|
|
|
|
| |
This patch migrates the ffs* optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 168571
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch migrates the math library call simplifications from the
simplify-libcalls pass into the instcombine library call simplifier.
I have typically migrated just one simplifier at a time, but the math
simplifiers are interdependent because:
1. CosOpt, PowOpt, and Exp2Opt all depend on UnaryDoubleFPOpt.
2. CosOpt, PowOpt, Exp2Opt, and UnaryDoubleFPOpt all depend on
the option -enable-double-float-shrink.
These two factors made migrating each of these simplifiers individually
more of a pain than it would be worth. So, I migrated them all together.
llvm-svn: 167815
|
|
|
|
| |
llvm-svn: 167698
|
|
|
|
|
|
|
| |
This patch migrates the memset optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167689
|
|
|
|
|
|
|
| |
This patch migrates the memmove optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167687
|
|
|
|
|
|
|
| |
This patch migrates the memcpy optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167686
|
|
|
|
|
|
|
| |
This patch migrates the memcmp optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167683
|
|
|
|
|
|
|
| |
This patch migrates the strstr optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167682
|
|
|
|
|
|
|
| |
This patch migrates the strcspn optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167675
|
|
|
|
|
|
|
| |
This patch migrates the strspn optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167568
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
getIntPtrType support for multiple address spaces via a pointer type,
and also introduced a crasher bug in the constant folder reported in
PR14233.
These commits also contained several problems that should really be
addressed before they are re-committed. I have avoided reverting various
cleanups to the DataLayout APIs that are reasonable to have moving
forward in order to reduce the amount of churn, and minimize the number
of commits that were reverted. I've also manually updated merge
conflicts and manually arranged for the getIntPtrType function to stay
in DataLayout and to be defined in a plausible way after this revert.
Thanks to Duncan for working through this exact strategy with me, and
Nick Lewycky for tracking down the really annoying crasher this
triggered. (Test case to follow in its own commit.)
After discussing with Duncan extensively, and based on a note from
Micah, I'm going to continue to back out some more of the more
problematic patches in this series in order to ensure we go into the
LLVM 3.2 branch with a reasonable story here. I'll send a note to
llvmdev explaining what's going on and why.
Summary of reverted revisions:
r166634: Fix a compiler warning with an unused variable.
r166607: Add some cleanup to the DataLayout changes requested by
Chandler.
r166596: Revert "Back out r166591, not sure why this made it through
since I cancelled the command. Bleh, sorry about this!
r166591: Delete a directory that wasn't supposed to be checked in yet.
r166578: Add in support for getIntPtrType to get the pointer type based
on the address space.
llvm-svn: 167221
|
|
|
|
|
|
|
| |
This patch migrates the strto* optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167119
|
|
|
|
|
|
|
| |
This patch migrates the strpbrk optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167105
|
|
|
|
|
|
|
| |
This patch migrates the strlen optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167103
|
|
|
|
|
|
|
| |
This patch migrates the strncpy optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.
llvm-svn: 167102
|
|
|
|
|
|
|
|
| |
This patch migrates the stpcpy optimizations from the simplify-libcalls
pass into the instcombine library call simplifier. Note that the
__stpcpy_chk simplifications were migrated in a previous commit.
llvm-svn: 167083
|
|
|
|
|
|
|
|
|
| |
address space.
This checkin also adds in some tests that utilize these paths and updates some of the
clients.
llvm-svn: 166578
|
|
|
|
|
|
|
|
| |
input is zero.
Fixes PR13028.
llvm-svn: 166313
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch migrates the strcpy optimizations from the simplify-libcalls pass
into the instcombine library call simplifier. Note also that StrCpyChkOpt
has been updated with a few simplifications that were being done in the
simplify-libcalls version of StrCpyOpt, but not in the migrated implementation
of StrCpyOpt. There is no reason to overload StrCpyOpt with fortified and
regular simplifications in the new model since there is already a dedicated
simplifier for __strcpy_chk.
llvm-svn: 166198
|
|
|
|
|
|
| |
simplify the code a bit. No functionality change.
llvm-svn: 166009
|
|
|
|
|
|
| |
own class named AttrBuilder. No functionality change.
llvm-svn: 165960
|
|
|
|
|
|
|
|
|
|
| |
Convert the internal representation of the Attributes class into a pointer to an
opaque object that's uniqued by and stored in the LLVMContext object. The
Attributes class then becomes a thin wrapper around this opaque
object. Eventually, the internal representation will be expanded to include
attributes that represent code generation options, etc.
llvm-svn: 165917
|
|
|
|
|
|
|
| |
This patch migrates the strcmp and strncmp optimizations from the
simplify-libcalls pass into the instcombine library call simplifier.
llvm-svn: 165915
|
|
|
|
|
|
|
| |
This patch migrates the strchr and strrchr optimizations from the
simplify-libcalls pass into the instcombine library call simplifier.
llvm-svn: 165875
|
|
|
|
|
|
|
| |
This patch migrates the strcat and strncat optimizations from the
simplify-libcalls pass into the instcombine library call simplifier.
llvm-svn: 165874
|
|
|
|
|
|
|
| |
namespace. Use the attribute's enum value instead. No functionality change
intended.
llvm-svn: 165610
|
|
|
|
| |
llvm-svn: 165402
|
|
|
|
| |
llvm-svn: 162383
|
|
|
|
|
|
|
| |
optimizations are guarded by the -enable-double-float-shrink LLVM option.
Last bit of PR13574. Patch by Weiming Zhao <weimingz@codeaurora.org>.
llvm-svn: 162368
|
|
|
|
|
|
| |
functional change intended. Patch by Weiming Zhao <weimingz@codeaurora.org>.
llvm-svn: 162363
|
|
|
|
|
|
| |
to shrink from double to float.
llvm-svn: 162173
|
|
|
|
|
|
| |
Thanks Eli for noticing.
llvm-svn: 160787
|
|
|
|
|
|
|
|
|
| |
creating a call to a library function.
Update all clients to pass the TLI information around.
Previous draft reviewed by Eli.
llvm-svn: 160733
|