oota-llvm.git
13 years agoGet rid of static constructors for pass registration. Instead, every pass exposes...
Owen Anderson [Tue, 19 Oct 2010 17:21:58 +0000 (17:21 +0000)]
Get rid of static constructors for pass registration.  Instead, every pass exposes an initializeMyPassFunction(), which
must be called in the pass's constructor.  This function uses static dependency declarations to recursively initialize
the pass's dependencies.

Clients that only create passes through the createFooPass() APIs will require no changes.  Clients that want to use the
CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h
before parsing commandline arguments.

I have tested this with all standard configurations of clang and llvm-gcc on Darwin.  It is possible that there are problems
with the static dependencies that will only be visible with non-standard options.  If you encounter any crash in pass
registration/creation, please send the testcase to me directly.

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

13 years agoRevert r116781 "- Add a hook for target to determine whether an instruction def
Daniel Dunbar [Tue, 19 Oct 2010 17:14:24 +0000 (17:14 +0000)]
Revert r116781 "- Add a hook for target to determine whether an instruction def
is", which breaks some nightly tests.

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

13 years agoConsistently use AliasAnalysis::UnknownSize instead of hardcoding ~0u.
Dan Gohman [Tue, 19 Oct 2010 17:06:23 +0000 (17:06 +0000)]
Consistently use AliasAnalysis::UnknownSize instead of hardcoding ~0u.

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

13 years agoGlobalOpt: EvaluateFunction() must not evaluate stores to weak_odr globals.
Mikhail Glushenkov [Tue, 19 Oct 2010 16:47:23 +0000 (16:47 +0000)]
GlobalOpt: EvaluateFunction() must not evaluate stores to weak_odr globals.

Fixes PR8389.

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

13 years agoTrailing whitespace.
Mikhail Glushenkov [Tue, 19 Oct 2010 16:47:15 +0000 (16:47 +0000)]
Trailing whitespace.

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

13 years agoAdd svn:ignore
Che-Liang Chiou [Tue, 19 Oct 2010 13:46:32 +0000 (13:46 +0000)]
Add svn:ignore

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

13 years agoAdd svn:ignore to lib/Target/PTX/
Che-Liang Chiou [Tue, 19 Oct 2010 13:28:18 +0000 (13:28 +0000)]
Add svn:ignore to lib/Target/PTX/

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

13 years agoAdd test case mov.ll for PTX device function
Che-Liang Chiou [Tue, 19 Oct 2010 13:21:51 +0000 (13:21 +0000)]
Add test case mov.ll for PTX device function

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

13 years agoAdd lower argument and return of device function
Che-Liang Chiou [Tue, 19 Oct 2010 13:14:40 +0000 (13:14 +0000)]
Add lower argument and return of device function

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

13 years agoFix spelling.
Bill Wendling [Tue, 19 Oct 2010 10:18:23 +0000 (10:18 +0000)]
Fix spelling.

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

13 years agoFirst step to allowing the resource directory of Clang to be adjusted for
Chandler Carruth [Tue, 19 Oct 2010 08:21:25 +0000 (08:21 +0000)]
First step to allowing the resource directory of Clang to be adjusted for
strange packaging environments. The primary result of this is to expose
a (normally empty) CLANG_RESOURCE_DIR string in the autoconf and CMake builds.
This will in turn be used by a subsequent commit to Clang.

Regenerated configure and config.h.in thanks to Nick. =D

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

13 years agoX86: Add MS-CRT libcalls.
Michael J. Spencer [Tue, 19 Oct 2010 07:32:52 +0000 (07:32 +0000)]
X86: Add MS-CRT libcalls.

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

13 years agoFix Whitespace.
Michael J. Spencer [Tue, 19 Oct 2010 07:32:42 +0000 (07:32 +0000)]
Fix Whitespace.

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

13 years agolib/CodeGen/TargetLoweringObjectFileImpl.cpp: Tweak to emit ".{section}${name}" inste...
NAKAMURA Takumi [Tue, 19 Oct 2010 03:24:42 +0000 (03:24 +0000)]
lib/CodeGen/TargetLoweringObjectFileImpl.cpp: Tweak to emit ".{section}${name}" instead of ".{section}$linkonce_{name}" for linkonce sections.

It seems GNU ld/PECOFF relies on section names, linking with g++'s libstdc++.a would fail.

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

13 years agoFix for machine licm assert: RCCost <= RegPressure[RCId]
Andrew Trick [Tue, 19 Oct 2010 02:50:50 +0000 (02:50 +0000)]
Fix for machine licm assert: RCCost <= RegPressure[RCId]
in MultiSource/Benchmarks/VersaBench/beamformer/beamformer.
SmallSet.insert returns true if the element is inserted.

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

13 years agoFix PR8300 by remembering to keep the bitcast in all cases.
Rafael Espindola [Tue, 19 Oct 2010 02:02:57 +0000 (02:02 +0000)]
Fix PR8300 by remembering to keep the bitcast in all cases.

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

13 years agolib/System/Win32/ThreadLocal.inc: Suppress "unused" warning on -Asserts.
NAKAMURA Takumi [Tue, 19 Oct 2010 01:22:01 +0000 (01:22 +0000)]
lib/System/Win32/ThreadLocal.inc: Suppress "unused" warning on -Asserts.

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

13 years agolib/Support/raw_ostream.cpp: Fix Cygwin's build.
NAKAMURA Takumi [Tue, 19 Oct 2010 01:21:55 +0000 (01:21 +0000)]
lib/Support/raw_ostream.cpp: Fix Cygwin's build.

setmode is provided by io.h on Cygwin.

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

13 years ago- Add a hook for target to determine whether an instruction def is
Evan Cheng [Tue, 19 Oct 2010 00:55:07 +0000 (00:55 +0000)]
- Add a hook for target to determine whether an instruction def is
  "long latency" enough to hoist even if it may increase spilling. Reloading
  a value from spill slot is often cheaper than performing an expensive
  computation in the loop. For X86, that means machine LICM will hoist
  SQRT, DIV, etc. ARM will be somewhat aggressive with VFP and NEON
  instructions.
- Enable register pressure aware machine LICM by default.

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

13 years agoMove the definition of this to the source file to anchor the vtable.
Chandler Carruth [Tue, 19 Oct 2010 00:37:30 +0000 (00:37 +0000)]
Move the definition of this to the source file to anchor the vtable.

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

13 years agoSpeculatively revert 116753 and 116756 to attempt to fix the bots.
Eric Christopher [Tue, 19 Oct 2010 00:19:49 +0000 (00:19 +0000)]
Speculatively revert 116753 and 116756 to attempt to fix the bots.

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

13 years agoSupport alignment for NEON vld-lane and vst-lane instructions.
Bob Wilson [Tue, 19 Oct 2010 00:16:32 +0000 (00:16 +0000)]
Support alignment for NEON vld-lane and vst-lane instructions.

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

13 years agoAdded a few tweaks to the Intel Descriptor-table support instructions to allow
Kevin Enderby [Tue, 19 Oct 2010 00:01:44 +0000 (00:01 +0000)]
Added a few tweaks to the Intel Descriptor-table support instructions to allow
word forms and suffixed versions to match the darwin assembler in 32-bit and
64-bit modes.  This is again for use just with assembly source for llvm-mc .

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

13 years agoARM encoding information for [SU]SAT* instructions.
Jim Grosbach [Mon, 18 Oct 2010 23:35:38 +0000 (23:35 +0000)]
ARM encoding information for [SU]SAT* instructions.

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

13 years agoMake the representation of AliasSets explicitly differentiate
Dan Gohman [Mon, 18 Oct 2010 23:31:47 +0000 (23:31 +0000)]
Make the representation of AliasSets explicitly differentiate
between "not known yet" and "known no tbaa info" so that it
can merge them properly.

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

13 years agoAdd a virtual destructor to silence a GCC warning.
Chandler Carruth [Mon, 18 Oct 2010 23:18:51 +0000 (23:18 +0000)]
Add a virtual destructor to silence a GCC warning.

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

13 years agoRevert r116220 - thus turning arm fast isel back on by default.
Eric Christopher [Mon, 18 Oct 2010 22:53:53 +0000 (22:53 +0000)]
Revert r116220 - thus turning arm fast isel back on by default.

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

13 years agoGet rid of unneeded FormatOutput global variable
Jason W Kim [Mon, 18 Oct 2010 21:59:38 +0000 (21:59 +0000)]
Get rid of unneeded FormatOutput global variable

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

13 years agoCrashRecoveryContext: Add missing return, so that the signal fires after we our
Daniel Dunbar [Mon, 18 Oct 2010 21:55:18 +0000 (21:55 +0000)]
CrashRecoveryContext: Add missing return, so that the signal fires after we our
routine is off the stack. Otherwise we show up rather confusingly in the stack
trace.

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

13 years agoChanged elf-dump to output hex format by default.
Jason W Kim [Mon, 18 Oct 2010 21:32:41 +0000 (21:32 +0000)]
Changed elf-dump to output hex format by default.
Also updated tests.

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

13 years agoDon't pass the raw invalid pointer used to represent conflicting
Dan Gohman [Mon, 18 Oct 2010 21:28:00 +0000 (21:28 +0000)]
Don't pass the raw invalid pointer used to represent conflicting
TBAA information to AliasAnalysis.

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

13 years agoDon't recompute MachineRegisterInfo in the Optimize* method.
Bill Wendling [Mon, 18 Oct 2010 21:22:31 +0000 (21:22 +0000)]
Don't recompute MachineRegisterInfo in the Optimize* method.

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

13 years agoTrailing whitespace.
Mikhail Glushenkov [Mon, 18 Oct 2010 21:16:00 +0000 (21:16 +0000)]
Trailing whitespace.

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

13 years agoAdd a basic testcase for TBAA-aware LICM.
Dan Gohman [Mon, 18 Oct 2010 21:00:09 +0000 (21:00 +0000)]
Add a basic testcase for TBAA-aware LICM.

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

13 years agoImplement R_386_GOT32.
Rafael Espindola [Mon, 18 Oct 2010 20:47:21 +0000 (20:47 +0000)]
Implement R_386_GOT32.

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

13 years agoMake AliasSetTracker TBAA-aware, enabling TBAA-enabled LICM.
Dan Gohman [Mon, 18 Oct 2010 20:44:50 +0000 (20:44 +0000)]
Make AliasSetTracker TBAA-aware, enabling TBAA-enabled LICM.

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

13 years agoRelocate with .bss instead of using the symbol. Matches gas behavior.
Rafael Espindola [Mon, 18 Oct 2010 20:25:33 +0000 (20:25 +0000)]
Relocate with .bss instead of using the symbol. Matches gas behavior.

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

13 years agoReenable assert.
Rafael Espindola [Mon, 18 Oct 2010 19:33:01 +0000 (19:33 +0000)]
Reenable assert.

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

13 years agoTransfer debug loc to lowered call.
Devang Patel [Mon, 18 Oct 2010 18:53:44 +0000 (18:53 +0000)]
Transfer debug loc to lowered call.
Patch by Alexander Herz!

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

13 years agoAdd TypeBasedAliasAnalysis to the standard pass lists. Note that it
Dan Gohman [Mon, 18 Oct 2010 18:50:27 +0000 (18:50 +0000)]
Add TypeBasedAliasAnalysis to the standard pass lists. Note that it
is currently inert by default.

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

13 years agoRun tbaa before basicaa, since that's how it's expected to be used.
Dan Gohman [Mon, 18 Oct 2010 18:45:59 +0000 (18:45 +0000)]
Run tbaa before basicaa, since that's how it's expected to be used.

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

13 years agoFix BasicAA to pass TBAAInfo through to the chained analysis.
Dan Gohman [Mon, 18 Oct 2010 18:45:11 +0000 (18:45 +0000)]
Fix BasicAA to pass TBAAInfo through to the chained analysis.

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

13 years agoFor Thumb2, try to use frame pointer references for stack slots even when a
Jim Grosbach [Mon, 18 Oct 2010 18:39:46 +0000 (18:39 +0000)]
For Thumb2, try to use frame pointer references for stack slots even when a
base register is available. rdar://8525298

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

13 years agoProduce ELF::R_386_GOTPC relocations.
Rafael Espindola [Mon, 18 Oct 2010 18:36:12 +0000 (18:36 +0000)]
Produce ELF::R_386_GOTPC relocations.

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

13 years agoMake TypeBasedAliasAnalysis default to doing nothing, with a command-line
Dan Gohman [Mon, 18 Oct 2010 18:17:47 +0000 (18:17 +0000)]
Make TypeBasedAliasAnalysis default to doing nothing, with a command-line
option to enable it.

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

13 years agoUse chaining in TypeBasedAliasAnalysis::pointsToConstantMemory.
Dan Gohman [Mon, 18 Oct 2010 18:10:31 +0000 (18:10 +0000)]
Use chaining in TypeBasedAliasAnalysis::pointsToConstantMemory.

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

13 years agoMake BasicAliasAnalysis a normal AliasAnalysis implementation which
Dan Gohman [Mon, 18 Oct 2010 18:04:47 +0000 (18:04 +0000)]
Make BasicAliasAnalysis a normal AliasAnalysis implementation which
does normal initialization and normal chaining. Change the default
AliasAnalysis implementation to NoAlias.

Update StandardCompileOpts.h and friends to explicitly request
BasicAliasAnalysis.

Update tests to explicitly request -basicaa.

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

13 years agoMake the bots happy.
Rafael Espindola [Mon, 18 Oct 2010 18:03:28 +0000 (18:03 +0000)]
Make the bots happy.

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

13 years agoAdded a handful of x86-32 instructions that were missing so that llvm-mc would
Kevin Enderby [Mon, 18 Oct 2010 17:04:36 +0000 (17:04 +0000)]
Added a handful of x86-32 instructions that were missing so that llvm-mc would
be more complete.  These are only expected to be used by llvm-mc with assembly
source so there is no pattern, [], in the .td files.  Most are being added to
X86InstrInfo.td as Chris suggested and only comments about register uses are
added.  Suggestions welcome on the .td changes as I'm not sure on every detail
of the x86 records.  More missing instructions will be coming.

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

13 years agoProduce a R_386_PLT32 when needed. Moved the default cases of switches to the
Rafael Espindola [Mon, 18 Oct 2010 16:58:03 +0000 (16:58 +0000)]
Produce a R_386_PLT32 when needed. Moved the default cases of switches to the
start for consistency.

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

13 years agoARM addrmode4 instructions (ldm, stm and friends) can't encode an immediate
Jim Grosbach [Mon, 18 Oct 2010 16:48:59 +0000 (16:48 +0000)]
ARM addrmode4 instructions (ldm, stm and friends) can't encode an immediate
offset for stack references. Make sure we take that into account when
deciding whether to reserver an emergency spill slot for the register
scavenger. rdar://8559625

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

13 years agoGrammar tweak.
Jim Grosbach [Mon, 18 Oct 2010 16:38:50 +0000 (16:38 +0000)]
Grammar tweak.

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

13 years agoHandle GOTOFF correctly on i386.
Rafael Espindola [Mon, 18 Oct 2010 16:38:04 +0000 (16:38 +0000)]
Handle GOTOFF correctly on i386.

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

13 years agoTrivial grammar tweak.
Jim Grosbach [Mon, 18 Oct 2010 16:29:26 +0000 (16:29 +0000)]
Trivial grammar tweak.

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

13 years agoImprove lowering of sext to i128 on SPU.
Kalle Raiskila [Mon, 18 Oct 2010 09:34:19 +0000 (09:34 +0000)]
Improve lowering of sext to i128 on SPU.
The old algorithm inserted a 'rotqmbyi' instruction which was
both redundant and wrong - it made shufb select bytes from the
wrong end of the input quad.

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

13 years agoRemove the check for invalid calling conventions. Testing shows that they're
Eric Christopher [Mon, 18 Oct 2010 06:49:12 +0000 (06:49 +0000)]
Remove the check for invalid calling conventions. Testing shows that they're
working just fine.

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

13 years agoLift arg promotion from the X86 backend. This should be unified at some point.
Eric Christopher [Mon, 18 Oct 2010 02:17:53 +0000 (02:17 +0000)]
Lift arg promotion from the X86 backend. This should be unified at some point.

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

13 years agoNow that we handle all allocas via a non-SP reg offset remove all of the
Eric Christopher [Sun, 17 Oct 2010 11:08:44 +0000 (11:08 +0000)]
Now that we handle all allocas via a non-SP reg offset remove all of the
special case handling for ARM::SP.

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

13 years agostd::string cleanup.
Benjamin Kramer [Sun, 17 Oct 2010 07:39:34 +0000 (07:39 +0000)]
std::string cleanup.

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

13 years agoFix a typo and silence unused variable warnings in -Asserts build.
Benjamin Kramer [Sun, 17 Oct 2010 07:38:40 +0000 (07:38 +0000)]
Fix a typo and silence unused variable warnings in -Asserts build.

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

13 years agoAllow more load types to be materialized through the allocas.
Eric Christopher [Sun, 17 Oct 2010 06:07:26 +0000 (06:07 +0000)]
Allow more load types to be materialized through the allocas.

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

13 years agoBuild with RTTI and exceptions disabled. Only in GCC for now.
Oscar Fuentes [Sun, 17 Oct 2010 02:26:16 +0000 (02:26 +0000)]
Build with RTTI and exceptions disabled. Only in GCC for now.

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

13 years agoOptimize GEP off of intermediate allocas.
Eric Christopher [Sun, 17 Oct 2010 01:51:42 +0000 (01:51 +0000)]
Optimize GEP off of intermediate allocas.

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

13 years agoFix comment.
Eric Christopher [Sun, 17 Oct 2010 01:42:53 +0000 (01:42 +0000)]
Fix comment.

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

13 years agoTurn on AddOperator folding in GEP.
Eric Christopher [Sun, 17 Oct 2010 01:41:46 +0000 (01:41 +0000)]
Turn on AddOperator folding in GEP.

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

13 years agoUse the i12 immediate versions of the load instructions - they're handled
Eric Christopher [Sun, 17 Oct 2010 01:40:27 +0000 (01:40 +0000)]
Use the i12 immediate versions of the load instructions - they're handled
more in the post-passes.

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

13 years agoAdd a MCObjectFormat class so that code common to all targets that use a
Rafael Espindola [Sat, 16 Oct 2010 18:23:53 +0000 (18:23 +0000)]
Add a MCObjectFormat class so that code common to all targets that use a
single object format can be shared.

This also adds support for

mov zed+(bar-foo), %eax

on ELF and COFF targets.

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

13 years agoHack around incompatible pointer warnings.
Benjamin Kramer [Sat, 16 Oct 2010 15:43:02 +0000 (15:43 +0000)]
Hack around incompatible pointer warnings.

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

13 years agoEliminate some calls to Value::getNameStr.
Benjamin Kramer [Sat, 16 Oct 2010 11:28:23 +0000 (11:28 +0000)]
Eliminate some calls to Value::getNameStr.

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

13 years agoUnbreak test on non-COFF targets.
Benjamin Kramer [Sat, 16 Oct 2010 11:27:13 +0000 (11:27 +0000)]
Unbreak test on non-COFF targets.

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

13 years agoMC-COFF: Add support for default-null weak externals.
Michael J. Spencer [Sat, 16 Oct 2010 08:25:57 +0000 (08:25 +0000)]
MC-COFF: Add support for default-null weak externals.

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

13 years agoX86-Windows: Emit an undefined global __fltused symbol when targeting Windows
Michael J. Spencer [Sat, 16 Oct 2010 08:25:41 +0000 (08:25 +0000)]
X86-Windows: Emit an undefined global __fltused symbol when targeting Windows
if any floating point arguments are passed to an external function.

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

13 years agoWhitespace!
Michael J. Spencer [Sat, 16 Oct 2010 08:25:21 +0000 (08:25 +0000)]
Whitespace!

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

13 years agoMC/AsmParser: Report .stabs directive as unsupported.
Daniel Dunbar [Sat, 16 Oct 2010 04:56:42 +0000 (04:56 +0000)]
MC/AsmParser: Report .stabs directive as unsupported.

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

13 years agoMore machine LICM work. It now tracks register pressure for path from preheader to...
Evan Cheng [Sat, 16 Oct 2010 02:20:26 +0000 (02:20 +0000)]
More machine LICM work. It now tracks register pressure for path from preheader to current BB and use the information determine whether hoisting is worthwhile.

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

13 years agoFix some funky formatting that got through.
Eric Christopher [Sat, 16 Oct 2010 01:10:35 +0000 (01:10 +0000)]
Fix some funky formatting that got through.

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

13 years agoARMCodeEmitter::emitMiscInstruction is dead. Long live
Bill Wendling [Fri, 15 Oct 2010 23:35:12 +0000 (23:35 +0000)]
ARMCodeEmitter::emitMiscInstruction is dead. Long live
ARMCodeEmitter::emitMiscInstruction!

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

13 years agoMake sure offset is 0 for load/store register to the stack call.
Eric Christopher [Fri, 15 Oct 2010 23:07:10 +0000 (23:07 +0000)]
Make sure offset is 0 for load/store register to the stack call.

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

13 years agoGeneralize MemCpyOpt's handling of call slot forwarding to function properly when...
Owen Anderson [Fri, 15 Oct 2010 22:52:12 +0000 (22:52 +0000)]
Generalize MemCpyOpt's handling of call slot forwarding to function properly when the call slot
forwarding is implemented with a load/store pair rather than a memcpy.

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

13 years agoFormatting.
Eric Christopher [Fri, 15 Oct 2010 22:49:28 +0000 (22:49 +0000)]
Formatting.

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

13 years agolto: Respect LLVM_VERSION_INFO make variable, since setting CC arguments with
Daniel Dunbar [Fri, 15 Oct 2010 22:46:15 +0000 (22:46 +0000)]
lto: Respect LLVM_VERSION_INFO make variable, since setting CC arguments with
spaces gives tests fits and shell escaping is an art best left to jabberwockies.

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

13 years agoFix else if -> if in store machinery.
Eric Christopher [Fri, 15 Oct 2010 22:32:37 +0000 (22:32 +0000)]
Fix else if -> if in store machinery.

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

13 years agoReformatting. No functionalogicality changes.
Bill Wendling [Fri, 15 Oct 2010 21:50:45 +0000 (21:50 +0000)]
Reformatting. No functionalogicality changes.

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

13 years agoRefactor ARM fast-isel reg + offset to be a base + offset.
Eric Christopher [Fri, 15 Oct 2010 21:32:12 +0000 (21:32 +0000)]
Refactor ARM fast-isel reg + offset to be a base + offset.

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

13 years agoEncoding information for the various ARM saturating add/sub instructions.
Jim Grosbach [Fri, 15 Oct 2010 19:49:46 +0000 (19:49 +0000)]
Encoding information for the various ARM saturating add/sub instructions.

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

13 years agollvmc: Add a test for the -c flag.
Mikhail Glushenkov [Fri, 15 Oct 2010 19:30:49 +0000 (19:30 +0000)]
llvmc: Add a test for the -c flag.

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

13 years agoARM binary encoding information for RSB and RSC instructions.
Jim Grosbach [Fri, 15 Oct 2010 18:42:41 +0000 (18:42 +0000)]
ARM binary encoding information for RSB and RSC instructions.

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

13 years agoDon't mark argument value stores as immutable, as otherwise the post-RA
Jim Grosbach [Fri, 15 Oct 2010 18:34:47 +0000 (18:34 +0000)]
Don't mark argument value stores as immutable, as otherwise the post-RA
scheduler may reorder loads from them before the stores and other such
badness. PR8347. Patch by David Meyer

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

13 years agoUse simple RegState::Define flag instead of getDefRegState(true).
Bob Wilson [Fri, 15 Oct 2010 18:25:59 +0000 (18:25 +0000)]
Use simple RegState::Define flag instead of getDefRegState(true).

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

13 years agoRefactor alias handling to AliasedSymbol.
Rafael Espindola [Fri, 15 Oct 2010 18:25:33 +0000 (18:25 +0000)]
Refactor alias handling to AliasedSymbol.

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

13 years agoKillTheDoctor: Fix 2008 build. I'm actually surprised 2010 defines all of these,...
Michael J. Spencer [Fri, 15 Oct 2010 18:13:02 +0000 (18:13 +0000)]
KillTheDoctor: Fix 2008 build. I'm actually surprised 2010 defines all of these, many are non-standard posix/unix extensions.

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

13 years agoExpand GEP handling for constant offsets.
Eric Christopher [Fri, 15 Oct 2010 18:02:07 +0000 (18:02 +0000)]
Expand GEP handling for constant offsets.

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

13 years agoTeach FileCheck to handle trailing CHECK-NOT patterns.
Jakob Stoklund Olesen [Fri, 15 Oct 2010 17:47:12 +0000 (17:47 +0000)]
Teach FileCheck to handle trailing CHECK-NOT patterns.

A CHECK-NOT pattern without a following CHECK pattern simply checks that the
pattern doesn't match before the end of the input file.

You can even have only CHECK-NOT patterns to check that strings appear nowhere
in the input file.

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

13 years agoWhen expanding the MOVsr[la]_flag pseudos, the CPSR implicit def becomes
Jim Grosbach [Fri, 15 Oct 2010 17:35:17 +0000 (17:35 +0000)]
When expanding the MOVsr[la]_flag pseudos, the CPSR implicit def becomes
an explicit def. Make sure to capture that properly. rdar://8556556

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

13 years agoARM mode encoding information for UBFX and SBFX instructions.
Jim Grosbach [Fri, 15 Oct 2010 17:15:16 +0000 (17:15 +0000)]
ARM mode encoding information for UBFX and SBFX instructions.

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

13 years agoFileCheckize
Jakob Stoklund Olesen [Fri, 15 Oct 2010 16:06:42 +0000 (16:06 +0000)]
FileCheckize

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

13 years agoRemove unused accessor.
Jakob Stoklund Olesen [Fri, 15 Oct 2010 16:06:40 +0000 (16:06 +0000)]
Remove unused accessor.

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

13 years agoRefactor code a bit and avoid creating unnecessary entries in the string
Rafael Espindola [Fri, 15 Oct 2010 15:39:06 +0000 (15:39 +0000)]
Refactor code a bit and avoid creating unnecessary entries in the string
map.

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

13 years agoRemove unused ARMISD::AND selection DAG node.
Bob Wilson [Fri, 15 Oct 2010 04:34:40 +0000 (04:34 +0000)]
Remove unused ARMISD::AND selection DAG node.

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

13 years agoARM instructions that are both predicated and set the condition codes
Bob Wilson [Fri, 15 Oct 2010 03:23:44 +0000 (03:23 +0000)]
ARM instructions that are both predicated and set the condition codes
have been printed with the "S" modifier after the predicate.  With ARM's
unified syntax, they are supposed to go in the other order.  We fixed this
for Thumb when we switched to unified syntax but missed changing it for
ARM.  Apparently we don't generate these instructions often because no one
noticed until now.  Thanks to Bill Wendling for the testcase!

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