Commit Graph

87160 Commits

Author SHA1 Message Date
NAKAMURA Takumi
ff9ca8c081 test/Transforms/SimplifyLibCalls/SPrintF.ll: Suppress this for now. r168677 unveiled another failure.
FYI, this test makes no sense with "not grep"... I saw "assertion failure" in stderr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168679 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 06:42:48 +00:00
Preston Briggs
6ee74f52e9 Modify depends(Src, Dst, PossiblyLoopIndependent).
If the Src and Dst are the same instruction,
no loop-independent dependence is possible,
so we force the PossiblyLoopIndependent flag to false.

The test case results are updated appropriately.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168678 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 06:41:46 +00:00
Meador Inge
69ea027e04 instcombine: Migrate sprintf optimizations
This patch migrates the sprintf optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168677 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 05:57:54 +00:00
Jakub Staszak
df22702db0 Remove unneeded #include.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168670 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 02:00:27 +00:00
Eric Christopher
eb6363adf0 The section is .debug_line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168666 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:40:36 +00:00
Andrew Kaylor
b709f9fe5a Make building of llvm-jitlistener conditional on the USE_INTEL_JITEVENTS setting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168665 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:24:25 +00:00
Jakub Staszak
388ffa7f66 Remove unneeded #include.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168664 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:22:15 +00:00
NAKAMURA Takumi
a823f18af4 llvm/CodeGen: Remove empty files in r168659.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168663 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:21:50 +00:00
Joe Abbey
eaac37ece1 Code pretification
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168661 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:20:22 +00:00
Jakub Staszak
07cde58fa0 Remove unused forward declaration.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168660 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:16:37 +00:00
Jakub Staszak
af650354a1 Remove unused MachineLoopRanges analysis.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168659 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:14:34 +00:00
Chad Rosier
277068fe40 Extend test case for r168657.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168658 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:10:48 +00:00
Chad Rosier
fc17ddd889 [arm fast-isel] Appease the machine verifier by using the proper register
classes.  The associated test case still doesn't pass, but it does have far
fewer issues.
rdar://12719844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168657 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:06:49 +00:00
Michael Ilseman
bc43fe1efe Fast-math test for SimplifyInstruction: fold multiply by 0
Applied the patch, rather than committing it.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168656 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 01:00:22 +00:00
Owen Anderson
9780d352b9 Revert r168635 "Step towards implementation of pass manager with doInitialization and doFinalization per module detangled from runOn?? calls, still has temporary code not to break ASAN to be removed when that pass conforms to the proposed model".
It appears to have broken at least one buildbot.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168654 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:53:24 +00:00
Richard Smith
6f6b97daf6 Remove some Clang-specific ownership roles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168653 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:48:36 +00:00
Michael Ilseman
a33e3d75fe Fast-math flags documentation added to LangRef
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168652 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:48:29 +00:00
NAKAMURA Takumi
cb84142195 llvm/test/CodeGen/X86/2012-07-15-broadcastfold.ll: Loosen expression corresponding to r168627. Win32 and *bsd were affected.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168651 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:48:27 +00:00
Michael Ilseman
bb22ad1e1b Fast-math test for SimplifyInstruction: fold multiply by 0
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168649 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:47:20 +00:00
Michael Ilseman
eb61c920f1 Fast-math optimization: fold multiply by zero
Added in first optimization using fast-math flags to serve as an example for following optimizations. SimplifyInstruction will now try to optimize an fmul observing its FastMathFlags to see if it can fold multiply by zero when 'nnan' and 'nsz' flags are set.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168648 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:46:26 +00:00
Michael Ilseman
a52f3ae45c Fast-math test case for bitcode and textual reading/writing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168647 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:45:08 +00:00
Michael Ilseman
495d10ad56 Fast-math flags for the bitcode
Added in bitcode enum for the serializing of fast-math flags. Added in the reading/writing of fast-math flags from the OptimizationFlags record for BinaryOps.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168646 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:43:38 +00:00
Michael Ilseman
15c13d3e63 Fast-math flags for LLVM IR parsing and printing
Added in the ability to read LLVM IR text that contains fast-math flags as a sequence of capital letters separated by spaces in any order. Added in the printing of the fast-math flags in a canonical order, and don't print the other flags when 'fast' is specified, as 'fast' implies all the others.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168645 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:42:44 +00:00
Eric Christopher
4d26533234 Make comment names match function names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168644 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:41:57 +00:00
Eric Christopher
74802f7e43 Add in sections for the fission case (no change so incorrect) and
add a TODO for starting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168643 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:41:54 +00:00
Michael Ilseman
125fc7fefd Fast-math interfaces for Instructions
Add in getter/setter methods for Instructions, allowing them to be the interface to FPMathOperator similarly to now NUS/NSW is handled.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168642 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:41:22 +00:00
Michael Ilseman
ab4649b25f Fast-math flags added to FPMathOperator.
Created FastMathFlags convenience struct for the getting and setting of fast-math flags en masse. Added SubclassOptionalData bitfields and corresponding getters/setters to FPMathOperator for the various fast-math flags.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168641 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:40:00 +00:00
Richard Smith
400581a924 Move Clang code owners list from llvm/ to cfe/.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168640 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:39:52 +00:00
Eric Christopher
8ba01175cc Reorder section output ordering.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168638 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:13:58 +00:00
Eric Christopher
bdab800b02 Whitespace cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168637 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-27 00:13:51 +00:00
Owen Anderson
0d30d30d58 Step towards implementation of pass manager with doInitialization and doFinalization per module detangled from runOn?? calls, still has temporary code not to break ASAN to be removed when that pass conforms to the proposed model
Patch by Pedro Artigas, with feedback from by Chandler Carruth.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168635 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:54:47 +00:00
Chad Rosier
8d20b5f9ff Add an assertion to ensure freezeReservedRegs() is only ever called once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168633 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:37:07 +00:00
Eli Bendersky
527ba9c88d Make this test less sensitive.
It currently assumes register numbering and any harmless change in the X86
register naming makes it fail. It's enough to match the register names.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168632 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:27:09 +00:00
Chad Rosier
728aede2e9 Now that the X86 Maximal Stack Alignment Check pass has been removed (i.e.,
r168627), we no longer need to call the freezeReservedRegs() function a second
time.  Previously, this pass was conservatively adding the FP to the set of
reserved registers, requiring the second update to the reserved registers.
rdar://12719844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168631 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:25:41 +00:00
Chad Rosier
216532ac0a Now that the X86 Maximal Stack Alignment Check pass has been removed (i.e.,
r168627), we no longer need to call the freezeReservedRegs() function a second
time.  Previously, this pass was conservatively adding the FP to the set of
reserved registers, requiring the second update to the reserved registers.
rdar://12719844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168630 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:14:37 +00:00
Eli Friedman
0c617e6026 Get rid of the getPointeeAlignment helper function from
InstCombineLoadStoreAlloca.cpp, which had many issues.
(At least two bugs were noted on llvm-commits, and it was overly conservative.)
Instead, use getOrEnforceKnownAlignment.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168629 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 23:04:53 +00:00
Chad Rosier
1243922fc1 Remove the X86 Maximal Stack Alignment Check pass as it is no longer necessary.
This pass was conservative in that it always reserved the FP to enable dynamic
stack realignment, which allowed the RA to use aligned spills for vector
registers.  This happens even when spills were not necessary.  The RA has 
since been improved to use unaligned spills when necessary.

The new behavior is to realign the stack if the frame pointer was already
reserved for some other reason, but don't reserve the frame pointer just
because a function contains vector virtual registers.

Part of rdar://12719844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168627 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 22:55:05 +00:00
Jakub Staszak
bb8ddc7e4f Don't use iterator after being erased.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168622 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 22:14:19 +00:00
Bill Wendling
8a66b6ab45 Correct copy-pasto where we're talking about function attributes and not parameter attributes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168619 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 22:04:13 +00:00
Jyotsna Verma
5c1f3d1a83 Fix comments in HexagonOperands.td.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168617 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 21:56:51 +00:00
Shuxin Yang
b30e256993 rdar://12329730 (defect 2)
Enhancement to InstCombine. Try to catch this opportunity:
  
 ---------------------------------------------------------------
 ((X^C1) >> C2) ^ C3  => (X>>C2) ^ ((C1>>C2)^C3)
  where the subexpression "X ^ C1" has more than one uses, and
  "(X^C1) >> C2" has single use. 
 ---------------------------------------------------------------- 

 Reviewed by Nadav (with minor change per his request).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168615 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 21:44:25 +00:00
Jakub Staszak
ec66ac5318 Remove unneeded #includes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168608 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 21:04:19 +00:00
Meador Inge
d6d6859850 Fix a comment bug in toascii simplifier
When I migrated the toascii simplifier in r168580 Benjamin Kramer noticed
a bug in one of the comments that I migrated.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168605 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 20:37:23 +00:00
Meador Inge
d7aa3231f7 instcombine: Migrate printf optimizations
This patch migrates the printf optimizations from the simplify-libcalls
pass into the instcombine library call simplifier.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168604 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 20:37:20 +00:00
Nadav Rotem
22689b6034 Move the code that uses SCEVs prior to creating the new loops.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168601 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 19:51:46 +00:00
Jakub Staszak
d642baf4be Normalize splat 256bit vectors with 8 elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168600 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 19:24:31 +00:00
Benjamin Kramer
ed9e442cf0 Decouple MCInstBuilder from the streamer per Eli's request.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168597 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 18:05:52 +00:00
Matt Beaumont-Gay
70af909f67 Remove stray trailing backslash
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168592 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 16:27:22 +00:00
Dmitry Vyukov
9a33f9f980 tsan: fix lint warnings
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168590 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 14:55:26 +00:00
Eli Bendersky
a5cf16fc51 Rewrite test to not use a FileCheck variable and redefine it on the same line.
In preparation for the FileCheck functionality change which will allow using
a variable later on the same line.

No functionality change.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168588 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-26 14:09:46 +00:00