Commit Graph

52627 Commits

Author SHA1 Message Date
Bill Wendling
27b5658aff Remove no-longer-useful dyn_casts and pals.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149307 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-31 00:56:53 +00:00
Bill Wendling
7750c3fc9f Add a constified getLandingPad() method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149303 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-31 00:26:24 +00:00
Kostya Serebryany
a1a8a323f4 [asan] fix the ObjC support (asan Issue #33)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149300 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 23:50:10 +00:00
Chandler Carruth
beb05952ce Chris's constant data sequence refactoring actually enabled printing
vectors of all one bits to be printed more cleverly in the AsmPrinter.
Unfortunately, the byte value for all one bits is the same with
-fsigned-char as the error return of '-1'. Force this to be the unsigned
byte value when returning it to avoid this problem, and update the test
case for the shiny new behavior.

Yay for building LLVM and Clang with -funsigned-char.

Chris, please review, and let me know if there is any reason to not
desire this change. It seems good on the surface, and certainly intended
based on the code written.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149299 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 23:47:44 +00:00
Evan Cheng
893a045cdb PR11834: Use macros which are defined on Windows. Patch by Marina Yatsina.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149294 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 23:10:32 +00:00
Devang Patel
885f65b4a1 Intel syntax. Adjust special code, used to recognize cmp<comparison code>{ss,sd,ps,pd}, for intel syntax.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149291 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 22:47:12 +00:00
Chad Rosier
0cf6b99b96 Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149289 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 22:44:13 +00:00
Chad Rosier
431985a421 Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149275 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 21:13:22 +00:00
David Greene
448b73a95c Implement String Cast from Integer
Allow casts from integer to string.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149273 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 20:47:04 +00:00
Devang Patel
be3e310d5e Intel syntax. Support .intel_syntax directive.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149270 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 20:02:42 +00:00
Benjamin Kramer
630ecf0f53 Fix refacto.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149269 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 20:01:35 +00:00
Matt Beaumont-Gay
baffe7a6f3 Here's a new one: GCC was complaining about an only-used-in-asserts
*function*. Wrap the function in #ifndef NDEBUG.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149259 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 19:26:20 +00:00
Chris Lattner
8cf27efe40 Various improvements suggested by Duncan
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149255 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 18:19:30 +00:00
Douglas Gregor
b2f1b5028c Eliminate narrowing conversion in initializer list, to make C++11 happy
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149254 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 16:57:18 +00:00
Benjamin Kramer
9c68354956 X86: Simplify shuffle mask generation code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149248 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 15:16:21 +00:00
Alexander Potapenko
8375bc9236 Fix compilation of ASan tests on OS X Lion (see http://code.google.com/p/address-sanitizer/issues/detail?id=32)
The redzones emitted by AddressSanitizer for CFString instances confuse the linker and are of little use, so we shouldn't add them. 


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149243 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 10:40:22 +00:00
Craig Topper
cc30006391 Fix pattern for memory form of PSHUFD for use with FP vectors to remove bitcast to an integer vector that normal code wouldn't have. Also remove bitcasts from code that turns splat vector loads into a shuffle as it was making the broken pattern necessary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149232 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 07:50:31 +00:00
Chris Lattner
41b9920a13 fix a major oversight that is breaking some llvm-test tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149230 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 07:36:01 +00:00
Chris Lattner
36c744ff10 First step of flipping on ConstantDataSequential: enable ConstantDataVector
to be formed whenever ConstantVector::get is used.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149226 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 06:21:21 +00:00
Chris Lattner
b66fb5acbe when verbose asm is on, print integers in ConstantDataSequentials just
like normal integers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149223 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 05:55:11 +00:00
Chris Lattner
6e64c381da don't lose tail padding on ConstantDataAggregate vec3's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149222 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 05:49:43 +00:00
Chris Lattner
0cd0d81492 Fix ConstantFoldShuffleVectorInstruction to properly handle the case
when the result type has a different # elements than the input vectors.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149221 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 05:34:13 +00:00
Craig Topper
86c7c583a3 Move some XOP patterns into instruction definition. Replae VPCMOV intrinsic patterns with custom lowering to a target specific nodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149216 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 01:10:15 +00:00
Chris Lattner
d408f06048 Add bitcode reader and writer support for ConstantDataAggregate, which
should be feature complete now.  Lets see if it works.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149215 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-30 00:51:16 +00:00
Douglas Gregor
95fa4005f5 Move Clang's file-level locking facility over to LLVM's support
library, since it doesn't really have anything to do with Clang.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149203 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-29 20:15:10 +00:00
Anton Korobeynikov
6edd5884c9 Cleanups for EABI standard functions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149195 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-29 09:11:50 +00:00
Anton Korobeynikov
f349cb8f33 Use base AAPCS for varargs functions even for AAPCS-VFP CC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149194 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-29 09:06:09 +00:00
Jakob Stoklund Olesen
9f946a24d9 Fix some scavenger performance issues.
- Don't call malloc+free in the very hot forward().
- Don't call isTiedToDefOperand().
- Don't create BitVector temporaries.
- Merge DeadRegs into KillRegs.
- Eliminate the early clobber checks, they were irrelevant to scavenging.
- Remove unnecessary code from -Asserts builds.

This speeds up ARM PEI by 3.4x and overall llc -O0 codegen time by 11%.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149189 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-29 01:29:28 +00:00
Jakob Stoklund Olesen
685c23e758 Avoid creating BitVector temporaries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149188 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-29 01:29:25 +00:00
Nick Lewycky
5fef01db01 Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149185 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 23:33:44 +00:00
Bob Wilson
7750ff1e3c Add a note about a potential optimization for clz/ctz patterns for ARM
(and other targets).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149182 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 18:30:07 +00:00
James Molloy
2d8955a77c Ensure .AliasedSymbol() is called on all uses of getSymbol(). Affects ARM and MIPS ELF backends.
Fixes PR11877



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149180 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 15:58:32 +00:00
Benjamin Kramer
518ff566f5 Silence GCC's -Wreturn-type warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149179 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 15:28:41 +00:00
Rafael Espindola
8b01c82f25 Small improvement to the recursion detection logic from the previous commit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149175 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 06:22:14 +00:00
Rafael Espindola
e71cc86ad1 Handle recursive variable definitions directly. This gives us better error
messages and allows us to fix PR11865.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149174 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 05:57:00 +00:00
Kostya Serebryany
f1639abf1a [asan] correctly use ConstantExpr::getGetElementPtr. Catch by NAKAMURA Takumi
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149172 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 04:27:16 +00:00
Bill Wendling
0ae06de094 Reapply r149159 with a fix to add to a PHI node with a non-null parent.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149164 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 01:17:56 +00:00
Lang Hames
1c1c5bba57 Remove code that adds live ranges for dead defs. It seems to be breaking things.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149163 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 01:17:01 +00:00
Bill Wendling
afcb5b5ee8 Revert r149159 until I can fix tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149162 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 01:10:01 +00:00
Bill Wendling
b0064c6d8b Don't always create a separate block for the call to _Unwind_Resume.
Sometimes there is only one 'resume' instruction per function. In those
situations, we don't need a separate block for the call to _Unwind_Resume. In
fact, it adds a lot of overhead to code-gen if we do that -- especially at -O0.
If we have a single 'resume' instruction, just generate the call within that
block.
<rdar://problem/10694814>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149159 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 00:47:18 +00:00
David Greene
1d5013992f Fix Record Name Reference
Get the record name though the init to avoid an assert.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149153 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-28 00:03:24 +00:00
Lang Hames
3f8d3c7d72 Silence warning about parens for && within ||
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149152 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 23:52:25 +00:00
Rafael Espindola
04594aeffa Add r149110 back with a fix for when the vector and the int have the same
width.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149151 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 23:33:07 +00:00
Rafael Espindola
41cedd740d Revert r149110 and add a testcase that was crashing since that revision.
Unfortunately I also had to disable constant-pool-sharing.ll the code it tests has been
updated to use the IL logic.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149148 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 22:42:48 +00:00
Lang Hames
907cc8f38d Add a "moveInstr" method to LiveIntervals. This can be used to move instructions
around within a basic block while maintaining live-intervals.

Updated ScheduleTopDownLive in MachineScheduler.cpp to use the moveInstr API
when reordering MIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149147 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 22:36:19 +00:00
Lang Hames
ff21bb53ae Backing out ill-considered 'refactor'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149146 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 21:43:32 +00:00
Lang Hames
c5c2fcd307 Move some duplicate loops in the coalescer into their own function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149144 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 19:58:14 +00:00
Devang Patel
a28101e61a Intel Syntax: Parse mem operand with seg reg. QWORD PTR FS:[320]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149142 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 19:48:28 +00:00
Craig Topper
3982b3cc7b Move some patterns back near their instructions and use AddedComplexity to fix priority. Merge some patterns into their instruction definition.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149122 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 07:09:40 +00:00
Lang Hames
b3396dc003 Physreg dead defs should be handled too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149118 91177308-0d34-0410-b5e6-96231b3b80d8
2012-01-27 03:20:42 +00:00