Commit Graph

94196 Commits

Author SHA1 Message Date
Richard Sandiford
52b2774577 [SystemZ] Add NGRK, OGRK and XGRK
Like r186683, but for 64 bits.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186685 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:24:22 +00:00
Serge Pavlov
ebd21b30eb Initialize TempFileHandle.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186684 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:23:54 +00:00
Richard Sandiford
db92fb0716 [SystemZ] Add NRK, ORK and XRK
The atomic tests assume the two-operand forms, so I've restricted them to z10.

Running and-01.ll, or-01.ll and xor-01.ll for z196 as well as z10 shows why
using convertToThreeAddress() is better than exposing the three-operand forms
first and then converting back to two operands where possible (which is what
I'd originally tried).  Using the three-operand form first stops us from
taking advantage of NG, OG and XG for spills.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186683 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:21:55 +00:00
Tilmann Scheller
cae5d5ea65 ARM: Add instruction aliases for the Thumb2 PLD/PLDW (literal) alternate form.
See A8.8.127 in ARM DDI 0406C.b.

Related to <rdar://problem/14403733>.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186682 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:18:56 +00:00
Richard Sandiford
93c2125c39 [SystemZ] Use SLLK, SRLK and SRAK for codegen
This patch uses the instructions added in r186680 for codegen.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186681 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:12:08 +00:00
Richard Sandiford
eddfaad1ef [SystemZ] Start adding z196 and zEC12 support
This first step just adds definitions for SLLK, SRLK and SRAK.
The next patch will actually make use of them during codegen.

insn-bad.s tests that some form of error is reported when using these
instructions on z10.  More work is needed to get the "instruction requires:
distinct-ops" that we'd ideally like, so I've stubbed that part out for now.
I'll come back and make it mandatory once the necessary changes are in.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186680 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 16:09:03 +00:00
Rafael Espindola
b1a003f377 Split openFileForWrite into windows and unix versions.
It is similar to 186511, but for creating files for writing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186679 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 15:02:03 +00:00
Rafael Espindola
c9c9825c93 Add a unit test for checking that we respect the F_Binary flag.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186676 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 14:41:25 +00:00
Chandler Carruth
47042bcc26 Cleanup the stats counters for the new implementation. These actually
count the right things and have the right names.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186667 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 10:57:36 +00:00
Chandler Carruth
fbf2a02622 Fix another assert failure very similar to PR16651's test case. This
test case came from Benjamin and found the parallel bug in the vector
promotion code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186666 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 10:57:32 +00:00
Tim Northover
914bc14e7b ARM: delete two tests now integrated into the larger files
Somehow forgot to git rm these two files. I believe I left the remaining
invalid* tests intentionally, though whether my reasons were sound is a
different matter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186663 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 10:23:15 +00:00
Tim Northover
29cc13892d ARM: remove invalid invalid tests
The tests were checking for barriers which the ARM ARM says they must execute
as a full system DMB/DSB, rather than that they're UNDEFINED and LLVM does in
fact represent them.

The tests happened to be passing because they were using a non-versioned ARM
triple which didn't have *any* DMB/DSB instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186662 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 10:19:56 +00:00
Tim Northover
38c6ff6c11 Improve llvm-mc disassembler mode and refactor ARM tests to use it
This allows "llvm-mc -disassemble" to accept two new features:
  + Using comma as a byte separator
  + Grouping bytes with '[' and ']' pairs.

The behaviour outside a [...] group is unchanged. But within the group once
llvm-mc encounters a true error, it stops rather than trying to resynchronise
the stream at the next byte. This is more useful for disassembly tests, where
we have an almost-instruction in mind and don't care what the misaligned
interpretation would be. Particularly if it means llvm-mc won't actually see
the next intended almost-instruction.

As a side effect, this means llvm-mc can disassemble its own -show-encoding
output if copy-pasted.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186661 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 10:05:04 +00:00
Chandler Carruth
c09228dba3 Try to move to a more reasonable set of naming conventions given the new
implementation of the SROA algorithm. We were using the term 'partition'
in many places that no longer ever represented an actual partition, but
rather just an arbitrary slice of an alloca.

No functionality change intended here. Mostly just renaming of types,
functions, variables, and rewording of comments. Several comments were
rewritten to make a lot more sense in the new structure of things.

The stats are still weird and not reflective of how this really works.
I'll fix those up in a separate patch as it is a touch more semantic of
a change...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186659 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 09:13:58 +00:00
Alexey Samsonov
86dc6f9a79 Fix uninitialized memory read found by MemorySanitizer: always set output parameter of ConvergingScheduler::SchedBoundary::getOtherResourceCount
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186658 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 08:55:18 +00:00
Chandler Carruth
df5ed3f642 A long overdue cleanup in SROA to use 'DL' instead of 'TD' for the
DataLayout variables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186656 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 07:21:28 +00:00
Chandler Carruth
8f0a1cecc5 Fix PR16651, an assert introduced in my recent re-work of the innards of
SROA.

The crux of the issue is that now we track uses of a partition of the
alloca in two places: the iterators over the partitioning uses and the
previously collected split uses vector. We weren't accounting for the
fact that the split uses might invalidate integer widening in ways other
than due to their width (in this case due to being volatile).

Further reduced testcase added to the tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186655 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 07:12:23 +00:00
Manman Ren
98cd02622d Try to appease the bots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186653 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 04:56:51 +00:00
NAKAMURA Takumi
f8087419df llvm/test/MC/AsmParser/secure_log_unique.s: Use env(1) here. Then r186611 can be reverted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186643 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 01:26:08 +00:00
Akira Hatanaka
da218210f7 [mips] Delete MFC1_FT_CCR, MTC1_FT_CCR and MOVCCRToCCR.
No functionality change.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186642 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 01:19:52 +00:00
Eric Christopher
1fe3f9af7f Remove DIBuilder cache of variable TheCU and change the few
uses that wanted it. Also change the interface for createCompileUnit
to compensate. Fix comments that refer to TheCU as well.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186637 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 00:51:47 +00:00
Rui Ueyama
f28019e5f7 Clarify comment for extension().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186636 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 00:51:17 +00:00
Andrew Trick
8594c2377d MI Sched: test case fix for previous checkin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186635 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 00:31:31 +00:00
Manman Ren
cd26257c85 Debug Info: enable verifying by default and disable testing cases that fail.
1> Use DebugInfoFinder to find debug info MDNodes.
2> Add disable-debug-info-verifier to disable verifying debug info.
3> Disable verifying for testing cases that fail (will update the testing cases
   later on).
4> MDNodes generated by clang can have empty filename for TAG_inheritance and
   TAG_friend, so DIType::Verify is modified accordingly.

Note that DebugInfoFinder does not list all debug info MDNode.
For example, clang can generate:
metadata !{i32 786468}, which will fail to verify.
This MDNode is used by debug info but not included in DebugInfoFinder.
This MDNode is generated as a temporary node in DIBuilder::createFunction
  Value *TElts[] = { GetTagConstant(VMContext, DW_TAG_base_type) };
  MDNode::getTemporary(VMContext, TElts)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186634 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 00:31:03 +00:00
Andrew Trick
4e3898056e MI Sched: Update the way resources are tracked so the current heuristics make more sense.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186632 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-19 00:20:07 +00:00
Stephen Lin
d639206676 Fix FileCheck CHECK-LABEL documentation wording slightly; also mention that it allows error recovery.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186628 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 23:26:58 +00:00
Rui Ueyama
9d1359453f Revert "COFFDumper: Dump data directory entries."
Because it broke s390x and ppc64-linux buildbots. This reverts commit r186623.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186627 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 23:15:50 +00:00
Stephen Lin
cf2ab764db Update to more CodeGen tests to use CHECK-LABEL for labels corresponding to function definitions for more informative error messages. No functionality change.
All changes were made by the following bash script:

  find test/CodeGen -name "*.ll" | \
  while read NAME; do
    echo "$NAME"
    grep -q "^; *RUN: *llc.*debug" $NAME && continue
    grep -q "^; *RUN:.*llvm-objdump" $NAME && continue
    grep -q "^; *RUN: *opt.*" $NAME && continue
    TEMP=`mktemp -t temp`
    cp $NAME $TEMP
    sed -n "s/^define [^@]*@\([A-Za-z0-9_]*\)(.*$/\1/p" < $NAME | \
    while read FUNC; do
      sed -i '' "s/;\([A-Za-z0-9_-]*\)\([A-Za-z0-9_-]*\):\( *\)$FUNC[:]* *\$/;\1\2-LABEL:\3$FUNC:/g" $TEMP
    done
    sed -i '' "s/;\(.*\)-LABEL-LABEL:/;\1-LABEL:/" $TEMP
    sed -i '' "s/;\(.*\)-NEXT-LABEL:/;\1-NEXT:/" $TEMP
    sed -i '' "s/;\(.*\)-NOT-LABEL:/;\1-NOT:/" $TEMP
    sed -i '' "s/;\(.*\)-DAG-LABEL:/;\1-DAG:/" $TEMP
    mv $TEMP $NAME
  done

This script catches a superset of the cases caught by the script associated with commit r186280. It initially found some false positives due to unusual constructs in a minority of tests; all such cases were disambiguated first in commit r186621.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186624 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 22:47:09 +00:00
Rui Ueyama
06bd2061fc COFFDumper: Dump data directory entries.
Summary:
Dump optional data directory entries in the PE/COFF header, so that
we can test the output of LLD linker. This patch updates the test binary
file, but the source of the binary is the same. I just re-linked the file.
I don't know how the previous file was linked, but the previous file did
not have any data directory entries for some reason.

Reviewers: rafael

CC: llvm-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D1148

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186623 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 22:44:20 +00:00
Nick Lewycky
b05ad799e7 Clean up some of this code a tiny bit, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186622 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 22:32:32 +00:00
Stephen Lin
771e0ab32a Disambiguate function names in some CodeGen tests. (Some tests were using function names that also were names of instructions and/or doing other unusual things that were making the test not amenable to otherwise scriptable pattern matching.) No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186621 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 22:29:15 +00:00
Tilmann Scheller
bbcea55b68 ARM: Make sure the instruction alias for PLI uses the right subtarget features.
PLI requires both the Thumb2 and the ARMv7 feature.

Related to <rdar://problem/14403733>.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186620 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 22:19:59 +00:00
Tom Stellard
4e518fd941 R600/SI: Fix crash with VSELECT
https://bugs.freedesktop.org/show_bug.cgi?id=66175

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186616 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:43:53 +00:00
Tom Stellard
ac85f3f65c R600/SI: Add support for v2f32 loads
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186615 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:43:48 +00:00
Tom Stellard
fc047278c1 R600/SI: Add support for v2f32 stores
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186614 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:43:42 +00:00
Tom Stellard
f5660aab41 R600: Expand VSELECT for all types
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186613 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:43:35 +00:00
Hans Wennborg
9903a2513d test/MC/AsmParser/secure_log_unique.s requires shell
This should fix the chapuni bots.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186611 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:34:13 +00:00
Hans Wennborg
894fd78d93 Fix -Wdocumentation warning
s/Tokenize/Tokenizer/ to make the comment correspond to the
parameter name

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186608 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 21:00:12 +00:00
Rafael Espindola
13c9cf1d51 Add a test for .secure_log_unique.
It also doubles a test that F_Append works.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186606 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 20:34:26 +00:00
Eric Christopher
7c05da187c Revert "Remove DIBuilder cache of variable TheCU and change the few"
This reverts commit r186599 as I didn't want to commit this yet.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186601 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 19:13:06 +00:00
Eric Christopher
960d6d909b Equal means ==, not !=. Thanks to Benjamin for catching.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186600 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 19:11:41 +00:00
Eric Christopher
6abb4d2ef2 Remove DIBuilder cache of variable TheCU and change the few
uses that wanted it. Also change the interface for createCompileUnit
to compensate. Fix comments that refer to TheCU as well.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186599 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 19:11:29 +00:00
Rafael Espindola
ef69f54fec Small improvement to the use of GetFileType:
* assert that the return value is one of the documented values on msdn.
* on FILE_TYPE_UNKNOWN, check GetLastError.

Unfortunately I can't think of a way to get a FILE_TYPE_UNKNOWN on a test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186595 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 18:42:52 +00:00
Stephen Lin
be9dd85f44 Update to CodeGen tests to use CHECK-LABEL for labels corresponding to function definitions for more informative error messages. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186594 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 18:35:22 +00:00
Nadav Rotem
39f59f4d95 Handle constants without going through SCEV.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186593 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 18:34:21 +00:00
Nadav Rotem
dfacdd04cd SLPVectorizer: Speedup isConsecutive by manually checking GEPs with multiple indices.
This brings the compile time of the SLP-Vectorizer to about 2.5% of OPT for my testcase.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186592 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 18:20:45 +00:00
NAKAMURA Takumi
2cf5425d0a Windows/Path.inc: Introduce file_type::character_file and file_type::fifo_file in sys::fs::getStatus(HANDLE).
It fixes llvm/test/Other/close-stderr.ll on msys.

FIXME: Provide unittests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186588 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 17:00:54 +00:00
Reid Kleckner
431b0a7646 [Support] Beef up and expose the response file parsing in llvm::cl
The plan is to use it for clang and lld.

Major behavior changes:
- We can now parse UTF-16 files that have a byte order mark.
- PR16209: Don't drop backslashes on the floor if they don't escape
  anything.

The actual parsing loop was based on code from Clang's driver.cpp,
although it's been rewritten to track its state with control flow rather
than state variables.

Reviewers: hans

Differential Revision: http://llvm-reviews.chandlerc.com/D1170

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186587 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 16:52:05 +00:00
NAKAMURA Takumi
3ece065dd6 llvm/test/Other/close-stderr.ll: Mark this as XFAIL on msys, since r186560.
sys::fs::status() doesn't work on pipes. Investigating.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186586 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 15:38:50 +00:00
Joey Gouly
f75a964173 Forgot 'svn add' again, sorry!
Tests for r186574.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186580 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-18 13:17:26 +00:00