summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* MC: Remove obsolete MachO UseAggressiveSymbolFolding.Jim Grosbach2015-06-049-81/+28
| | | | | | | | | | Fix the FIXME and remove this old as(1) compat option. It was useful for bringup of the integrated assembler to diff object files, but now it's just causing more relocations than strictly necessary to be generated. rdar://21201804 llvm-svn: 239084
* Having another go at some simple cleanup from r237975/r237976David Blaikie2015-06-041-1/+0
| | | | | | | | | | | I made a few changes here in a couple of commits - breaking them out into smaller ones in case I hit the GCC oddities again. I'm still not /entirely/ sure what the issues were, so apologies if any of these experiments break things again. Feel free to revert immediately. llvm-svn: 239083
* [NVPTX] kernel pointer arguments point to the global address spaceJingyue Wu2015-06-0411-158/+215
| | | | | | | | | | | | | | | | | | | | | | | | Summary: With this patch, NVPTXLowerKernelArgs converts a kernel pointer argument to a pointer in the global address space. This change, along with NVPTXFavorNonGenericAddrSpaces, allows the NVPTX backend to emit ld.global.* and st.global.* for accessing kernel pointer arguments. Minor changes: 1. refactor: extract function convertToPointerInAddrSpace 2. fix a bug in the test case in bug21465.ll Test Plan: lower-kernel-ptr-arg.ll Reviewers: eliben, meheff, jholewinski Reviewed By: jholewinski Subscribers: wengxt, jholewinski, llvm-commits Differential Revision: http://reviews.llvm.org/D10154 llvm-svn: 239082
* [Object, MachO] Don't crash on invalid MachO segment load commands.Alexey Samsonov2015-06-044-13/+23
| | | | | | | | | | | | | | | Summary: Properly report the error in segment load commands from MachOObjectFile constructor instead of crashing the program. Adjust the test case accordingly. Test Plan: regression test suite Reviewers: rafael, filcab Subscribers: llvm-commits llvm-svn: 239081
* [Object, MachO] Don't crash on invalid MachO load commands.Alexey Samsonov2015-06-044-11/+28
| | | | | | | | | | | | | | | Summary: Currently all load commands are parsed in MachOObjectFile constructor. If the next load command cannot be parsed, or if command size is too small, properly report it through the error code and fail to construct the object, instead of crashing the program. Test Plan: regression test suite Reviewers: rafael, filcab Subscribers: llvm-commits llvm-svn: 239080
* [MC] Allowing operands to be erased from MCInst.Colin LeMahieu2015-06-041-3/+3
| | | | llvm-svn: 239079
* [Object, MachO] Don't crash on parsing invalid MachO header.Alexey Samsonov2015-06-043-4/+32
| | | | | | | | | | | Summary: Instead, properly report this error from MachOObjectFile constructor. Test Plan: regression test suite Reviewers: rafael Subscribers: llvm-commits llvm-svn: 239078
* [Object, MachO] Remove some code duplication. NFC.Alexey Samsonov2015-06-042-29/+25
| | | | llvm-svn: 239077
* [CMake] Fixing the check for NinjaChris Bieneman2015-06-041-2/+2
| | | | | | Enabling Ninja Job Pools needs to be dependent on the CMAKE_MAKE_PROGRAM not the CMAKE_GENERATOR. There are generators (like "Sublime Text 2 - Ninja") that also generate ninja build files. Basing of the CMAKE_MAKE_PROGRAM is the best future-proof way to handle this. llvm-svn: 239076
* [Object, MachO] Cache parsed MachO header in MachOObjectFile. NFC.Alexey Samsonov2015-06-042-22/+23
| | | | | | | | | | | | | | | Summary: Avoid parsing object file each time MachOObjectFile::getHeader() is called. Instead, cache the header in MachOObjectFile constructor, where it's parsed anyway. In future, we must avoid constructing the object at all if the header can't be parsed. Test Plan: regression test suite. Reviewers: rafael Subscribers: llvm-commits llvm-svn: 239075
* Fix buildbot failure on Windows by relaxing test expectations.Alexey Samsonov2015-06-041-1/+2
| | | | llvm-svn: 239074
* COFF: Add /failifmismatch option.Rui Ueyama2015-06-045-0/+56
| | | | llvm-svn: 239073
* Add comments.Rui Ueyama2015-06-041-1/+2
| | | | llvm-svn: 239072
* [bpf] add big- and host- endian supportAlexei Starovoitov2015-06-0425-72/+271
| | | | | | | | | | | | | | | | | | | Summary: -march=bpf -> host endian -march=bpf_le -> little endian -match=bpf_be -> big endian Test Plan: v1 was tested by IBM s390 guys and appears to be working there. It bit rots too fast here. Reviewers: chandlerc, tstellarAMD Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10177 llvm-svn: 239071
* [DAGCombiner] Fix wrong folding of a build_vector into a blend with zero.Andrea Di Biagio2015-06-042-3/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Method 'visitBUILD_VECTOR' in the DAGCombiner knows how to combine a build_vector of a bunch of extract_vector_elt nodes and constant zero nodes into a shuffle blend with a zero vector. However, method 'visitBUILD_VECTOR' forgot that a floating point build_vector may contain negative zero as well as positive zero. Example: define <2 x double> @example(<2 x double> %A) { entry: %0 = extractelement <2 x double> %A, i32 0 %1 = insertelement <2 x double> undef, double %0, i32 0 %2 = insertelement <2 x double> %1, double -0.0, i32 1 ret <2 x double> %2 } Before this patch, llc (with -mattr=+sse4.1) wrongly generated movq %xmm0, %xmm0 # xmm0 = xmm0[0],zero So, the sign bit of the negative zero was effectively lost. This patch fixes the problem by adding explicit checks for positive zero. With this patch, llc produces the following code for the example above: movhpd .LCPI0_0(%rip), %xmm0 where .LCPI0_0 referes to a 'double -0'. llvm-svn: 239070
* Fix the check for Ninja in the CMake build.Evgeniy Stepanov2015-06-041-2/+2
| | | | | | | | | | The current check never passes, because CMAKE_MAKE_PROGRAM, at least on Linux, includes the full path to the "ninja" binary; this effectively disables compile/link jobs pools. Use CMAKE_GENERATOR STREQUAL "Ninja" as a more reliable check. llvm-svn: 239069
* Make test case more readable: move CHECK-lines next to corresponding RUN-lines.Alexey Samsonov2015-06-041-8/+6
| | | | llvm-svn: 239068
* Fix the test to use the correct size.Rafael Espindola2015-06-041-1/+1
| | | | | | | | | | | For some reason llvm's r239045 made lld propagate data_1's size. This indicates a bug somewhere in lld. I hesitated between changing the test or just checking in a .o produced with the old llvm-mc. Since the size is now correct, it seemed better to update the test. llvm-svn: 239067
* [PowerPC] This revision adds 68 of the missing "Predefined Functions for ↵Bill Seurer2015-06-044-65/+704
| | | | | | | | | | | | Vector Programming" from appendix A of the OpenPOWER ABI for Linux Supplement document. I also added tests for the new functions and updated another test that was looking for specific line numbers in error messages from altivec.h. https://llvm.org/bugs/show_bug.cgi?id=23679 http://reviews.llvm.org/D10131 llvm-svn: 239066
* llvm-objdump: return non-zero exit code for certain cases of invalid inputAlexey Samsonov2015-06-042-7/+17
| | | | | | | | * If the input file is missing; * If the type of input object file can't be recognized; * If the object file can't be parsed correctly. llvm-svn: 239065
* C++11 rangify for loop.Yaron Keren2015-06-041-4/+2
| | | | llvm-svn: 239064
* [tsan] Disable a flaky test.Evgeniy Stepanov2015-06-041-0/+2
| | | | llvm-svn: 239063
* [APInt] Remove special case for i1.Benjamin Kramer2015-06-042-3/+8
| | | | | | Add a unit test. llvm-svn: 239062
* Use owning pointers to avoid memory leaksTobias Grosser2015-06-041-17/+10
| | | | | | This fixes a memory leak caused by us not freeing the expanded region nodes. llvm-svn: 239061
* Disable output for test case that does not need outputTobias Grosser2015-06-041-1/+1
| | | | llvm-svn: 239060
* Allow case-insensitive values for -mcpu for ARMGabor Ballabas2015-06-045-8/+21
| | | | | | | GCC allows case-insensitive values for -mcpu, -march and -mtune options. This patch implements the same behaviour for the -mcpu option. llvm-svn: 239059
* Test commit access.Gabor Ballabas2015-06-041-1/+1
| | | | | | Fix trailing whitespace. llvm-svn: 239058
* Fix some sign compare warnings.Jonathan Peyton2015-06-044-15/+10
| | | | | | | | | This change changes kmp_bstate.old_tid to sign integer instead of unsigned integer. It also defines two new macros KMP_NSEC_PER_SEC and KMP_USEC_PER_SEC which lets us take control of the sign (we want them to be longs). Also, in kmp_wait_release.h, the byteref() function's return type is changed from char to unsigned char. llvm-svn: 239057
* [SDag switch lowering] Simplify code a bit. No functional change intended.Benjamin Kramer2015-06-041-10/+9
| | | | llvm-svn: 239056
* Fix doxygen warnings.Bruce Mitchener2015-06-043-8/+8
| | | | | | | | | | | | | | Summary: Building the doxygen target presented some warnings which are now addressed by this patch. Test Plan: Ran doxygen build target and these warnings were no longer present. Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D10181 llvm-svn: 239055
* [clang-tidy] Force braces around leaf 'else if' for consistency.Samuel Benzaquen2015-06-043-5/+27
| | | | | | | | | | | | | | Summary: Force braces around leaf 'else if' for consistency. This complements r233697. Reviewers: alexfh Subscribers: curdeius, cfe-commits Differential Revision: http://reviews.llvm.org/D10245 llvm-svn: 239054
* R600/SI: Reimplement isLegalAddressingModeMatt Arsenault2015-06-043-31/+312
| | | | | | | | | | | Now that we sometimes know the address space, this can theoretically do a better job. This needs better test coverage, but this mostly depends on first updating the loop optimizatiosn to provide the address space. llvm-svn: 239053
* CodeGenPrepare: Provide address space to isLegalAddressingModeMatt Arsenault2015-06-042-27/+44
| | | | | | Use -1 as the address space if it can't be determined. llvm-svn: 239052
* Pass address space to isLegalAddressingMode in DAGCombinerMatt Arsenault2015-06-041-1/+5
| | | | | | | No test because I don't know of a target that makes use of address spaces and indexed load / store. llvm-svn: 239051
* Store ArrayShape in shared_ptr and MemAccs as actual objectsTobias Grosser2015-06-043-9/+13
| | | | | | This fixes two more memory leaks. llvm-svn: 239050
* R600/SI: Fix some cases for load / store of halfMatt Arsenault2015-06-044-43/+601
| | | | | | | Mostly argument loads were producing broken zextloads from an FP type. llvm-svn: 239049
* Switch lowering: fix assert in buildBitTests (PR23738)Hans Wennborg2015-06-042-1/+17
| | | | | | | | When checking (High - Low + 1).sle(BitWidth), BitWidth would be truncated to the size of the left-hand side. In the case of this PR, the left-hand side was i4, so BitWidth=64 got truncated to 0 and the assert failed. llvm-svn: 239048
* [SPARC] Fix multiarch path detection for sparc and sparcv9.James Y Knight2015-06-041-0/+8
| | | | llvm-svn: 239047
* [SPARC] Fix types of size_t, intptr_t, and ptrdiff_t on Linux.James Y Knight2015-06-042-17/+27
| | | | | | | | They should be 'int' instead of 'long int' everywhere else except NetBSD too, from what I gather in GCC's spec files. So, optimistically changing it for everyone else, too. llvm-svn: 239046
* Omit unused section symbols from the symbol table.Rafael Espindola2015-06-0416-147/+55
| | | | | | | | | | | | | | Section symbols exist as an optimization: instead of having multiple relocations point to different symbols, many of them can point to a single section symbol. When that optimization is unused, a section symbol is also unused and adds no extra information to the object file. This saves a bit of space on the object files and makes the output of llvm-objdump -t easier to read and consequently some tests get quite a bit simpler. llvm-svn: 239045
* [CMake] Add warning for using compile and link pools on unsupported versions ↵Chris Bieneman2015-06-041-4/+12
| | | | | | | | | | | | | | | | of CMake or non-ninja generators. Summary: I've gotten feedback from users on CMake 2.8 that the compile and link pool options were not working. This is expected so I'm adding a warning so we can report invalid configurations to users. Reviewers: eugenis Reviewed By: eugenis Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10193 llvm-svn: 239044
* Move test that depends on x86 to the x86 directory.Rafael Espindola2015-06-041-1/+1
| | | | llvm-svn: 239043
* No need to check the raw relocation bytes if checking the parsed dump.Rafael Espindola2015-06-041-6/+2
| | | | llvm-svn: 239042
* llvm-readobj can parse relocations, no need to check the raw bytes.xRafael Espindola2015-06-041-11/+7
| | | | llvm-svn: 239041
* Replace custom fixed endian to raw_ostream emission with EndianStream.Benjamin Kramer2015-06-046-99/+28
| | | | | | Less code, clearer and more efficient. No functionality change intended. llvm-svn: 239040
* Disassemble the start of sections even if there is no symbol there.Rafael Espindola2015-06-043-5/+12
| | | | | | | We already handled a section with no symbols, extend that to also handle a section with symbols that don't include the section start. llvm-svn: 239039
* Remove extraneous qualifiers due to "using namespace". NFCDouglas Katzman2015-06-042-10/+10
| | | | llvm-svn: 239038
* Don't create a MIN/MAX node if the underlying compare has more than one use.James Molloy2015-06-042-1/+16
| | | | | | | | | If the compare in a select pattern has another use then it can't be removed, so we'd just be creating repeated code if we created a min/max node. Spotted by Matt Arsenault! llvm-svn: 239037
* Replace string GNU Triples with llvm::Triple in MCAsmInfo subclasses and ↵Daniel Sanders2015-06-0432-70/+66
| | | | | | | | | | | | | | | | | | | | create*AsmInfo(). NFC. Summary: This is the first of several patches to eliminate StringRef forms of GNU triples from the internals of LLVM. After this is complete, GNU triples will be replaced by a more authoratitive representation in the form of an LLVM TargetTuple. Reviewers: rengolin Reviewed By: rengolin Subscribers: ted, llvm-commits, rengolin, jholewinski Differential Revision: http://reviews.llvm.org/D10236 llvm-svn: 239036
* Include BPF target in CMake builds.Daniel Sanders2015-06-041-0/+1
| | | | llvm-svn: 239035
OpenPOWER on IntegriCloud