oota-llvm.git
15 years agoKill off SwitchToDataSection and SwitchToTextSection, woo.
Chris Lattner [Mon, 3 Aug 2009 23:10:34 +0000 (23:10 +0000)]
Kill off SwitchToDataSection and SwitchToTextSection, woo.

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

15 years agoremove an unneeded section switch.
Chris Lattner [Mon, 3 Aug 2009 23:02:45 +0000 (23:02 +0000)]
remove an unneeded section switch.

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

15 years agoswitch ppc to using SwitchToSection instead of textual section stuff.
Chris Lattner [Mon, 3 Aug 2009 22:52:21 +0000 (22:52 +0000)]
switch ppc to using SwitchToSection instead of textual section stuff.

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

15 years agoKeep track of metadata used by other metadata.
Devang Patel [Mon, 3 Aug 2009 22:51:10 +0000 (22:51 +0000)]
Keep track of metadata used by other metadata.

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

15 years agouse TLOF to compute the section for a function instead of
Chris Lattner [Mon, 3 Aug 2009 22:32:50 +0000 (22:32 +0000)]
use TLOF to compute the section for a function instead of
replicating the logic manually.

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

15 years agoMinor whitespace fix, so this doesn't look like a unary *.
Dan Gohman [Mon, 3 Aug 2009 22:30:18 +0000 (22:30 +0000)]
Minor whitespace fix, so this doesn't look like a unary *.

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

15 years agoAdd -disable-output. Thanks Bill!
Dan Gohman [Mon, 3 Aug 2009 22:24:22 +0000 (22:24 +0000)]
Add -disable-output. Thanks Bill!

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

15 years agoconvert macho stub emission to use SwitchToSection instead of
Chris Lattner [Mon, 3 Aug 2009 22:18:15 +0000 (22:18 +0000)]
convert macho stub emission to use SwitchToSection instead of
textual sections.

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

15 years agohoist some common code out of a switch
Chris Lattner [Mon, 3 Aug 2009 22:16:57 +0000 (22:16 +0000)]
hoist some common code out of a switch

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

15 years agoAdd a new Constant::getIntegerValue helper function, and convert a
Dan Gohman [Mon, 3 Aug 2009 22:07:33 +0000 (22:07 +0000)]
Add a new Constant::getIntegerValue helper function, and convert a
few places in InstCombine to use it, to fix problems handling pointer
types. This fixes the recent llvm-gcc bootstrap error.

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

15 years agothis really shouldn't switch sections without telling the asmprinter, but
Chris Lattner [Mon, 3 Aug 2009 21:57:00 +0000 (21:57 +0000)]
this really shouldn't switch sections without telling the asmprinter, but
hey it uses .previous, so it should work :)

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

15 years agoRe-apply LiveInterval index dumping patch, with fixes suggested by Bill
David Greene [Mon, 3 Aug 2009 21:55:09 +0000 (21:55 +0000)]
Re-apply LiveInterval index dumping patch, with fixes suggested by Bill
and others.

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

15 years agoEliminate textual section switching from the x86 backend, one
Chris Lattner [Mon, 3 Aug 2009 21:53:27 +0000 (21:53 +0000)]
Eliminate textual section switching from the x86 backend, one
more step towards "semantics sections"

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

15 years agoLower CONCAT_VECTOR during legalization instead of matching it during isel.
Bob Wilson [Mon, 3 Aug 2009 20:36:38 +0000 (20:36 +0000)]
Lower CONCAT_VECTOR during legalization instead of matching it during isel.
Add a testcase.

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

15 years agoFix Bug 4657: register scavenger asserts with subreg lowering
Jakob Stoklund Olesen [Mon, 3 Aug 2009 20:08:18 +0000 (20:08 +0000)]
Fix Bug 4657: register scavenger asserts with subreg lowering

When LowerSubregsInstructionPass::LowerInsert eliminates an INSERT_SUBREG
instriction because it is an identity copy, make sure that the same registers
are alive before and after the elimination.

When the super-register is marked <undef> this requires inserting an
IMPLICIT_DEF instruction to make sure the super register is live.

Fix a related bug where a kill flag on the inserted sub-register was not transferred properly.

Finally, clear the undef flag in MachineInstr::addRegisterKilled. Undef implies dead and kill implies live, so they cant both be valid.

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

15 years agoMinor stylistic cleanups in the Blackfin target.
Jakob Stoklund Olesen [Mon, 3 Aug 2009 19:32:30 +0000 (19:32 +0000)]
Minor stylistic cleanups in the Blackfin target.

Thanks Chris.

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

15 years agoMake SimplifyDemandedUseBits generate vector constants where
Eli Friedman [Mon, 3 Aug 2009 19:15:42 +0000 (19:15 +0000)]
Make SimplifyDemandedUseBits generate vector constants where
appropriate.  Patch per report on llvmdev.  No testcase because the
original report didn't come with a testcase, and I can't come up with a case
that actually fails.

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

15 years agomake getObjFileLowering() return a non-const reference.
Chris Lattner [Mon, 3 Aug 2009 19:12:26 +0000 (19:12 +0000)]
make getObjFileLowering() return a non-const reference.

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

15 years agoremove a dead switch directive, replace it with some
Chris Lattner [Mon, 3 Aug 2009 19:10:44 +0000 (19:10 +0000)]
remove a dead switch directive, replace it with some
code that I will be using shortly.

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

15 years agoRevert 77974. It breaks 3 of the ARM tests.
Bob Wilson [Mon, 3 Aug 2009 19:06:29 +0000 (19:06 +0000)]
Revert 77974.  It breaks 3 of the ARM tests.

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

15 years agoRemove neverHasSideEffects on MMX_MOVD64rrv164 since it has a matching pattern.
Evan Cheng [Mon, 3 Aug 2009 18:07:19 +0000 (18:07 +0000)]
Remove neverHasSideEffects on MMX_MOVD64rrv164 since it has a matching pattern.

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

15 years agoeliminate textual section switching from intel asm printer.
Chris Lattner [Mon, 3 Aug 2009 18:06:07 +0000 (18:06 +0000)]
eliminate textual section switching from intel asm printer.
This will cause it to enter the ".text" section instead of "_text"
but masm is already broken.

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

15 years agomake SwitchToSection accept null sections for now.
Chris Lattner [Mon, 3 Aug 2009 18:04:42 +0000 (18:04 +0000)]
make SwitchToSection accept null sections for now.

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

15 years agoChange C, CBE, MSIL to not provide target data via getTargetData().
Daniel Dunbar [Mon, 3 Aug 2009 17:40:25 +0000 (17:40 +0000)]
Change C, CBE, MSIL to not provide target data via getTargetData().
 - The theory is these should never actually be called, since these boil down to
   passes which can access the target data via the standard mechanism.

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

15 years agoAllow targets to custom handle softening of results or operands before trying the...
Sanjiv Gupta [Mon, 3 Aug 2009 17:35:21 +0000 (17:35 +0000)]
Allow targets to custom handle softening of results or operands before trying the standard stuff.

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

15 years agoProvide target data from the module if the target machine doesn't have any.
Daniel Dunbar [Mon, 3 Aug 2009 17:34:19 +0000 (17:34 +0000)]
Provide target data from the module if the target machine doesn't have any.

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

15 years agollvm_report_error already prints "LLVM ERROR:". So stop reporting errors like "LLVM...
Benjamin Kramer [Mon, 3 Aug 2009 13:33:33 +0000 (13:33 +0000)]
llvm_report_error already prints "LLVM ERROR:". So stop reporting errors like "LLVM ERROR: llvm: error:" or "LLVM ERROR: ERROR:".

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

15 years agoUnbreak win64 compilation callback.
Anton Korobeynikov [Mon, 3 Aug 2009 08:43:36 +0000 (08:43 +0000)]
Unbreak win64 compilation callback.
Since we're generating stubs by hands we don't follow the ABI and don't
create a register spill area.
Don't use this area in compilation callback!

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

15 years agoFix a coaelescer bug. If a copy val# is extended to eliminate a non-trivially coalesc...
Evan Cheng [Mon, 3 Aug 2009 08:41:59 +0000 (08:41 +0000)]
Fix a coaelescer bug. If a copy val# is extended to eliminate a non-trivially coalesced copy, and the copy kills its source register. Trim the source register's live range to the last use if possible. This fixes up kill marker to make the scavenger happy.

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

15 years agoCreate proper frame index for FP
Anton Korobeynikov [Mon, 3 Aug 2009 08:14:30 +0000 (08:14 +0000)]
Create proper frame index for FP

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

15 years agoPerform bitconvert to proper type
Anton Korobeynikov [Mon, 3 Aug 2009 08:14:14 +0000 (08:14 +0000)]
Perform bitconvert to proper type

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

15 years agoAdd 'Indirect' LocInfo class and use to pass __m128 on win64. Also minore fixes here...
Anton Korobeynikov [Mon, 3 Aug 2009 08:13:56 +0000 (08:13 +0000)]
Add 'Indirect' LocInfo class and use to pass __m128 on win64. Also minore fixes here and there (mostly __m64).

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

15 years agoCleanup Darwin MMX calling conv stuff - make the stuff more generic. This also fixes...
Anton Korobeynikov [Mon, 3 Aug 2009 08:13:24 +0000 (08:13 +0000)]
Cleanup Darwin MMX calling conv stuff - make the stuff more generic. This also fixes a subtle bug, when 6th v1i64 argument passed wrongly.

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

15 years agoUnbreak Win64 CC. Step one: honour register save area, fix some alignment and provide...
Anton Korobeynikov [Mon, 3 Aug 2009 08:12:53 +0000 (08:12 +0000)]
Unbreak Win64 CC. Step one: honour register save area, fix some alignment and provide a different set of call-clobberred registers.

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

15 years agoRemove the GCC path from libLTO. This has been superceded by setAssemblerPath.
Nick Lewycky [Mon, 3 Aug 2009 07:16:42 +0000 (07:16 +0000)]
Remove the GCC path from libLTO. This has been superceded by setAssemblerPath.

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

15 years agoAdd NamedMDNode destructor.
Devang Patel [Mon, 3 Aug 2009 06:19:01 +0000 (06:19 +0000)]
Add NamedMDNode destructor.

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

15 years agoUse movd instead of movq
Rafael Espindola [Mon, 3 Aug 2009 05:21:05 +0000 (05:21 +0000)]
Use movd instead of movq

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

15 years agoAdd FileUpdate tool, conditionally updates its output based on its input.
Daniel Dunbar [Mon, 3 Aug 2009 05:12:16 +0000 (05:12 +0000)]
Add FileUpdate tool, conditionally updates its output based on its input.
 - Gratuitous and unused, but possibly useful one day.

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

15 years agoFix a race condition in getting the process exit code on Win32.
Daniel Dunbar [Mon, 3 Aug 2009 05:02:46 +0000 (05:02 +0000)]
Fix a race condition in getting the process exit code on Win32.

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

15 years agoRemove now unused arguments from TargetRegistry::lookupTarget.
Daniel Dunbar [Mon, 3 Aug 2009 04:20:57 +0000 (04:20 +0000)]
Remove now unused arguments from TargetRegistry::lookupTarget.

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

15 years agoThese are done.
Evan Cheng [Mon, 3 Aug 2009 04:08:36 +0000 (04:08 +0000)]
These are done.

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

15 years agoPass target triple string in to TargetMachine constructor.
Daniel Dunbar [Mon, 3 Aug 2009 04:03:51 +0000 (04:03 +0000)]
Pass target triple string in to TargetMachine constructor.

This is not just a matter of passing in the target triple from the module;
currently backends are making decisions based on the build and host
architecture. The goal is to migrate to making these decisions based off of the
triple (in conjunction with the feature string). Thus most clients pass in the
target triple, or the host triple if that is empty.

This has one important change in the way behavior of the JIT and llc.

For the JIT, it was previously selecting the Target based on the host
(naturally), but it was setting the target machine features based on the triple
from the module. Now it is setting the target machine features based on the
triple of the host.

For LLC, -march was previously only used to select the target, the target
machine features were initialized from the module's triple (which may have been
empty). Now the target triple is taken from the module, or the host's triple is
used if that is empty. Then the triple is adjusted to match -march.

The take away is that -march for llc is now used in conjunction with the host
triple to initialize the subtarget. If users want more deterministic behavior
from llc, they should use -mtriple, or set the triple in the input module.

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

15 years agoFix the instruction encoding.
Rafael Espindola [Mon, 3 Aug 2009 03:27:05 +0000 (03:27 +0000)]
Fix the instruction encoding.

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

15 years agoRemove a bitcast that was a no-op.
Rafael Espindola [Mon, 3 Aug 2009 03:00:05 +0000 (03:00 +0000)]
Remove a bitcast that was a no-op.
Thanks to Eli Friedman for noticing it.

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

15 years agoUse movq to move 64 bits in and out of mmx registers.
Rafael Espindola [Mon, 3 Aug 2009 02:45:34 +0000 (02:45 +0000)]
Use movq to move 64 bits in and out of mmx registers.
Fixes PR4669

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

15 years agoUse the i12 variant of load / store opcodes if offset is zero. Now we pass all of...
Evan Cheng [Mon, 3 Aug 2009 02:38:06 +0000 (02:38 +0000)]
Use the i12 variant of load / store opcodes if offset is zero. Now we pass all of multisource as well.

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

15 years agoRemove -disable-mips-abicall and -enable-mips-absolute-call command-line
Eli Friedman [Mon, 3 Aug 2009 02:22:28 +0000 (02:22 +0000)]
Remove -disable-mips-abicall and -enable-mips-absolute-call command-line
options, which don't appear to be useful.  -enable-mips-absolute-call is
completely unused (and unless I'm mistaken, is supposed to have the
same effect that -relocation-model=dynamic-no-pic should have),
and -disable-mips-abicall appears to be effectively a
synonym for -relocation-model=static. Adjust the few users of hasABICall
to checks which seem more appropriate.  Update MipsSubtarget,
MipsTargetMachine, and MipselTargetMachine to synchronize with recent
changes.

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

15 years agoRestrict LDA to affine subscripts.
Andreas Bolka [Mon, 3 Aug 2009 01:03:48 +0000 (01:03 +0000)]
Restrict LDA to affine subscripts.

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

15 years agoFix some comments referring to std::cerr.
Daniel Dunbar [Mon, 3 Aug 2009 01:02:24 +0000 (01:02 +0000)]
Fix some comments referring to std::cerr.

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

15 years ago- s/DOUT/DEBUG(errs()/g
Bill Wendling [Mon, 3 Aug 2009 00:11:34 +0000 (00:11 +0000)]
- s/DOUT/DEBUG(errs()/g
- Tidy up some headers.

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

15 years agoMove most targets TargetMachine constructor to only taking a target triple.
Daniel Dunbar [Sun, 2 Aug 2009 23:37:13 +0000 (23:37 +0000)]
Move most targets TargetMachine constructor to only taking a target triple.
 - The C, C++, MSIL, and Mips backends still need the module.

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

15 years agoExpand LDA testcases.
Andreas Bolka [Sun, 2 Aug 2009 23:28:14 +0000 (23:28 +0000)]
Expand LDA testcases.

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

15 years agoAdd extra SEXT pattern.
Richard Osborne [Sun, 2 Aug 2009 22:45:24 +0000 (22:45 +0000)]
Add extra SEXT pattern.

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

15 years agoThe x86 jit doesn't generate a def_cfa_offset unwind instruction after the
Bill Wendling [Sun, 2 Aug 2009 22:25:37 +0000 (22:25 +0000)]
The x86 jit doesn't generate a def_cfa_offset unwind instruction after the
pushes in the function prolog if the function doesn't have any stack space,
i.e. for a prolog like:

0x40011870:     push %r15
0x40011872:     push %r14
0x40011874:     push %rbx

Patch by Zoltan!

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

15 years agoNormalize Subtarget constructors to take a target triple string instead of
Daniel Dunbar [Sun, 2 Aug 2009 22:11:08 +0000 (22:11 +0000)]
Normalize Subtarget constructors to take a target triple string instead of
Module*.

Also, dropped uses of TargetMachine where unnecessary. The only target which
still takes a TargetMachine& is Mips, I would appreciate it if someone would
normalize this to match other targets.

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

15 years agoRemove unneeded intrinsics from Blackfin backend.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 21:49:05 +0000 (21:49 +0000)]
Remove unneeded intrinsics from Blackfin backend.

__builtin_bfin_ones does the same as ctpop, so it can be implemented in the front-end.

__builtin_bfin_loadbytes loads from an unaligned pointer with the disalignexcpt instruction. It does the same as loading from a pointer with the low bits masked. It is better if the front-end creates a masked load. We can always instruction select the masked to disalignexcpt+load.

We keep csync/ssync/idle. These intrinsics represent instructions that need workarounds for some silicon revisions. We may even want to convert inline assembler to intrinsics to enable the workarounds.

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

15 years agoFix the build for people with oprofile installed.
Nick Lewycky [Sun, 2 Aug 2009 20:51:44 +0000 (20:51 +0000)]
Fix the build for people with oprofile installed.

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

15 years agoEmpty arguments need to be quoted on Win32.
Daniel Dunbar [Sun, 2 Aug 2009 20:41:09 +0000 (20:41 +0000)]
Empty arguments need to be quoted on Win32.

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

15 years agoFix issue in regscavenger when scavenging a callee-saved register that has not been...
Jakob Stoklund Olesen [Sun, 2 Aug 2009 20:29:41 +0000 (20:29 +0000)]
Fix issue in regscavenger when scavenging a callee-saved register that has not been spilled.

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

15 years agoOne two many newlines at end of file LLVMContextImpl.cpp
Edward O'Callaghan [Sun, 2 Aug 2009 20:06:26 +0000 (20:06 +0000)]
One two many newlines at end of file LLVMContextImpl.cpp

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

15 years agoTweak svn:ignore more
Daniel Dunbar [Sun, 2 Aug 2009 19:53:40 +0000 (19:53 +0000)]
Tweak svn:ignore more

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

15 years agoTweak svn:ignore
Daniel Dunbar [Sun, 2 Aug 2009 19:53:19 +0000 (19:53 +0000)]
Tweak svn:ignore

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

15 years agoAdjust comment to distinguish between target name and triple target name they
Daniel Dunbar [Sun, 2 Aug 2009 19:41:20 +0000 (19:41 +0000)]
Adjust comment to distinguish between target name and triple target name they
match.

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

15 years agoFix no newline at end of LLVMContextImpl.cpp
Edward O'Callaghan [Sun, 2 Aug 2009 19:38:12 +0000 (19:38 +0000)]
Fix no newline at end of LLVMContextImpl.cpp

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

15 years agoNever add a kill flag to a constrained physical register in a two-addr instruction.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 19:13:03 +0000 (19:13 +0000)]
Never add a kill flag to a constrained physical register in a two-addr instruction.

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

15 years agoScavenger asserts.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 18:28:41 +0000 (18:28 +0000)]
Scavenger asserts.

Allow imp-def and imp-use of anything in the scavenger asserts, just like the machine code verifier.
Allow redefinition of a sub-register of a live register.

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

15 years agoAdd some basic blackfin intrinsics.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 18:28:11 +0000 (18:28 +0000)]
Add some basic blackfin intrinsics.

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

15 years agoAdd support for CPU features (i.e., bugs) and workarounds.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 18:27:36 +0000 (18:27 +0000)]
Add support for CPU features (i.e., bugs) and workarounds.

This is just the framework to identify the needed workarounds. They are not actually implemented.

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

15 years agoInline assembly support for Blackfin.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 17:39:17 +0000 (17:39 +0000)]
Inline assembly support for Blackfin.

We use the same constraints as GCC, including those that are slightly insane for inline assembler.

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

15 years agoBuild Blackfin target with autoconf and cmake.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 17:32:37 +0000 (17:32 +0000)]
Build Blackfin target with autoconf and cmake.

Note that configure was edited by hand. Will somebody with the correct version of autoconf please regenerate?

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

15 years agoAnalog Devices Blackfin back-end.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 17:32:10 +0000 (17:32 +0000)]
Analog Devices Blackfin back-end.

Generate code for the Blackfin family of DSPs from Analog Devices:

  http://www.analog.com/en/embedded-processing-dsp/blackfin/processors/index.html

We aim to be compatible with the exsisting GNU toolchain found at:

  http://blackfin.uclinux.org/gf/project/toolchain

The back-end is experimental.

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

15 years agoAvoid forming a SELECT_CC in a type that the target doesn't
Dan Gohman [Sun, 2 Aug 2009 16:19:38 +0000 (16:19 +0000)]
Avoid forming a SELECT_CC in a type that the target doesn't
support. This isn't immediately interesting, because Legalize
ends up lowering SELECT_CC if the target doesn't support it,
but this simplifies the process.

Also, if the SELECT_CC would be expanded in Legalize, it
can potentially end up with two copies of the condition
expression. By leaving it as SELECT+SETCC, the SELECT can be
expanded into two SELECTs that use a single SETCC.

The two comparisons are usually CSE'd, but depending on
when various expressions get legalized, the comparison
expression could involve calls to library functions, such
that the comparison expression may not be able to be CSE'd.
This will be needed by a future patch.

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

15 years agoFix indentation.
Dan Gohman [Sun, 2 Aug 2009 16:10:52 +0000 (16:10 +0000)]
Fix indentation.

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

15 years agoAdd a comment.
Dan Gohman [Sun, 2 Aug 2009 16:10:01 +0000 (16:10 +0000)]
Add a comment.

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

15 years agoResync lea32addr and lea64addr.
Dan Gohman [Sun, 2 Aug 2009 16:09:17 +0000 (16:09 +0000)]
Resync lea32addr and lea64addr.

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

15 years agoRemove duplicated colons and spaces.
Benjamin Kramer [Sun, 2 Aug 2009 12:13:02 +0000 (12:13 +0000)]
Remove duplicated colons and spaces.

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

15 years agoHandle <undef> flag in machine code verifier.
Jakob Stoklund Olesen [Sun, 2 Aug 2009 07:38:21 +0000 (07:38 +0000)]
Handle <undef> flag in machine code verifier.

Use of an <undef> register is treated like an <imp-use>. It is not an error to use a dead <undef> register.

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

15 years agomove dwarf debug info section selection stuff from TAI to
Chris Lattner [Sun, 2 Aug 2009 07:24:22 +0000 (07:24 +0000)]
move dwarf debug info section selection stuff from TAI to
TLOF, unifying all the dwarf targets at the same time.

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

15 years agoconvert EHFrameSection to be managed by TLOF instead of TAI.
Chris Lattner [Sun, 2 Aug 2009 06:52:36 +0000 (06:52 +0000)]
convert EHFrameSection to be managed by TLOF instead of TAI.

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

15 years agoI need Triple information, 10.6 shouldn't set this, it bloats
Chris Lattner [Sun, 2 Aug 2009 06:51:58 +0000 (06:51 +0000)]
I need Triple information, 10.6 shouldn't set this, it bloats
object files.

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

15 years agoARM TAI no longer needs a TM, but createTargetAsmInfo() still does.
Chris Lattner [Sun, 2 Aug 2009 05:23:52 +0000 (05:23 +0000)]
ARM TAI no longer needs a TM, but createTargetAsmInfo() still does.

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

15 years agoMove the getInlineAsmLength virtual method from TAI to TII, where
Chris Lattner [Sun, 2 Aug 2009 05:20:37 +0000 (05:20 +0000)]
Move the getInlineAsmLength virtual method from TAI to TII, where
the only real caller (GetFunctionSizeInBytes) uses it.

The custom ARM implementation of this is basically reimplementing
an assembler poorly for negligible gain.  It should be removed
IMNSHO, but I'll leave that to ARMish folks to decide.

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

15 years agomove a virtual method body to its .cpp file to avoid a #include
Chris Lattner [Sun, 2 Aug 2009 04:58:19 +0000 (04:58 +0000)]
move a virtual method body to its .cpp file to avoid a #include
in a header.

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

15 years agoturn some templated inline functions into static functions.
Chris Lattner [Sun, 2 Aug 2009 04:52:00 +0000 (04:52 +0000)]
turn some templated inline functions into static functions.

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

15 years agoalpha TAI doesn't need TM.
Chris Lattner [Sun, 2 Aug 2009 04:46:05 +0000 (04:46 +0000)]
alpha TAI doesn't need TM.

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

15 years agoMSP430 TAI doesn't need TM.
Chris Lattner [Sun, 2 Aug 2009 04:45:22 +0000 (04:45 +0000)]
MSP430 TAI doesn't need TM.

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

15 years agosimplify SPULinuxTargetAsmInfo, remove use of TM.
Chris Lattner [Sun, 2 Aug 2009 04:44:33 +0000 (04:44 +0000)]
simplify SPULinuxTargetAsmInfo, remove use of TM.

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

15 years agoxcore TAI doesn't need TM.
Chris Lattner [Sun, 2 Aug 2009 04:42:09 +0000 (04:42 +0000)]
xcore TAI doesn't need TM.

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

15 years agoPIC16 TAI doesn't need TM
Chris Lattner [Sun, 2 Aug 2009 04:41:14 +0000 (04:41 +0000)]
PIC16 TAI doesn't need TM

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

15 years agoremove the dead ELFTargetAsmInfo.h/cpp file. TargetAsmInfo
Chris Lattner [Sun, 2 Aug 2009 04:33:09 +0000 (04:33 +0000)]
remove the dead ELFTargetAsmInfo.h/cpp file.  TargetAsmInfo
defaults to being ELF.

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

15 years agoeliminate the TM argument to the TAI class, remove comment about supporting
Chris Lattner [Sun, 2 Aug 2009 04:32:07 +0000 (04:32 +0000)]
eliminate the TM argument to the TAI class, remove comment about supporting
solaris :)

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

15 years agoeliminate TargetMAchine argument to sparc TAI
Chris Lattner [Sun, 2 Aug 2009 04:30:59 +0000 (04:30 +0000)]
eliminate TargetMAchine argument to sparc TAI

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

15 years agoremove TargetAsmInfo::TM, which is now dead. The basic TAI class now
Chris Lattner [Sun, 2 Aug 2009 04:27:24 +0000 (04:27 +0000)]
remove TargetAsmInfo::TM, which is now dead.  The basic TAI class now
no longer depends on TM!

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

15 years agoremove the x86/ppc impls of getEHGlobalPrefix, which is already dead.
Chris Lattner [Sun, 2 Aug 2009 04:13:22 +0000 (04:13 +0000)]
remove the x86/ppc impls of getEHGlobalPrefix, which is already dead.

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

15 years agoAdd missing flush().
Daniel Dunbar [Sun, 2 Aug 2009 04:12:28 +0000 (04:12 +0000)]
Add missing flush().

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

15 years agoclean up #includes of TargetAsmInfo.cpp
Chris Lattner [Sun, 2 Aug 2009 04:09:22 +0000 (04:09 +0000)]
clean up #includes of TargetAsmInfo.cpp

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

15 years agomove an enum from TM -> TargetOptions. This makes TargetOptions.h
Chris Lattner [Sun, 2 Aug 2009 04:08:52 +0000 (04:08 +0000)]
move an enum from TM -> TargetOptions.  This makes TargetOptions.h
be self contained, and it isn't used from TM.h

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

15 years agoremove the dead PreferredEHDataFormat TAI hook: its now dead
Chris Lattner [Sun, 2 Aug 2009 04:02:52 +0000 (04:02 +0000)]
remove the dead PreferredEHDataFormat TAI hook: its now dead
even considering #if 0 code.

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

15 years agoFix some fixme's in #if 0'd code by making it dependent on the structural
Chris Lattner [Sun, 2 Aug 2009 03:59:56 +0000 (03:59 +0000)]
Fix some fixme's in #if 0'd code by making it dependent on the structural
behavior of the LSDA section instead of on some random target hook that
needs to be kept in synch with other points of truth.

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

15 years agoTest both darwin and linux.
Evan Cheng [Sun, 2 Aug 2009 02:54:34 +0000 (02:54 +0000)]
Test both darwin and linux.

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