Nadav Rotem [Wed, 10 Oct 2012 21:31:55 +0000 (21:31 +0000)]
Patch by Shuxin Yang <shuxin.llvm@gmail.com>.
Original message:
The attached is the fix to radar://
11663049. The optimization can be outlined by following rules:
(select (x != c), e, c) -> select (x != c), e, x),
(select (x == c), c, e) -> select (x == c), x, e)
where the <c> is an integer constant.
The reason for this change is that : on x86, conditional-move-from-constant needs two instructions;
however, conditional-move-from-register need only one instruction.
While the LowerSELECT() sounds to be the most convenient place for this optimization, it turns out to be a bad place. The reason is that by replacing the constant <c> with a symbolic value, it obscure some instruction-combining opportunities which would otherwise be very easy to spot. For that reason, I have to postpone the change to last instruction-combining phase.
The change passes the test of "make check-all -C <build-root/test" and "make -C project/test-suite/SingleSource".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165661
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Wed, 10 Oct 2012 21:25:01 +0000 (21:25 +0000)]
When generating spill and reload code for vector registers on PowerPC,
the compiler makes use of GPR0. However, there are two flavors of
GPR0 defined by the target: the 32-bit GPR0 (R0) and the 64-bit GPR0
(X0). The spill/reload code makes use of R0 regardless of whether we
are generating 32- or 64-bit code.
This patch corrects the problem in the obvious manner, using X0 and
ADDI8 for 64-bit and R0 and ADDI for 32-bit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165658
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Wed, 10 Oct 2012 20:54:15 +0000 (20:54 +0000)]
The PowerPC VRSAVE register has been somewhat of an odd beast since
the Altivec extensions were introduced. Its use is optional, and
allows the compiler to communicate to the operating system which
vector registers should be saved and restored during a context switch.
In practice, this information is ignored by the various operating
systems using the SVR4 ABI; the kernel saves and restores the entire
register state. Setting the VRSAVE register is no longer performed by
the AIX XL compilers, the IBM i compilers, or by GCC on Power Linux
systems. It seems best to avoid this logic within LLVM as well.
This patch avoids generating code to update and restore VRSAVE for the
PowerPC SVR4 ABIs (32- and 64-bit). The code remains in place for the
Darwin ABI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165656
91177308-0d34-0410-b5e6-
96231b3b80d8
Micah Villmow [Wed, 10 Oct 2012 20:50:51 +0000 (20:50 +0000)]
Add in support for expansion of all of the comparison operations to the absolute minimum required set. This allows a backend to expand any arbitrary set of comparisons as long as a minimum set is supported.
The minimum set of required instructions is ISD::AND, ISD::OR, ISD::SETO(or ISD::SETOEQ) and ISD::SETUO(or ISD::SETUNE). Everything is expanded into one of two patterns:
Pattern 1: (LHS CC1 RHS) Opc (LHS CC2 RHS)
Pattern 2: (LHS CC1 LHS) Opc (RHS CC2 RHS)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165655
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:50:36 +0000 (20:50 +0000)]
Revert r165652: "Remove unnecessary RTTI from the build."
... Apparently the RTTI is still necessary for some reason.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165654
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:27:20 +0000 (20:27 +0000)]
Remove unnecessary RTTI from the build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165652
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:27:18 +0000 (20:27 +0000)]
tblgen: Compile TableGen without RTTI.
TableGen no longer needs RTTI!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165651
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:24:49 +0000 (20:24 +0000)]
tblgen: Move mini Type hierarchy to LLVM-style RTTI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165648
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:24:47 +0000 (20:24 +0000)]
tblgen: Use semantically correct RTTI functions.
Also, some minor cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165647
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:24:43 +0000 (20:24 +0000)]
tblgen: Mechanically move dynamic_cast<> to dyn_cast<>.
Some of these dyn_cast<>'s would be better phrased as isa<> or cast<>.
That will happen in a future patch.
There are also two dyn_cast_or_null<>'s slipped in instead of
dyn_cast<>'s, since they were causing crashes with just dyn_cast<>.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165646
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 20:24:40 +0000 (20:24 +0000)]
tblgen: Put dyn_cast<> machinery in place for Init hierarchy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165645
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 10 Oct 2012 18:41:19 +0000 (18:41 +0000)]
Add the testcase from pr13254 (the old scalarreply pass handles this wrong;
the new sroa pass handles it right).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165644
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 18:20:49 +0000 (18:20 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165639
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Liao [Wed, 10 Oct 2012 18:04:52 +0000 (18:04 +0000)]
Specify CPU model to avoid breaking ATOM builds
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165638
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 18:02:57 +0000 (18:02 +0000)]
Remove unused argument.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165636
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 17:21:39 +0000 (17:21 +0000)]
docs: Propagate fix from r165632 to other docs.
There are only two other instances of using `.. code::` instead of
`.. code-block::`.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165633
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Wed, 10 Oct 2012 17:07:23 +0000 (17:07 +0000)]
docs: Attempt to fix PR14053.
Hypothesis 1: use of `.. code::` directive instead of `.. code-block::`
is causing Sphinx to discard the block. On my machine, `.. code::`
renders fine. However, I don't think that `.. code::` is actually a
legit Sphinx directive. I believe that on my machine Sphinx is falling
back to just displaying it monospace with no syntax, whereas llvm.org's
Sphinx is just discarding it.
This is truly "remote debugging" since I can't reproduce this on my
machine. It would be helpful to be able to see the llvm.org Sphinx
build logs; if that's possible please let me know.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165632
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Liao [Wed, 10 Oct 2012 16:53:28 +0000 (16:53 +0000)]
Add support for FP_ROUND from v2f64 to v2f32
- Due to the current matching vector elements constraints in
ISD::FP_ROUND, rounding from v2f64 to v4f32 (after legalization from
v2f32) is scalarized. Add a customized v2f32 widening to convert it
into a target-specific X86ISD::VFPROUND to work around this
constraints.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165631
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Liao [Wed, 10 Oct 2012 16:32:15 +0000 (16:32 +0000)]
Add alternative support for FP_ROUND from v2f32 to v2f64
- Due to the current matching vector elements constraints in ISD::FP_EXTEND,
rounding from v2f32 to v2f64 is scalarized. Add a customized v2f32 widening
to convert it into a target-specific X86ISD::VFPEXT to work around this
constraints. This patch also reverts a previous attempt to fix this issue by
recovering the scalarized ISD::FP_EXTEND pattern and thus significantly
reduces the overhead of supporting non-power-2 vector FP extend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165625
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Wed, 10 Oct 2012 13:33:00 +0000 (13:33 +0000)]
[CMake] check-all: Don't include check-llvm into check-all without LLVM_BUILD_TOOLS.
FIXME: Would you like to run llvm/unittests w/o LLVM_BUILD_TESTS regardless of LLVM_BUILD_TOOLS?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165619
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Wed, 10 Oct 2012 13:32:55 +0000 (13:32 +0000)]
[CMake] add_lit_testsuite: EXCLUDE_FROM_ALL excludes the test ${target} out of check-all.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165618
91177308-0d34-0410-b5e6-
96231b3b80d8
Stepan Dyatkovskiy [Wed, 10 Oct 2012 11:43:40 +0000 (11:43 +0000)]
Fix for LDRB instruction:
SDNode for LDRB_POST_IMM is invalid: number of registers added to SDNode fewer
that described in .td.
7 ops is needed, but SDNode with only 6 is created.
In more details:
In ARMInstrInfo.td, in multiclass AI2_ldridx, in definition _POST_IMM, offset
operand is defined as am2offset_imm. am2offset_imm is complex parameter type,
and actually it consists from dummy register and imm itself. As I understood
trick with dummy reg was made for AsmParser. In ARMISelLowering.cpp, this dummy
register was not added to SDNode, and it cause crash in Peephole Optimizer pass.
The problem fixed by setting up additional dummy reg when emitting
LDRB_POST_IMM instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165617
91177308-0d34-0410-b5e6-
96231b3b80d8
Stepan Dyatkovskiy [Wed, 10 Oct 2012 11:37:36 +0000 (11:37 +0000)]
Issue description:
SchedulerDAGInstrs::buildSchedGraph ignores dependencies between FixedStack
objects and byval parameters. So loading byval parameters from stack may be
inserted *before* it will be stored, since these operations are treated as
independent.
Fix:
Currently ARMTargetLowering::LowerFormalArguments saves byval registers with
FixedStack MachinePointerInfo. To fix the problem we need to store byval
registers with MachinePointerInfo referenced to first the "byval" parameter.
Also commit adds two new fields to the InputArg structure: Function's argument
index and InputArg's part offset in bytes relative to the start position of
Function's argument. E.g.: If function's argument is 128 bit width and it was
splitted onto 32 bit regs, then we got 4 InputArg structs with same arg index,
but different offset values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165616
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 08:03:34 +0000 (08:03 +0000)]
Cleanup. Get rid of now dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165613
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 07:36:45 +0000 (07:36 +0000)]
Remove the final bits of Attributes being declared in the Attribute
namespace. Use the attribute's enum value instead. No functionality change
intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165610
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Wed, 10 Oct 2012 06:39:48 +0000 (06:39 +0000)]
My earlier "fix" for PBQP (see r165201) was incorrect. The real issue was that
checkRegMaskInterference only initializes the bitmask on the first interference.
This fixes PR14027 and (re)fixes PR13945.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165608
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 06:13:42 +0000 (06:13 +0000)]
Pass into the AttributeWithIndex::get method an ArrayRef of attribute
enums. These are then created via the correct Attributes creation method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165607
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:18 +0000 (05:43 +0000)]
misched: fall-back to a target hook for instr bundles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165606
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:16 +0000 (05:43 +0000)]
TODO comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165605
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:13 +0000 (05:43 +0000)]
TableGen subtarget emitter cleanup.
Consistently evaluate Aliases and Sequences recursively.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165604
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:09 +0000 (05:43 +0000)]
misched: Use the TargetSchedModel interface wherever possible.
Allows the new machine model to be used for NumMicroOps and OutputLatency.
Allows the HazardRecognizer to be disabled along with itineraries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165603
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:04 +0000 (05:43 +0000)]
misched: Generate IsBuffered flag for machine resources.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165602
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Wed, 10 Oct 2012 05:43:01 +0000 (05:43 +0000)]
whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165601
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 05:29:15 +0000 (05:29 +0000)]
Place temporary LTO files into their own subdirectory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165599
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 10 Oct 2012 03:12:49 +0000 (03:12 +0000)]
Have 'addFnAttr' take the attribute enum value. Then have it build the attribute object and add it appropriately. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165595
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 10 Oct 2012 02:54:23 +0000 (02:54 +0000)]
Test case for r165480.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165594
91177308-0d34-0410-b5e6-
96231b3b80d8
Reed Kotler [Wed, 10 Oct 2012 01:58:16 +0000 (01:58 +0000)]
Reorder some parts of the td file to by in alphabetical order
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165590
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Wed, 10 Oct 2012 01:48:52 +0000 (01:48 +0000)]
Adding comments to clarify the reason for non-standard style in these files.
Patch committed on behalf of Kirill Uhanov
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165589
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Wed, 10 Oct 2012 01:45:52 +0000 (01:45 +0000)]
Cosmetic changes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165588
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Wed, 10 Oct 2012 01:41:33 +0000 (01:41 +0000)]
This patch adds new functions to the SectionRef and ObjectFile interfaces to determine whether or not a section is meant to be read-only. These functions will be used by the MCJIT RuntimeDyld to give hints to the memory manager during the object loading process in a future patch.
Patch by Ashok Thirumurthi.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165586
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 10 Oct 2012 01:27:09 +0000 (01:27 +0000)]
Implement MipsTargetLowering::CanLowerReturn.
Patch by Sasa Stankovic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165585
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Tue, 9 Oct 2012 23:59:01 +0000 (23:59 +0000)]
Revert "Use a special path to place the .o files in."
This reverts commit 165428 in an attempt to get our buildbots going.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165574
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Liao [Tue, 9 Oct 2012 23:48:34 +0000 (23:48 +0000)]
Add extra vim swap file pattern
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165569
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Tue, 9 Oct 2012 23:48:33 +0000 (23:48 +0000)]
When expanding atomic load arith instructions, do not lose target flags. rdar://
12453106
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165568
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Tue, 9 Oct 2012 23:44:32 +0000 (23:44 +0000)]
misched: Add computeInstrLatency to TargetSchedModel.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165566
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Tue, 9 Oct 2012 23:44:29 +0000 (23:44 +0000)]
misched: Doxument the TargetSchedule API.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165565
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Tue, 9 Oct 2012 23:44:26 +0000 (23:44 +0000)]
misched: Allow flags to disable hasInstrSchedModel/hasInstrItineraries for external users of TargetSchedule.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165564
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Tue, 9 Oct 2012 23:44:23 +0000 (23:44 +0000)]
misched: Remove LoopDependencies heuristic.
This wasn't contributing anything significant to postRA heuristics except compile time (by my measurements) and will be replaced by a more general heuristic for cross-region dependencies within the scheduler itself.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165563
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 23:40:31 +0000 (23:40 +0000)]
Use the attribute builder to add attributes to call/invoke instruction. No functionality change intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165562
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Tue, 9 Oct 2012 23:29:45 +0000 (23:29 +0000)]
Initial assembler implementation of Mips load address macro
This patch provides initial implementation of load address
macro instruction for Mips. We have implemented two kinds
of expansions with their variations depending on the size
of immediate operand:
1) load address with immediate value directly:
* la d,j => addiu d,$zero,j (for -32768 <= j <= 65535)
* la d,j => lui d,hi16(j)
ori d,d,lo16(j) (for any other 32 bit value of j)
2) load load address with register offset value
* la d,j(s) => addiu d,s,j (for -32768 <= j <= 65535)
* la d,j(s) => lui d,hi16(j) (for any other 32 bit value of j)
ori d,d,lo16(j)
addu d,d,s
This patch does not cover the case when the address is loaded
from the value of the label or function.
Contributer: Vladimir Medic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165561
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 9 Oct 2012 23:02:47 +0000 (23:02 +0000)]
Add count() method to MapVector
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165559
91177308-0d34-0410-b5e6-
96231b3b80d8
Micah Villmow [Tue, 9 Oct 2012 22:27:29 +0000 (22:27 +0000)]
Add in some interfaces that will allow easier access to the pointer address space.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165554
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 21:49:51 +0000 (21:49 +0000)]
Use the attribute enums to query if a function has an attribute.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165551
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 21:38:14 +0000 (21:38 +0000)]
Use the attribute enums to query if a parameter has an attribute.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165550
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 20:56:48 +0000 (20:56 +0000)]
Revert r165547 to fix build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165548
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 20:55:16 +0000 (20:55 +0000)]
Use a single location for calculating the alignments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165547
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Tue, 9 Oct 2012 20:39:28 +0000 (20:39 +0000)]
tblgen: Rename handleDependencies -> createDependencyFile
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165544
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 20:35:11 +0000 (20:35 +0000)]
Remove this now unused variable macro.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165543
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Tue, 9 Oct 2012 20:29:03 +0000 (20:29 +0000)]
tblgen: Move dependency file output to a separate function.
This keeps it out of the main flow of TableGenMain.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165542
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 20:28:54 +0000 (20:28 +0000)]
Use appropriate method calls to get the alignment value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165541
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Tue, 9 Oct 2012 20:15:02 +0000 (20:15 +0000)]
Whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165540
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 20:11:19 +0000 (20:11 +0000)]
Inline the checks for mutually exclusive attributes since they're used in only one module.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165539
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 9 Oct 2012 19:52:10 +0000 (19:52 +0000)]
Enable response files in all tools. Patch by Liu, Yaxun (Sam). I have simplified
the test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165535
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 19:01:18 +0000 (19:01 +0000)]
Move the 'FunctionOnly' attributes thingy inside of the Attributes class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165530
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 9 Oct 2012 17:51:56 +0000 (17:51 +0000)]
Not everyone uses C++11, apparently
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165517
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 9 Oct 2012 17:49:42 +0000 (17:49 +0000)]
Allow MapVector clients to specify the map and vector types, and add a
clear() method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165514
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Tue, 9 Oct 2012 17:05:59 +0000 (17:05 +0000)]
More descriptive, doxygen-ed comments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165512
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Tue, 9 Oct 2012 17:03:11 +0000 (17:03 +0000)]
tblgen: Remove pointless method call.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165511
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Tue, 9 Oct 2012 16:58:13 +0000 (16:58 +0000)]
New EarlyCSE tests for CSE-ing across commutativity.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165510
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Tue, 9 Oct 2012 16:57:38 +0000 (16:57 +0000)]
Update EarlyCSE's SimpleValues to use Hashing.h for their hashes. Expanded the hashing and equality to allow for equality modulo commutativity for binary ops, and comparisons with swapping of predicates.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165509
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Tue, 9 Oct 2012 16:55:14 +0000 (16:55 +0000)]
New value_op_iterator for User. This allows other code to iterate over the User's operands directly as values, which can be convenient.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165508
91177308-0d34-0410-b5e6-
96231b3b80d8
David Chisnall [Tue, 9 Oct 2012 16:27:43 +0000 (16:27 +0000)]
Improvements to MIPS64 assembler:
- Teach it about dadd[i] instructions and move pseudo-instruction
- Make it parse the register names correctly (for N32 / N64)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165506
91177308-0d34-0410-b5e6-
96231b3b80d8
Micah Villmow [Tue, 9 Oct 2012 16:06:12 +0000 (16:06 +0000)]
Add in the first step of the multiple pointer support. This adds in support to the data layout for specifying a per address space pointer size.
The next step is to update the optimizers to allow them to optimize the different address spaces with this information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165505
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Tue, 9 Oct 2012 10:34:52 +0000 (10:34 +0000)]
Fixup for r165490: Use DenseMap instead of std::map. Simplify the loop in CollectFunctionDIs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165498
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 09:51:10 +0000 (09:51 +0000)]
Move the 'ParameterOnly' variable inside of the Attributes class and make it a method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165497
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 09:33:01 +0000 (09:33 +0000)]
Remove the now dead VarArgsIncompatible variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165496
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 09:17:28 +0000 (09:17 +0000)]
Use the enum value of the attributes when removing them from the attributes builder.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165495
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 09:11:20 +0000 (09:11 +0000)]
Use the enum value of the attributes when adding them to the attributes builder.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165494
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Tue, 9 Oct 2012 08:13:15 +0000 (08:13 +0000)]
Fix PR14016.
DeadArgumentElimination pass can replace one LLVM function with another,
invalidating a pointer stored in debug info metadata entry for this function.
To fix this, we collect debug info descriptors for functions before
running a DeadArgumentElimination pass and "patch" pointers in metadata nodes
if we replace a function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165490
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 07:45:08 +0000 (07:45 +0000)]
Create enums for the different attributes.
We use the enums to query whether an Attributes object has that attribute. The
opaque layer is responsible for knowing where that specific attribute is stored.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165488
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 05:54:39 +0000 (05:54 +0000)]
Remove some dead methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165485
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 05:36:15 +0000 (05:36 +0000)]
Remove ifdef'd code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165484
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 9 Oct 2012 05:26:13 +0000 (05:26 +0000)]
Separate AVXCC and SSECC printing for cmpps/pd/ss/sd and add masking before the switch statement. This keeps the unreachable default case from being hit if the instruction was created with an intrinsic with too large of an immediate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165483
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Tue, 9 Oct 2012 05:07:18 +0000 (05:07 +0000)]
Revert r117093, "test/Makefile: Force lit -j1 on Cygwin."
lit -jN works on cygwin in most cases, but still sometimes I can see stalls with iterative run on the buildbot.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165482
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 9 Oct 2012 04:55:28 +0000 (04:55 +0000)]
In parseMSRMaskOperand, add an explicit check for the operand being an identifier instead of just having an assert.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165480
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 9 Oct 2012 04:23:49 +0000 (04:23 +0000)]
Remove some dead code from ARMAsmPrinter. Add virtual and LLVM_OVERRIDE to the other methods. Mark some of the helper methods as private.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165479
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 9 Oct 2012 03:50:37 +0000 (03:50 +0000)]
Remove some unused code in the X86AsmPrinter. Add LLVM_OVERRIDE and virtual keywords to the remaining interface methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165478
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Tue, 9 Oct 2012 01:58:35 +0000 (01:58 +0000)]
Fix PR14034, an infloop / heap corruption / crash bug in the new SROA.
Thanks to Benjamin for the raw test case. This one took about 50 times
longer to reduce than to fix. =/
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165476
91177308-0d34-0410-b5e6-
96231b3b80d8
Nadav Rotem [Tue, 9 Oct 2012 01:56:07 +0000 (01:56 +0000)]
whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165475
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Tue, 9 Oct 2012 01:47:16 +0000 (01:47 +0000)]
Move misplaced comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165474
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 01:03:48 +0000 (01:03 +0000)]
Remove a couple more 'hasAttrSomewhere' calls.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165470
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 00:51:40 +0000 (00:51 +0000)]
Fix. Apply the no capture attribute to the correct parameter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165469
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 00:47:36 +0000 (00:47 +0000)]
Convert to using the Attributes::Builder class to create attributes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165468
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 00:34:19 +0000 (00:34 +0000)]
Use an iterator and proper query method instead of the 'hasAttrSomewhere' method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165467
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 00:28:54 +0000 (00:28 +0000)]
Remove more uses of the attribute enums by supplying appropriate query methods for them.
No functionality change intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165466
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 9 Oct 2012 00:01:21 +0000 (00:01 +0000)]
Convert to using the Attributes::Builder interface.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165465
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Mon, 8 Oct 2012 23:54:10 +0000 (23:54 +0000)]
Fix typo in docs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165464
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Mon, 8 Oct 2012 23:53:45 +0000 (23:53 +0000)]
Fix up comment to be more clear.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165463
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 8 Oct 2012 23:51:19 +0000 (23:51 +0000)]
Update comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165461
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 8 Oct 2012 23:27:46 +0000 (23:27 +0000)]
Use the Attributes::Builder to build the attributes in the parser.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165458
91177308-0d34-0410-b5e6-
96231b3b80d8