oota-llvm.git
13 years agoImproving the factoring of several instruction encodings.
Owen Anderson [Mon, 29 Nov 2010 20:38:48 +0000 (20:38 +0000)]
Improving the factoring of several instruction encodings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120317 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoTeach ConstantFoldInstruction() how to fold insertvalue and extractvalue.
Frits van Bommel [Mon, 29 Nov 2010 20:36:52 +0000 (20:36 +0000)]
Teach ConstantFoldInstruction() how to fold insertvalue and extractvalue.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120316 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoNow to chant the magical incantation that will exorcise the System library
Charles Davis [Mon, 29 Nov 2010 19:44:50 +0000 (19:44 +0000)]
Now to chant the magical incantation that will exorcise the System library
from LLVM forever:

grep -lR "llvm/System" * | grep -v .svn | xargs sed -ie 's#llvm/System#llvm/Support#g'

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120314 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove empty directories.
Benjamin Kramer [Mon, 29 Nov 2010 19:36:46 +0000 (19:36 +0000)]
Remove empty directories.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120313 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd support for NEON VLD3-dup instructions.
Bob Wilson [Mon, 29 Nov 2010 19:35:29 +0000 (19:35 +0000)]
Add support for NEON VLD3-dup instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120312 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix copy-and-paste errors in VLD2-dup scheduling itineraries.
Bob Wilson [Mon, 29 Nov 2010 19:35:23 +0000 (19:35 +0000)]
Fix copy-and-paste errors in VLD2-dup scheduling itineraries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120311 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoARM Pseudo-ize tBR_JTr.
Jim Grosbach [Mon, 29 Nov 2010 19:32:47 +0000 (19:32 +0000)]
ARM Pseudo-ize tBR_JTr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120310 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThumb2 encodings for MSR and MRS.
Owen Anderson [Mon, 29 Nov 2010 19:29:15 +0000 (19:29 +0000)]
Thumb2 encodings for MSR and MRS.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120309 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUpdate library dependencies changed in the System -> Support merge.
Michael J. Spencer [Mon, 29 Nov 2010 19:28:48 +0000 (19:28 +0000)]
Update library dependencies changed in the System -> Support merge.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120308 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThumb2 encodings for system instructions.
Owen Anderson [Mon, 29 Nov 2010 19:22:08 +0000 (19:22 +0000)]
Thumb2 encodings for system instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120307 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThumb2 encodings for branches and IT blocks.
Owen Anderson [Mon, 29 Nov 2010 18:54:38 +0000 (18:54 +0000)]
Thumb2 encodings for branches and IT blocks.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120306 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThe ARM BR_JT* pseudos don't need to use the printer jtblock_operand node to
Jim Grosbach [Mon, 29 Nov 2010 18:53:24 +0000 (18:53 +0000)]
The ARM BR_JT* pseudos don't need to use the printer jtblock_operand node to
get the pretty-printer. That's handled explicityly by the MC lowering now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120305 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoI swear I did a make clean and make before committing all this...
Michael J. Spencer [Mon, 29 Nov 2010 18:47:54 +0000 (18:47 +0000)]
I swear I did a make clean and make before committing all this...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120304 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSwitch ARM BR_JTm and BR_JTr instructions to be MC-expanded pseudos.
Jim Grosbach [Mon, 29 Nov 2010 18:37:44 +0000 (18:37 +0000)]
Switch ARM BR_JTm and BR_JTr instructions to be MC-expanded pseudos.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120303 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMissed another one.
Michael J. Spencer [Mon, 29 Nov 2010 18:33:08 +0000 (18:33 +0000)]
Missed another one.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120302 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMissed a spot.
Michael J. Spencer [Mon, 29 Nov 2010 18:29:55 +0000 (18:29 +0000)]
Missed a spot.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120301 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMerge System into Support.
Michael J. Spencer [Mon, 29 Nov 2010 18:16:10 +0000 (18:16 +0000)]
Merge System into Support.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120298 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoHandle lshr for i128 correctly on SPU also when
Kalle Raiskila [Mon, 29 Nov 2010 14:44:28 +0000 (14:44 +0000)]
Handle lshr for i128 correctly on SPU also when
shiftamount > 7.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120288 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoEnable PostRA scheduling for SPU.
Kalle Raiskila [Mon, 29 Nov 2010 10:30:25 +0000 (10:30 +0000)]
Enable PostRA scheduling for SPU.
This speeds up selected test cases with up to
5% - no slowdowns observed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120286 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAllow machine LICM to do its job on SPU.
Kalle Raiskila [Mon, 29 Nov 2010 10:08:09 +0000 (10:08 +0000)]
Allow machine LICM to do its job on SPU.
-return a sensible value for register pressure
-add pattern to 'ila' instrucion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120285 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd missing i128 case.
Kalle Raiskila [Mon, 29 Nov 2010 09:36:26 +0000 (09:36 +0000)]
Add missing i128 case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120284 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotools/Makefile: Don't look into $(TARGET_OS), but $(HOST_OS), to inspect availability...
NAKAMURA Takumi [Mon, 29 Nov 2010 08:58:11 +0000 (08:58 +0000)]
tools/Makefile: Don't look into $(TARGET_OS), but $(HOST_OS), to inspect availability of loadable module!

The last commit made run.build.step.test_llvm_1 to fail.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120283 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotest: Check the feature 'loadable_module' with load modules in %llvmshlibdir.
NAKAMURA Takumi [Mon, 29 Nov 2010 07:58:32 +0000 (07:58 +0000)]
test: Check the feature 'loadable_module' with load modules in %llvmshlibdir.

%llvmshlibdir should be 'bin' on Cygming.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120282 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd some dead stores to pacify my least favorite GCC warning: may be
Chandler Carruth [Mon, 29 Nov 2010 01:41:13 +0000 (01:41 +0000)]
Add some dead stores to pacify my least favorite GCC warning: may be
uninitialized. The warning is terrible, has incorrect source locations, and has
a huge false positive rate such as *all* of these.

If anyone has a better solution, please let me know. Alternatively, I'll
happily add -Wno-uninitialized to the -Werror build mode. Maybe I can even do
it *only* when building with GCC instead of Clang.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120281 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd more Thumb encodings.
Bill Wendling [Mon, 29 Nov 2010 01:07:48 +0000 (01:07 +0000)]
Add more Thumb encodings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120279 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMore Thumb encodings.
Bill Wendling [Mon, 29 Nov 2010 01:00:43 +0000 (01:00 +0000)]
More Thumb encodings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120278 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd Thumb encodings for REV instructions.
Bill Wendling [Mon, 29 Nov 2010 00:42:50 +0000 (00:42 +0000)]
Add Thumb encodings for REV instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120277 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotools/Makefile: Fix indentation.
NAKAMURA Takumi [Mon, 29 Nov 2010 00:20:34 +0000 (00:20 +0000)]
tools/Makefile: Fix indentation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120276 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotools/Makefile: Enable building lto, edis and bugpoint-passes on Cygming.
NAKAMURA Takumi [Mon, 29 Nov 2010 00:20:28 +0000 (00:20 +0000)]
tools/Makefile: Enable building lto, edis and bugpoint-passes on Cygming.

bugpoint-passes would be built with ENABLE_SHARED=1.
You could try building gold on Cygming, though, it would fail.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120275 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotest: Use $SharedLibDir for loadable modules. On Cygming, loadable modules are not...
NAKAMURA Takumi [Mon, 29 Nov 2010 00:20:21 +0000 (00:20 +0000)]
test: Use $SharedLibDir for loadable modules. On Cygming, loadable modules are not in lib/ but bin.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120274 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotest: Add the new feature 'loadable_module'.
NAKAMURA Takumi [Mon, 29 Nov 2010 00:20:09 +0000 (00:20 +0000)]
test: Add the new feature 'loadable_module'.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120273 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd more Thumb encodings.
Bill Wendling [Mon, 29 Nov 2010 00:18:15 +0000 (00:18 +0000)]
Add more Thumb encodings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120272 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMake EmitIntValue non virtual.
Rafael Espindola [Sun, 28 Nov 2010 23:22:44 +0000 (23:22 +0000)]
Make EmitIntValue non virtual.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120271 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoForgot the MCPureStreamer::EmitValue in the previous commit.
Rafael Espindola [Sun, 28 Nov 2010 23:13:47 +0000 (23:13 +0000)]
Forgot the MCPureStreamer::EmitValue in the previous commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120270 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove EmitValue to MCObjectStreamer.
Rafael Espindola [Sun, 28 Nov 2010 23:08:47 +0000 (23:08 +0000)]
Move EmitValue to MCObjectStreamer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120269 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDon't use std::copy and std::copy_backward, run 10% faster.
Jakob Stoklund Olesen [Sun, 28 Nov 2010 22:17:14 +0000 (22:17 +0000)]
Don't use std::copy and std::copy_backward, run 10% faster.

Sometimes std::copy can become a memmove call, and that is not a good idea when
copying relatively few bytes as we are doing. We also get a small win by
changing two loops into one.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120265 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDisallow overlapping inserts, even when inserting the same value.
Jakob Stoklund Olesen [Sun, 28 Nov 2010 22:17:11 +0000 (22:17 +0000)]
Disallow overlapping inserts, even when inserting the same value.

We always disallowed overlapping inserts with different values, and this makes
the insertion code smaller and faster.

If an overwriting insert is needed, it can be added as a separate method that
trims any existing intervals before inserting. The immediate use cases for
IntervalMap don't need this - they only use disjoint insertions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120264 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove lowering of TLS_addr32 and TLS_addr64 to X86MCInstLower.
Rafael Espindola [Sun, 28 Nov 2010 21:16:39 +0000 (21:16 +0000)]
Move lowering of TLS_addr32 and TLS_addr64 to X86MCInstLower.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120263 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPR5207: remove unused methods APInt::Emit() and APInt::Read().
Jay Foad [Sun, 28 Nov 2010 21:05:31 +0000 (21:05 +0000)]
PR5207: remove unused methods APInt::Emit() and APInt::Read().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120262 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPR5207: change APInt::doubleToBits() and APInt::floatToBits() to be
Jay Foad [Sun, 28 Nov 2010 21:04:48 +0000 (21:04 +0000)]
PR5207: change APInt::doubleToBits() and APInt::floatToBits() to be
static methods that return a new APInt.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120261 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agofix PR8686, accepting a 'b' suffix at the end of all the setcc
Chris Lattner [Sun, 28 Nov 2010 20:23:50 +0000 (20:23 +0000)]
fix PR8686, accepting a 'b' suffix at the end of all the setcc
instructions.  I choose to handle this with an asmparser hack,
though it could be handled by changing all the instruction definitions
to allow be "setneb" instead of "setne".  The asm parser hack is
better in this case, because we want the disassembler to produce
setne, not setneb.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120260 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoadd a function to the C api to get the context out of a module, patch
Chris Lattner [Sun, 28 Nov 2010 20:03:44 +0000 (20:03 +0000)]
add a function to the C api to get the context out of a module, patch
by Eric Dobson!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120259 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoTweak comments to make it clear that we are working in a namespace.
Jakob Stoklund Olesen [Sun, 28 Nov 2010 18:58:30 +0000 (18:58 +0000)]
Tweak comments to make it clear that we are working in a namespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120256 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoWhen emitting a single function with cppgen=function, you don't want to emit
Nicolas Geoffray [Sun, 28 Nov 2010 18:00:53 +0000 (18:00 +0000)]
When emitting a single function with cppgen=function, you don't want to emit
initializers of global variables used in the function.
Also make sure to emit the operands of a constant.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120253 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFixed verson of r120245.
Rafael Espindola [Sun, 28 Nov 2010 17:18:55 +0000 (17:18 +0000)]
Fixed verson of r120245.
Factor some duplicated code into MCObjectStreamer::EmitLabel.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120248 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRevert previous patch while I debug the darwin bootstrap failure.
Rafael Espindola [Sun, 28 Nov 2010 16:22:59 +0000 (16:22 +0000)]
Revert previous patch while I debug the darwin bootstrap failure.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120246 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFactor some duplicated code into MCObjectStreamer::EmitLabel.
Rafael Espindola [Sun, 28 Nov 2010 15:54:36 +0000 (15:54 +0000)]
Factor some duplicated code into MCObjectStreamer::EmitLabel.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120245 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMake EmitSymbolValue non virtual.
Rafael Espindola [Sun, 28 Nov 2010 15:12:55 +0000 (15:12 +0000)]
Make EmitSymbolValue non virtual.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120244 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAvoid code duplication in the many unsupported EmitGPRel32Value implementations.
Rafael Espindola [Sun, 28 Nov 2010 15:09:24 +0000 (15:09 +0000)]
Avoid code duplication in the many unsupported EmitGPRel32Value implementations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120243 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMake EmitULEB128IntValue and EmitSLEB128IntValue non virtual.
Rafael Espindola [Sun, 28 Nov 2010 14:56:52 +0000 (14:56 +0000)]
Make EmitULEB128IntValue and EmitSLEB128IntValue non virtual.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120242 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove the PTXMCAsmStreamer class to the .cpp file.
Rafael Espindola [Sun, 28 Nov 2010 14:48:34 +0000 (14:48 +0000)]
Move the PTXMCAsmStreamer class to the .cpp file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120241 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDefine generic 1, 2 and 4 byte pc relative relocations. They are common
Rafael Espindola [Sun, 28 Nov 2010 14:17:56 +0000 (14:17 +0000)]
Define generic 1, 2 and 4 byte pc relative relocations. They are common
and at least the 4 byte one will be needed to implement the .cfi_* directives.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120240 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd default constructors for iterators.
Jakob Stoklund Olesen [Sun, 28 Nov 2010 07:21:48 +0000 (07:21 +0000)]
Add default constructors for iterators.

These iterators don't point anywhere, and they can't be compared to anything.
They are only good for assigning to.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120239 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoImplement const_iterator::advanceTo().
Jakob Stoklund Olesen [Sun, 28 Nov 2010 07:00:46 +0000 (07:00 +0000)]
Implement const_iterator::advanceTo().

This is a version of find() that always searches forwards and is faster for
local searches.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120237 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd support for NEON VLD2-dup instructions.
Bob Wilson [Sun, 28 Nov 2010 06:51:26 +0000 (06:51 +0000)]
Add support for NEON VLD2-dup instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120236 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a comment typo.
Bob Wilson [Sun, 28 Nov 2010 06:51:19 +0000 (06:51 +0000)]
Fix a comment typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120235 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAnother minor refactoring for VLD1DUP instructions.
Bob Wilson [Sun, 28 Nov 2010 06:51:15 +0000 (06:51 +0000)]
Another minor refactoring for VLD1DUP instructions.
The op11_8 field is the same for all of them so put it in the instruction
classes instead of specifying it separately for each instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120234 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd entry in getTargetNodeName() for ARMISD::VBICIMM.
Bob Wilson [Sun, 28 Nov 2010 06:51:11 +0000 (06:51 +0000)]
Add entry in getTargetNodeName() for ARMISD::VBICIMM.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120233 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSpeed up simple insertions into an unbranched tree by not creating an iterator.
Jakob Stoklund Olesen [Sun, 28 Nov 2010 06:14:33 +0000 (06:14 +0000)]
Speed up simple insertions into an unbranched tree by not creating an iterator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120232 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agollvmc: First stab at better -march handling.
Mikhail Glushenkov [Sun, 28 Nov 2010 00:31:13 +0000 (00:31 +0000)]
llvmc: First stab at better -march handling.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120230 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove more PEI-related hooks to TFI
Anton Korobeynikov [Sat, 27 Nov 2010 23:05:25 +0000 (23:05 +0000)]
Move more PEI-related hooks to TFI

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120229 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove callee-saved regs spills / reloads to TFI
Anton Korobeynikov [Sat, 27 Nov 2010 23:05:03 +0000 (23:05 +0000)]
Move callee-saved regs spills / reloads to TFI

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120228 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd more tests for erase(). Fix a few exposed bugs.
Jakob Stoklund Olesen [Sat, 27 Nov 2010 22:56:53 +0000 (22:56 +0000)]
Add more tests for erase(). Fix a few exposed bugs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120227 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd test case with randomly ordered insertions, massive coalescing.
Jakob Stoklund Olesen [Sat, 27 Nov 2010 21:12:36 +0000 (21:12 +0000)]
Add test case with randomly ordered insertions, massive coalescing.

Implement iterator::erase() in a simple version that erases nodes when they
become empty, but doesn't try to redistribute elements among siblings for better
packing.

Handle coalescing across leaf nodes which may require erasing entries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120226 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoLower TLS_addr32 and TLS_addr64.
Rafael Espindola [Sat, 27 Nov 2010 20:43:02 +0000 (20:43 +0000)]
Lower TLS_addr32 and TLS_addr64.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120225 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoImplement the data16 prefix.
Rafael Espindola [Sat, 27 Nov 2010 20:29:45 +0000 (20:29 +0000)]
Implement the data16 prefix.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120224 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove PIC16 remnants.
Benjamin Kramer [Sat, 27 Nov 2010 18:20:30 +0000 (18:20 +0000)]
Remove PIC16 remnants.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120223 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for --dump-section-data and tweak a few format strings.
Daniel Dunbar [Sat, 27 Nov 2010 13:58:16 +0000 (13:58 +0000)]
macho-dump: Add support for --dump-section-data and tweak a few format strings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120219 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping symbol table entries.
Daniel Dunbar [Sat, 27 Nov 2010 13:52:53 +0000 (13:52 +0000)]
macho-dump: Add support for dumping symbol table entries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120218 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping string table data.
Daniel Dunbar [Sat, 27 Nov 2010 13:46:11 +0000 (13:46 +0000)]
macho-dump: Add support for dumping string table data.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120217 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping relocation entries.
Daniel Dunbar [Sat, 27 Nov 2010 13:39:48 +0000 (13:39 +0000)]
macho-dump: Add support for dumping relocation entries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120216 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping sections.
Daniel Dunbar [Sat, 27 Nov 2010 13:33:15 +0000 (13:33 +0000)]
macho-dump: Add support for dumping sections.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120215 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping dysymtab indirect symbol table.
Daniel Dunbar [Sat, 27 Nov 2010 13:26:12 +0000 (13:26 +0000)]
macho-dump: Add support for dumping dysymtab indirect symbol table.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120214 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd an optional LowerCase argument to hexdigit().
Daniel Dunbar [Sat, 27 Nov 2010 13:19:46 +0000 (13:19 +0000)]
Add an optional LowerCase argument to hexdigit().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120213 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoCMake: lit(check.vcproj) can run with multiple configurations on Visual Studio.
NAKAMURA Takumi [Sat, 27 Nov 2010 13:10:11 +0000 (13:10 +0000)]
CMake: lit(check.vcproj) can run with multiple configurations on Visual Studio.

Unittests need LLVM_BUILD_MODE to pick up each test.

Confirmed on CentOS5, Mingw, MSYS, and with possible configurations on VS8 and VS10.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120212 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUnbreak build for newer GCCs.
Benjamin Kramer [Sat, 27 Nov 2010 09:08:25 +0000 (09:08 +0000)]
Unbreak build for newer GCCs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120205 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping symtab and dysymtab commands.
Daniel Dunbar [Sat, 27 Nov 2010 08:33:44 +0000 (08:33 +0000)]
macho-dump: Add support for dumping symtab and dysymtab commands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120204 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Add support for dumping segment load commands.
Daniel Dunbar [Sat, 27 Nov 2010 08:22:29 +0000 (08:22 +0000)]
macho-dump: Add support for dumping segment load commands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120203 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSecond attempt at fixing the performance regressions introduced
Owen Anderson [Sat, 27 Nov 2010 08:15:55 +0000 (08:15 +0000)]
Second attempt at fixing the performance regressions introduced
by my recent GVN improvement.  Looking through a single layer of
PHI nodes when attempting to sink GEPs, we need to iteratively
look through arbitrary PHI nests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120202 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoADT/InMemoryStruct: Add an experimental helper class intended for use in
Daniel Dunbar [Sat, 27 Nov 2010 08:11:02 +0000 (08:11 +0000)]
ADT/InMemoryStruct: Add an experimental helper class intended for use in
situations where on the common path an API can return a pointer to some direct
memory, but which on an exceptional path may need to return a pointer to a
temporary struct.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120201 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoraw_ostream::write_escaped: Add a UseHexEscapes argument.
Daniel Dunbar [Sat, 27 Nov 2010 07:59:50 +0000 (07:59 +0000)]
raw_ostream::write_escaped: Add a UseHexEscapes argument.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120200 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a comment.
Daniel Dunbar [Sat, 27 Nov 2010 07:39:37 +0000 (07:39 +0000)]
Fix a comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120199 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoObject/Mach-O: Add header and load command information.
Daniel Dunbar [Sat, 27 Nov 2010 07:19:41 +0000 (07:19 +0000)]
Object/Mach-O: Add header and load command information.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120198 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactor. Set alignment bit in VLD1-dup instruction classes.
Bob Wilson [Sat, 27 Nov 2010 07:12:02 +0000 (07:12 +0000)]
Refactor.  Set alignment bit in VLD1-dup instruction classes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120197 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agobuild/Makefiles: Don't build unittests when ONLY_TOOLS is set.
Daniel Dunbar [Sat, 27 Nov 2010 06:59:16 +0000 (06:59 +0000)]
build/Makefiles: Don't build unittests when ONLY_TOOLS is set.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120196 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoObject/Mach-O: Validate Mach-O magic and initialize format info.
Daniel Dunbar [Sat, 27 Nov 2010 06:39:22 +0000 (06:39 +0000)]
Object/Mach-O: Validate Mach-O magic and initialize format info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120195 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd NEON VLD1-dup instructions (load 1 element to all lanes).
Bob Wilson [Sat, 27 Nov 2010 06:35:16 +0000 (06:35 +0000)]
Add NEON VLD1-dup instructions (load 1 element to all lanes).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120194 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix incorrect scheduling itineraries for NEON vld1/vst1 instructions.
Bob Wilson [Sat, 27 Nov 2010 06:35:09 +0000 (06:35 +0000)]
Fix incorrect scheduling itineraries for NEON vld1/vst1 instructions.
I added these instructions recently but I have no idea where these "1"
values in the NextCycles field came from.  As far as I can tell now,
these instruction stages are clearly intended to overlap.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120193 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: More sketching.
Daniel Dunbar [Sat, 27 Nov 2010 06:19:17 +0000 (06:19 +0000)]
macho-dump: More sketching.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120192 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Stub out C++ macho-dump tool.
Daniel Dunbar [Sat, 27 Nov 2010 05:58:44 +0000 (05:58 +0000)]
macho-dump: Stub out C++ macho-dump tool.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120191 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMC/Mach-O: Start stubbing out a Mach-O object file wrapper.
Daniel Dunbar [Sat, 27 Nov 2010 05:38:50 +0000 (05:38 +0000)]
MC/Mach-O: Start stubbing out a Mach-O object file wrapper.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120190 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoReduce nesting.
Daniel Dunbar [Sat, 27 Nov 2010 05:18:48 +0000 (05:18 +0000)]
Reduce nesting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120189 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMC/Mach-O: Migrate more constants into MachOFormat.h.
Daniel Dunbar [Sat, 27 Nov 2010 04:59:14 +0000 (04:59 +0000)]
MC/Mach-O: Migrate more constants into MachOFormat.h.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120188 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMC/Mach-O: Switch to using MachOFormat.h.
Daniel Dunbar [Sat, 27 Nov 2010 04:38:36 +0000 (04:38 +0000)]
MC/Mach-O: Switch to using MachOFormat.h.
 - I'm leaving MachO.h, because I believe it has external consumers, but I would really like to eliminate it (we have stylistic disagreements with one another).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120187 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMC/Mach-O: Introduce Object/MachOFormat for describing purely platform / machine
Daniel Dunbar [Sat, 27 Nov 2010 04:19:38 +0000 (04:19 +0000)]
MC/Mach-O: Introduce Object/MachOFormat for describing purely platform / machine
independent information on the Mach object format, and move some stuff from
MachObjectWriter.cpp there.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120186 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomacho-dump: Fix typo.
Daniel Dunbar [Sat, 27 Nov 2010 04:00:06 +0000 (04:00 +0000)]
macho-dump: Fix typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120185 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoBitVector tweaks.
Benjamin Kramer [Fri, 26 Nov 2010 18:25:20 +0000 (18:25 +0000)]
BitVector tweaks.

- Double the vector's capacity when growing to avoid unneeccesary reallocation.
- Do the reallocation with realloc(3) which can expand the memory in place.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120183 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoStringRefs are POD-like.
Benjamin Kramer [Fri, 26 Nov 2010 14:36:54 +0000 (14:36 +0000)]
StringRefs are POD-like.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120181 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agounittests/JITTests: Don't use --export-dynamic but --export-all-symbols on cygming.
NAKAMURA Takumi [Fri, 26 Nov 2010 09:32:02 +0000 (09:32 +0000)]
unittests/JITTests: Don't use --export-dynamic but --export-all-symbols on cygming.

GNU ld/PECOFF accepts but ignores them below;
  --version-script
  --export-dynamic
  --rpath

FIXME: autoconf should be aware of them.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120179 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotest/site.exp.in: Add "emitir", for now, fixing up r120156. CMake depends on site...
NAKAMURA Takumi [Fri, 26 Nov 2010 08:30:15 +0000 (08:30 +0000)]
test/site.exp.in: Add "emitir", for now, fixing up r120156. CMake depends on site.exp.in, though, "emitir" might be unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120174 91177308-0d34-0410-b5e6-96231b3b80d8