oota-llvm.git
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

13 years agoAdd B+-tree test case that creates a height 3 tree with a smaller root node.
Jakob Stoklund Olesen [Fri, 26 Nov 2010 06:54:20 +0000 (06:54 +0000)]
Add B+-tree test case that creates a height 3 tree with a smaller root node.

Change temporary debugging code to write a dot file directly.

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

13 years agoExtract template function adjustSiblingSizes(), allowing instances to be shared
Jakob Stoklund Olesen [Fri, 26 Nov 2010 06:54:17 +0000 (06:54 +0000)]
Extract template function adjustSiblingSizes(), allowing instances to be shared
between B+-trees using the same KeyT.

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

13 years agoRemove the unused TheTarget member.
Rafael Espindola [Fri, 26 Nov 2010 04:24:21 +0000 (04:24 +0000)]
Remove the unused TheTarget member.

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

13 years agoFix spelling!
Michael J. Spencer [Fri, 26 Nov 2010 04:16:20 +0000 (04:16 +0000)]
Fix spelling!

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

13 years agoFix Whitespace.
Michael J. Spencer [Fri, 26 Nov 2010 04:16:08 +0000 (04:16 +0000)]
Fix Whitespace.

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

13 years agoMove tree navigation to a new Path class that doesn't have to be a template.
Jakob Stoklund Olesen [Fri, 26 Nov 2010 01:39:40 +0000 (01:39 +0000)]
Move tree navigation to a new Path class that doesn't have to be a template.

The path also holds a reference to the root node, and that allows important
iterator accessors like start() and stop() to have no conditional code. (When
the compiler is clever enough to remove it.)

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

13 years agoRemove explicit uses of -emit-llvm, the test infrastructure adds it
Duncan Sands [Thu, 25 Nov 2010 21:48:20 +0000 (21:48 +0000)]
Remove explicit uses of -emit-llvm, the test infrastructure adds it
automatically.  Use -S with llvm-gcc rather than -c, so tests can
work when llvm-gcc is really dragonegg (which can output IR with -S
but not -c).  Yes, dragonegg supports objective-c++ (poorly though).

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

13 years agoRemove explicit uses of -emit-llvm, the test infrastructure adds it
Duncan Sands [Thu, 25 Nov 2010 21:46:07 +0000 (21:46 +0000)]
Remove explicit uses of -emit-llvm, the test infrastructure adds it
automatically.  Use -S with llvm-gcc rather than -c, so tests can
work when llvm-gcc is really dragonegg (which can output IR with -S
but not -c).  Yes, dragonegg supports objective-c (poorly though).

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

13 years agoBump required cmake version on CMake.html.
Oscar Fuentes [Thu, 25 Nov 2010 21:41:48 +0000 (21:41 +0000)]
Bump required cmake version on CMake.html.

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

13 years agoUse -S rather than -c for the benefit of dragonegg.
Duncan Sands [Thu, 25 Nov 2010 21:41:35 +0000 (21:41 +0000)]
Use -S rather than -c for the benefit of dragonegg.

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

13 years agoRemove explicit uses of -emit-llvm, the test infrastructure adds it
Duncan Sands [Thu, 25 Nov 2010 21:39:17 +0000 (21:39 +0000)]
Remove explicit uses of -emit-llvm, the test infrastructure adds it
automatically.  Use -S with llvm-gcc rather than -c, so tests can
work when llvm-gcc is really dragonegg (which can output IR with -S
but not -c).

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

13 years agoJudging from the comment, the system assembler is supposed to assemble
Duncan Sands [Thu, 25 Nov 2010 21:26:21 +0000 (21:26 +0000)]
Judging from the comment, the system assembler is supposed to assemble
the output of this test.  Since it was producing bitcode, that clearly
wasn't happening!  Have it produce target assembler and assemble that
instead.

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

13 years agoRemove explicit uses of -emit-llvm, the test infrastructure adds it
Duncan Sands [Thu, 25 Nov 2010 21:24:35 +0000 (21:24 +0000)]
Remove explicit uses of -emit-llvm, the test infrastructure adds it
automatically.  Use -S with llvm-gcc rather than -c, so tests can
work when llvm-gcc is really dragonegg (which can output IR with -S
but not -c).

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

13 years agoDragonegg cannot output bitcode, only human readable IR, so use -S rather
Duncan Sands [Thu, 25 Nov 2010 21:21:59 +0000 (21:21 +0000)]
Dragonegg cannot output bitcode, only human readable IR, so use -S rather
than -c.

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

13 years agoUse LLVMCC_EMITIR_FLAG rather than hard-coding "-emit-llvm".
Duncan Sands [Thu, 25 Nov 2010 21:19:52 +0000 (21:19 +0000)]
Use LLVMCC_EMITIR_FLAG rather than hard-coding "-emit-llvm".

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

13 years agoUsing LLVMCC_EMITIR_FLAG rather than hard-coding -emit-llvm
Duncan Sands [Thu, 25 Nov 2010 21:14:55 +0000 (21:14 +0000)]
Using LLVMCC_EMITIR_FLAG rather than hard-coding -emit-llvm
(dragonegg cannot use -emit-llvm so needs a different flag
to everyone else).

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

13 years agoIt seems inconsistent to have LLVMCC_EMITIR_FLAG and
Duncan Sands [Thu, 25 Nov 2010 17:57:43 +0000 (17:57 +0000)]
It seems inconsistent to have LLVMCC_EMITIR_FLAG and
LLVMGCC_DISABLEOPT_FLAGS, one with CC in it, the other
with GCC.  Rename LLVMGCC_DISABLEOPT_FLAGS to
LLVMCC_DISABLEOPT_FLAGS.

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

13 years agoSDep is POD-like. Shave off a few bytes from SUnit by moving a member around.
Benjamin Kramer [Thu, 25 Nov 2010 17:50:19 +0000 (17:50 +0000)]
SDep is POD-like. Shave off a few bytes from SUnit by moving a member around.

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

13 years agoInitial support for being able to specify the llvm-gcc to use like this:
Duncan Sands [Thu, 25 Nov 2010 17:47:42 +0000 (17:47 +0000)]
Initial support for being able to specify the llvm-gcc to use like this:
  --with-llvmgcc="gcc-4.5 -fplugin=dragonegg.so"

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

13 years agoUse multiple 0x66 prefixes so that all nops up to 15 bytes are a single instruction.
Rafael Espindola [Thu, 25 Nov 2010 17:14:16 +0000 (17:14 +0000)]
Use multiple 0x66 prefixes so that all nops up to 15 bytes are a single instruction.

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

13 years agoNamespacify.
Benjamin Kramer [Thu, 25 Nov 2010 16:42:51 +0000 (16:42 +0000)]
Namespacify.

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

13 years agoFactor some code to parseSectionFlags and fix the default type of a section.
Rafael Espindola [Thu, 25 Nov 2010 15:32:56 +0000 (15:32 +0000)]
Factor some code to parseSectionFlags and fix the default type of a section.

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

13 years agosystem_error: Even more unsupported error numbers :(.
Michael J. Spencer [Thu, 25 Nov 2010 01:53:59 +0000 (01:53 +0000)]
system_error: Even more unsupported error numbers :(.

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

13 years agoTreat a call of function pointer like a load of the pointer when considering
Nick Lewycky [Wed, 24 Nov 2010 22:04:20 +0000 (22:04 +0000)]
Treat a call of function pointer like a load of the pointer when considering
whether the pointer can be replaced with the global variable it is a copy of.
Fixes PR8680.

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

13 years agoBehave a bit more like gnu as and use the symbol (instead of the section)
Rafael Espindola [Wed, 24 Nov 2010 21:57:39 +0000 (21:57 +0000)]
Behave a bit more like gnu as and use the symbol (instead of the section)
for any relocation to a symbol defined in a tls section.

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

13 years ago80 col.
Michael J. Spencer [Wed, 24 Nov 2010 20:07:14 +0000 (20:07 +0000)]
80 col.

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

13 years agogoogle test depends on Support.
Michael J. Spencer [Wed, 24 Nov 2010 19:35:15 +0000 (19:35 +0000)]
google test depends on Support.

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

13 years agoRelocate with the symbol if the relocation is of kind NTPOFF.
Rafael Espindola [Wed, 24 Nov 2010 19:23:50 +0000 (19:23 +0000)]
Relocate with the symbol if the relocation is of kind NTPOFF.
Patch by David Meyer, I added the test.

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

13 years agounittests: Add initial Path-V2 test.
Michael J. Spencer [Wed, 24 Nov 2010 19:20:28 +0000 (19:20 +0000)]
unittests: Add initial Path-V2 test.

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

13 years agoPath Version 2.
Michael J. Spencer [Wed, 24 Nov 2010 19:20:19 +0000 (19:20 +0000)]
Path Version 2.

Based on TR2/boost filesystem (v3) API, but modified to remove exceptions.

Do not include this file directly, when it is ready, it will be included by
include/llvm/System/Path.h.

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

13 years agounittests: Add SystemTests.
Michael J. Spencer [Wed, 24 Nov 2010 19:20:05 +0000 (19:20 +0000)]
unittests: Add SystemTests.

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

13 years agoFix and add tests for all cases in x86 and x86_64 where gnu as implicitly
Rafael Espindola [Wed, 24 Nov 2010 18:51:21 +0000 (18:51 +0000)]
Fix and add tests for all cases in x86 and x86_64 where gnu as implicitly
sets the type of a symbol to STT_TLS.

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

13 years agoTestcase for r120017.
Rafael Espindola [Wed, 24 Nov 2010 18:03:57 +0000 (18:03 +0000)]
Testcase for r120017.

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

13 years agoUpdating MBlaze .mask and .frame directives to match GCC's output and fixing regressi...
Wesley Peck [Wed, 24 Nov 2010 16:32:35 +0000 (16:32 +0000)]
Updating MBlaze .mask and .frame directives to match GCC's output and fixing regression introduced in 120095 by checking MCStreamer::hasRawTextSupport.

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

13 years ago1. Fixing error where basic block labels were not being printed out when they need...
Wesley Peck [Wed, 24 Nov 2010 15:39:32 +0000 (15:39 +0000)]
1. Fixing error where basic block labels were not being printed out when they need to be for the MBlaze backend because AsmPrinter::isBlockOnlyReachableByFallthrough does not take into account delay slots.
2. Re-adding .mask and .frame directives in printed assembly.
3. Adding .ent and .end directives in printed assembly.
4. Minor cleanups to MBlaze backend.

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

13 years agoUse i8 as SETCC result type for i1 in SPU.
Kalle Raiskila [Wed, 24 Nov 2010 12:59:16 +0000 (12:59 +0000)]
Use i8 as SETCC result type for i1 in SPU.

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

13 years agoAllow for 'fcmp ogt' in SPU.
Kalle Raiskila [Wed, 24 Nov 2010 11:42:17 +0000 (11:42 +0000)]
Allow for 'fcmp ogt' in SPU.

Fix by Visa Putkinen!

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

13 years agoIf a symbol is used as tls, mark it as tls even if not declare as so. Probably
Rafael Espindola [Wed, 24 Nov 2010 02:19:40 +0000 (02:19 +0000)]
If a symbol is used as tls, mark it as tls even if not declare as so. Probably
fixes PR8659.

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

13 years agoinclude/llvm/System/system_error.h: ECANCELED is undefined on Cygwin-1.5.
NAKAMURA Takumi [Wed, 24 Nov 2010 01:29:45 +0000 (01:29 +0000)]
include/llvm/System/system_error.h: ECANCELED is undefined on Cygwin-1.5.

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

13 years agoTweak ImmutableMap/ImmutableSet/ImmutableList APIs
Ted Kremenek [Wed, 24 Nov 2010 00:54:28 +0000 (00:54 +0000)]
Tweak ImmutableMap/ImmutableSet/ImmutableList APIs
to use lowercase letters for the start of most
method names and to replace some method names
with more descriptive names (e.g., "getLeft()"
instead of "Left()").  No real functionality
change.

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

13 years agoGeneralize overflowLeaf to also handle overflows in branch nodes.
Jakob Stoklund Olesen [Wed, 24 Nov 2010 00:03:32 +0000 (00:03 +0000)]
Generalize overflowLeaf to also handle overflows in branch nodes.

This doesn't quite work yet because the calls to treeDecrement and treeIncrement
operate at the leaf level, not on pathNode(Level) as required.

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

13 years agoadd a MemoryBuffer::getOpenFile method, which turns an open
Chris Lattner [Tue, 23 Nov 2010 22:20:27 +0000 (22:20 +0000)]
add a MemoryBuffer::getOpenFile method, which turns an open
file descriptor into a MemoryBuffer (and closes the FD).

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

13 years agosystem_error: Add fixme.
Michael J. Spencer [Tue, 23 Nov 2010 21:09:11 +0000 (21:09 +0000)]
system_error: Add fixme.

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

13 years agoRename SimplifyDistributed to the more meaningfull name SimplifyByFactorizing.
Duncan Sands [Tue, 23 Nov 2010 20:42:39 +0000 (20:42 +0000)]
Rename SimplifyDistributed to the more meaningfull name SimplifyByFactorizing.

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

13 years agoThe srem -> urem transform is not safe for any divisor that's not a power of two.
Benjamin Kramer [Tue, 23 Nov 2010 20:33:57 +0000 (20:33 +0000)]
The srem -> urem transform is not safe for any divisor that's not a power of two.
E.g. -5 % 5 is 0 with srem and 1 with urem.

Also addresses Frits van Bommel's comments.

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

13 years agoReplace calls to ConstantFoldInstruction with calls to SimplifyInstruction
Duncan Sands [Tue, 23 Nov 2010 20:26:33 +0000 (20:26 +0000)]
Replace calls to ConstantFoldInstruction with calls to SimplifyInstruction
in two places that are really interested in simplified instructions, not
constants.

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

13 years agoConstant folding here is pointless, because InstructionSimplify
Duncan Sands [Tue, 23 Nov 2010 20:24:21 +0000 (20:24 +0000)]
Constant folding here is pointless, because InstructionSimplify
(which does constant folding and more) is called a few lines
later.

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

13 years agoMove the ARM reloc constants to Support/ELF.h
Jason W Kim [Tue, 23 Nov 2010 19:40:36 +0000 (19:40 +0000)]
Move the ARM reloc constants to Support/ELF.h

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

13 years agoRecognize sign/zero-extended constant BUILD_VECTORs for VMULL operations.
Bob Wilson [Tue, 23 Nov 2010 19:38:38 +0000 (19:38 +0000)]
Recognize sign/zero-extended constant BUILD_VECTORs for VMULL operations.
We need to check if the individual vector elements are sign/zero-extended
values.  For now this only handles constants values.  Radar 8687140.

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