Commit Graph

32112 Commits

Author SHA1 Message Date
Victor Hernandez
399e45b459 Fit code within 80 columns
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81459 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 20:18:57 +00:00
Sean Callanan
7893ec6494 Added XOR instructions for rAX and immediates of
various widths.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81458 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 19:52:26 +00:00
Sean Callanan
2f34a136b5 Added MOV instructions between rAX and memory offsets,
including segment offsets and (for 8-bit operands)
absolute offsets.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81457 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 18:33:42 +00:00
Sean Callanan
1f24e01b87 Added a variety of PUSH and POP instructions, including
ones capable of accessing R/M operands instead of just
registers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81456 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 18:29:13 +00:00
Bill Wendling
73c5a61725 Exit early if exception handling isn't supported.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81454 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 18:28:06 +00:00
Andreas Neustifter
0c0de66ea4 Make ProfileEstimator more robust on general CFGs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81450 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 16:30:38 +00:00
Benjamin Kramer
b84c5ae3d4 Add some braces to make newer GCCs happy and update CMakeLists.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81443 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 11:31:39 +00:00
Andreas Neustifter
b4b1c9fa23 Cleaned up code by factoring out common portions of edge loading into function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81438 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 07:12:35 +00:00
Nick Lewycky
fd5249e15b Correctly handle the case where a comparison is created in one BasicBlock and
used by a terminator in another.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81437 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 07:02:09 +00:00
Bill Wendling
28275fdf02 Comment and whitespace cleanups. No intentional functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81436 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 06:50:01 +00:00
Bill Wendling
a2f6449a57 Revert part of my r81424 patch. I removed what looked like superfluous padding
from the exception tables. However, Duncan explained why it's a can of worms to
do it the GCC way. I went back to doing it the LLVM way and added Duncan's
explanation so that I don't do this again in the future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81434 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 06:27:16 +00:00
Evan Cheng
fabcb9127f Add malloc call utility functions. Patch by Victor Hernandez.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81426 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 04:36:43 +00:00
Bill Wendling
fe220285b5 Don't hardcode the TType format size. In fact, rework the code so that it's more
like what GCC outputs. The mysterious code to insert padding wasn't in GCC at
all. I modified the TType base offset code to calculate the offset like GCC
does, though.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81424 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 02:07:37 +00:00
Evan Cheng
08669746d0 Proper support of non-lazy indirect symbols.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81422 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 01:23:53 +00:00
Bill Wendling
43e484fbcf Remove the "#if 0" that Noone loved. It wasn't really necessary, because the
code within it was the same inside and out. There's still a problem of the
TypeInfoSize should be the size of the TType format encoding (at least that's
what GCC thinks it should be).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81417 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 01:12:47 +00:00
Bob Wilson
2a16e6b22c Revert r81171 which was causing pr4927.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81415 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 00:49:22 +00:00
Bill Wendling
d1a5b37a62 Pull check for SJLJ EH into a boolean and use that.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81409 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 00:17:04 +00:00
Bill Wendling
40121bccbe Use the SizeOfEncodedValue function instead of magic variables for the
sizeof(DW_EH_PE_udata4).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81408 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 00:13:16 +00:00
Bill Wendling
bb3e29932d Add helpful comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81406 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 00:04:48 +00:00
Bill Wendling
52783c63a1 Believe it or not, this is a simplification. :-)
Basically, this patch is working towards removing the hard-coded values that are
output for the CIE. In particular, the CIE augmentation and the CIE augmentation
size. Both of these should be calculated. In the process, I was able to make a
bunch of code simpler.

The encodings for the personality, LSDA, and FDE in the CIE are still not
correct. They should be generated either from target-specific callbacks (blech!)
or grokked from first-principles.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81404 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:56:55 +00:00
Evan Cheng
10bf734e6e Fix double load / store multiple encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81403 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:55:03 +00:00
Chris Lattner
2a1744f553 canonicalize namespace gymnastics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81402 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:46:42 +00:00
Bob Wilson
cd3b9a4f17 Fix pr4939: Change FPCCToARMCC to translate SETOLE to ARMCC::LS.
See the bug report for details.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81397 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:14:54 +00:00
Chris Lattner
c5ea263a23 remove DebugLoc from MCInst and eliminate "Comment printing" from
the MCInst path of the asmprinter.  Instead, pull comment printing
out of the autogenerated asmprinter into each target that uses the
autogenerated asmprinter.  This causes code duplication into each
target, but in a way that will be easier to clean up later when more
asmprinter stuff is commonized into the base AsmPrinter class.

This also fixes an xcore strangeness where it inserted two tabs
before every instruction.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81396 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:14:36 +00:00
Daniel Dunbar
ed6878842b Add comment re: clang dependency.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81393 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 23:01:25 +00:00
Sean Callanan
251ef612a8 Added an abstract superclass, MCDisassembler, for
all disassemblers.

Modified the MemoryObject to support 64-bit address
spaces, regardless of the LLVM process's address
width.

Modified the Target class to allow extraction of a
MCDisassembler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81392 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:49:13 +00:00
Bill Wendling
0734d35044 Use the EOL that takes the encoding and translates it into DWARF-English.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81382 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 21:26:19 +00:00
Bill Wendling
7b09a6c622 Early exit from function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81381 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 21:08:12 +00:00
Bill Wendling
b4049fe8cb Small amount of code clean-up: Don't use ".size()" when not necessary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81380 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 21:06:24 +00:00
Chris Lattner
65c060064d add a gross hack to get "SrcLine" comments to show up with the
new asmprinter.  Differently gross hack coming next.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81379 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 20:45:42 +00:00
Chris Lattner
634cca377a hoist the call to processDebugLoc out of the generated
asm printer into the "printInstruction" routine.  This
fixes a problem where the experimental asmprinter would
drop debug labels in some cases, and fixes issues on ppc/xcore
where pseudo instructions like "mr" didn't get debug locs properly.

It is annoying that this moves the call from one place into each
target, but a future set of more invasive refactorings will fix
that problem.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81377 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 20:34:59 +00:00
Lang Hames
9647994e09 Removed static qualifier from a few index related methods. These methods may require a LiveIntervals instance in future.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81374 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 20:14:17 +00:00
Andreas Neustifter
eadcdc564d Reverted r81358.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81364 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:19:35 +00:00
Dan Gohman
c292caf55c Fix SplitCriticalEdge to properly update LCSSA form when splitting a
loop exit edge -- new PHIs may be needed not only for the additional
splits that are made to preserve LoopSimplify form, but also for the
original split. Factor out the code that inserts new PHIs so that it
can be used for both. Remove LoopRotation.cpp's code for manually
updating LCSSA form, as it is now redundant. This fixes PR4934.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81363 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:18:18 +00:00
Benjamin Kramer
17568251af Fix build, add missing simicolon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81362 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:03:46 +00:00
Mike Stump
c02f0d7e4b Reflow comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81361 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:57:16 +00:00
Andreas Neustifter
ff5dfdff56 Preserve ProfileInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81360 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:53:39 +00:00
Andreas Neustifter
07abe17bd2 Add the first functions for updating ProfileInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81359 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:52:57 +00:00
Andreas Neustifter
7fd7061de0 Cleaned up code by factoring out common portions of edge loading into funcion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81358 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:51:39 +00:00
Devang Patel
88cfd964a3 Take lock before removing a node from MDNodeSet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81356 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:44:26 +00:00
Devang Patel
740fce3020 Enable MDNode uniquing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81355 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:30:04 +00:00
Dan Gohman
842dee44b5 Fix an 80-column violation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81354 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:17:19 +00:00
Devang Patel
9c0aa85337 Gracefully destroy MDNodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81353 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 17:07:07 +00:00
Chris Lattner
273a488cdf revert r81335, which breaks the build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81347 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 16:00:57 +00:00
Dan Gohman
607a0508ba When widening a vector load, use the correct chain. This fixes PR4891.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81343 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 14:22:57 +00:00
Andreas Neustifter
43b1b0e4ff Fixed wrong storage option for ProfileVerifierDisableAssertions.
Fixed non working -profile-verifier-noassert option.
Fixed missing newline in debugEntry().
Cleaned up assert messages. (assert(0 && Message) is still shown, but the message is printed before.)
When verifiying loaded profiles the ProfileVerifier got confused when block was a setjmp target, this is checked now.
When verifiying loaded profiles the ProfileVerifier got confused when block eventually reaching an exit(), this is checked now.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81338 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 13:01:03 +00:00
Andreas Neustifter
1f3b00272a Updated ProfileInfo to have clean seperation between different sentinels.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81335 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 12:48:26 +00:00
Benjamin Kramer
d8b0630027 Add a shortcut for OS X to Path::GetMainExecutable. This gives a nice speedup on
clang's testsuite.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81333 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 12:09:08 +00:00
Mikhail Glushenkov
8add26934a Check that the 'kill' call succeeded.
Thanks to Duncan Sands for spotting this.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81328 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 09:51:47 +00:00
Anton Korobeynikov
4c0b349253 Provide proper section flags for various BSS flavours
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81322 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 08:48:53 +00:00