summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
* Retry defaulting the virtual dtor in LoadedObjectInfoDavid Blaikie2015-06-042-3/+1
| | | | | | | | | | | | Originally committed in r237975, GCC 4.7 gave a compilation error regarding "looser throw specification" though it seemed to be pointing to a virtual defaulted dtor in a base class and an override defaulted dtor in a derived class - so I'm not quite sure why/how they could end up with different throw specifications. To simplify and reduce the risk of this, I've just removed the pointless override in the derived class, the base class's should be sufficient. *fingers crossed* llvm-svn: 239088
* [GlobalMerge] Take into account minsize on Global users' parents.Ahmed Bougacha2015-06-045-11/+113
| | | | | | | | | | Now that we can look at users, we can trivially do this: when we would have otherwise disabled GlobalMerge (currently -O<3), we can just run it for minsize functions, as it's usually a codesize win. Differential Revision: http://reviews.llvm.org/D10054 llvm-svn: 239087
* [docs] Document "LGTM" in the lexicon.Sean Silva2015-06-041-0/+4
| | | | llvm-svn: 239085
* 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
* [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
* 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
* [APInt] Remove special case for i1.Benjamin Kramer2015-06-042-3/+8
| | | | | | Add a unit test. llvm-svn: 239062
* Test commit access.Gabor Ballabas2015-06-041-1/+1
| | | | | | Fix trailing whitespace. llvm-svn: 239058
* [SDag switch lowering] Simplify code a bit. No functional change intended.Benjamin Kramer2015-06-041-10/+9
| | | | llvm-svn: 239056
* 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
* 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
* 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
* 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
* Tidy code in InstrProfiling.cpp. NFC.Diego Novillo2015-06-041-8/+8
| | | | | | | | | Removed the redundant "llvm::" from class names in InstrProfiling.cpp clang-format is ran on the changes. Patch from Betul Buyukkurt. llvm-svn: 239034
* [C API] Add LLVMStructGetTypeAtIndex.Peter Zotov2015-06-042-0/+12
| | | | | | Patch by deadalnix (Amaury SECHET). llvm-svn: 239029
* AVX-512: I brought back vector-shuffle-512-v8.ll test.Elena Demikhovsky2015-06-042-1/+1155
| | | | | | I re-generated it after all AVX-512 shuffle optimizations. llvm-svn: 239026
* [TableGen] Replace a couple if/else chains with a switch. NFCCraig Topper2015-06-041-13/+9
| | | | llvm-svn: 239023
* [TableGen] Use range-based for loops. NFCCraig Topper2015-06-041-12/+13
| | | | llvm-svn: 239022
* [TableGen] Merge single prefix bit in RecordVal into PointerIntPair with ↵Craig Topper2015-06-042-11/+10
| | | | | | Name to reduce memory usage. llvm-svn: 239021
* Test commitIgor Breger2015-06-041-0/+1
| | | | llvm-svn: 239019
* Make the test introduced in r239015 more targeted.David Majnemer2015-06-042-29/+4
| | | | | | | | We don't need to go through LSR to trigger this bug. Instead, hand-craft a tricky GEP and get the constant folder to hack on it when parsing the IR. llvm-svn: 239017
* AVX-512: added all SKX forms of VPERMW/D/Q instructions.Elena Demikhovsky2015-06-043-38/+429
| | | | | | | Added all forms of VPERMPS/PD instrcuctions. Added encoding tests. llvm-svn: 239016
* [ConstantFold] Don't skip the first gep index when folding gepsDavid Majnemer2015-06-042-3/+32
| | | | | | | | | We neglected to check if the first index made the GEP ineligible for 'inbounds'. This fixes PR23753. llvm-svn: 239015
* Removed {}, NFC.Elena Demikhovsky2015-06-041-2/+1
| | | | llvm-svn: 239014
* Bring back r239006 with a fix.Rafael Espindola2015-06-047-74/+152
| | | | | | | | | | | | | | | | | | | The fix is just that getOther had not been updated for packing the st_other values in fewer bits and could return spurious values: - unsigned Other = (getFlags() & (0x3f << ELF_STO_Shift)) >> ELF_STO_Shift; + unsigned Other = (getFlags() & (0x7 << ELF_STO_Shift)) >> ELF_STO_Shift; Original message: Pack the MCSymbolELF bit fields into MCSymbol's Flags. This reduces MCSymolfELF from 64 bytes to 56 bytes on x86_64. While at it, also make getOther/setOther easier to use by accepting unshifted STO_* values. llvm-svn: 239012
* Add testcase that would crash before the previous revert.Rafael Espindola2015-06-041-0/+21
| | | | llvm-svn: 239011
OpenPOWER on IntegriCloud