summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
...
* Update the MemoryBuffer API to use ErrorOr.Rafael Espindola2014-07-0635-280/+297
| | | | llvm-svn: 212405
* Declare variable on first use.Rafael Espindola2014-07-061-5/+5
| | | | llvm-svn: 212403
* This only needs a StringRef.Rafael Espindola2014-07-062-11/+11
| | | | llvm-svn: 212402
* This only needs a StringRef.Rafael Espindola2014-07-064-19/+17
| | | | llvm-svn: 212401
* Fix the MSVC build following r212382Alp Toker2014-07-061-2/+4
| | | | | | Looks like the casts are needed there after all. llvm-svn: 212399
* SourceMgr: make valid buffer IDs start from oneAlp Toker2014-07-0610-64/+73
| | | | | | | | | | Use 0 for the invalid buffer instead of -1/~0 and switch to unsigned representation to enable more idiomatic usage. Also introduce a trivial SourceMgr::getMainFileID() instead of hard-coding 0/1 to identify the main file. llvm-svn: 212398
* Don't use StringRef iterator functions for data accessAlp Toker2014-07-061-4/+3
| | | | | | And also remove some redundant casts from r212371. llvm-svn: 212397
* Remove IntrusiveRefCntPtr::getPtr() functionAlp Toker2014-07-051-3/+0
| | | | | | It was deprecated in r212366 and all uses have been switched to get(). llvm-svn: 212382
* Use cast<> instead of dyn_cast + assertMatt Arsenault2014-07-051-2/+1
| | | | llvm-svn: 212380
* Fix grammarMatt Arsenault2014-07-051-1/+1
| | | | llvm-svn: 212379
* ARM: mark matching ARM intrinsics as MSBuiltinSaleem Abdulrasool2014-07-051-3/+10
| | | | | | | | | | | | A number of the ARM intrinsics are aliased with alternative names in MSVC compatibility mode. This change indicates those intrinsics to permit tablegen to construct an appropriate list of MSBuiltins. With the corresponding change in clang, these intrinsics can then be mapped from the frontend. The tests to validate the intrinsics are aliased correctly will be added with the corresponding clang change. llvm-svn: 212377
* Revert r212375 because of test failuresEhsan Akhgari2014-07-051-4/+0
| | | | llvm-svn: 212376
* Add a test case for the tilde operator in Microsoft inline assemblyEhsan Akhgari2014-07-051-0/+4
| | | | llvm-svn: 212375
* [llvm-readobj] Fix output of MIPS GOT without local and global entries.Simon Atanasyan2014-07-053-1/+26
| | | | llvm-svn: 212374
* This only needs a StringRef. No functionality change.Rafael Espindola2014-07-053-12/+13
| | | | llvm-svn: 212371
* ADT: Add a drop_back() helper to ArrayRefDavid Majnemer2014-07-052-0/+13
| | | | | | | | The slice(N, M) interface is powerful but not concise when wanting to drop a few elements off of an ArrayRef, fix this by adding a drop_back method. llvm-svn: 212370
* Deprecate IntrusiveRefCntPtr::getPtr() in favour of get()Alp Toker2014-07-051-10/+13
| | | | | | | | | | | This better aligns with other LLVM-specific and C++ standard library smart pointer types. In particular there are at least a few uses of intrusive refcounting in the frontend where it's worth investigating std::shared_ptr as a more appropriate alternative. llvm-svn: 212366
* MC: make MCSymbolData::dump work on const objectsDavid Majnemer2014-07-052-2/+2
| | | | | | | This just lets us dump a const MCSymbolData object, no functionality changed. llvm-svn: 212365
* Make a helper function static. No functionality change.Rafael Espindola2014-07-052-10/+2
| | | | llvm-svn: 212364
* MC: Correct comment in ExportSymbolDavid Majnemer2014-07-041-1/+1
| | | | | | | No functionality changed, just make it so that the code _could_ be uncommented. llvm-svn: 212363
* MC: Cleanup COFFAsmParser::ParseSectionFlagsDavid Majnemer2014-07-041-2/+2
| | | | | | Switch a normal for-loop to a range-based for. No functionality changed. llvm-svn: 212362
* Make RecordStreamer.h private.Rafael Espindola2014-07-043-3/+3
| | | | llvm-svn: 212361
* IR: Fold away compares between GV GEPs and GVsDavid Majnemer2014-07-045-16/+44
| | | | | | | | | A GEP of a non-weak global variable will not be equivalent to another non-weak global variable or a GEP of such a variable. Differential Revision: http://reviews.llvm.org/D4238 llvm-svn: 212360
* Fix a bug in the conversion to ErrorOr.Rafael Espindola2014-07-041-2/+2
| | | | | | | | | The regular end of the bitcode parsing is in the BitstreamEntry::EndBlock case. Should fix the LTO bootstrap on OS X (this function is only used by ld64). llvm-svn: 212357
* Revert "Convert a few std::strings to StringRef."Rafael Espindola2014-07-044-29/+17
| | | | | | | | | This reverts commit r212342. We can get a StringRef into the current Record, but not one in the bitcode itself since the string is compressed in it. llvm-svn: 212356
* fixed typosSanjay Patel2014-07-041-2/+2
| | | | llvm-svn: 212355
* Ignore llvm specific symbols in the LTOModule.Rafael Espindola2014-07-041-0/+3
| | | | | | | | | | These are the llvm.* globals and functions. I don't think it is possible to test this directly since llvm-lto is not a full linker and will not report duplicated symbols, but this fixes bootstrap with gold and lto enabled. llvm-svn: 212354
* Add support for parsing the not operator in Microsoft inline assemblyEhsan Akhgari2014-07-041-5/+36
| | | | | | This fixes http://llvm.org/PR20202 llvm-svn: 212352
* Ignore llvm.* globals.Rafael Espindola2014-07-042-6/+4
| | | | | | | It is not clear if llvm.global_ctors should or should not be in llvm.metadata, but in practice it is not and we need to ignore it for LTO. llvm-svn: 212351
* TableGen: introduce support for MSBuiltinSaleem Abdulrasool2014-07-046-0/+69
| | | | | | | | | | | | | Add MSBuiltin which is similar in vein to GCCBuiltin. This allows for adding intrinsics for Microsoft compatibility to individual instructions. This is needed to permit the creation of ARM specific MSVC extensions. This is not currently in use, and requires an associated change in clang to enable use of the intrinsics defined by this new class. This merely sets the LLVM portion of the infrastructure in place to permit the use of this functionality. A separate set of changes will enable the new intrinsics. llvm-svn: 212350
* Implement LTOModule on top of IRObjectFile.Rafael Espindola2014-07-045-168/+117
| | | | | | | | | | | | | IRObjectFile provides all the logic for producing mangled names and getting symbols from inline assembly. LTOModule then adds logic for linking specific tasks, like constructing llvm.compiler_user or extracting linker options from the bitcode. The rule of the thumb is that IRObjectFile has the functionality that is needed by both LTO and llvm-ar. llvm-svn: 212349
* Avoid mangling names twice. No functionality change.Rafael Espindola2014-07-042-19/+28
| | | | llvm-svn: 212348
* Mark intrinsic functions as llvm-specific.Rafael Espindola2014-07-042-0/+11
| | | | llvm-svn: 212347
* [mips][mips64r6] Set ELF e_flags for MIPS32r6/MIPS64r6. Also do MIPS-I to MIPS-VDaniel Sanders2014-07-042-1/+49
| | | | | | Differential Revision: http://reviews.llvm.org/D4386 llvm-svn: 212346
* [mips] Add tests for the 'ret', 'call', and 'indirectbr' LLVM IR instruction.Daniel Sanders2014-07-043-0/+353
| | | | | | | | | | | | | | | | | | | | | Summary: The tests in this directory are intended to test a single IR instruction with as few dependencies on other instructions as possible. The aim is to be very confident that each LLVM-IR instruction is implemented correctly and with the optimal sequence of instructions, as well as to make it easy to tell what is tested, and make it easier to bring up new ISA revisions in the future. This gives us a good foundation on which to test bigger things. These particular tests will allow testing that MIPS32r6/MIPS64r6 generate the correct return instruction for returns, calls, and indirect branches. This will be a bit tricky since the assembly text is identical but the instruction is actually different. On MIPS32r6/MIPS64r6 'jr $rs' has been removed in favour of the equivalent 'jalr $zero, $rs'. 'jr $rs' remains as an alias for 'jalr $zero, $rs'. Differential Revision: http://reviews.llvm.org/D4266 llvm-svn: 212345
* Don't include llvm.metadata variables in archive symbol tables.Rafael Espindola2014-07-043-0/+9
| | | | llvm-svn: 212344
* Change LTOModule`s getTargetTriple and setTargetTriple to use c++ types.Rafael Espindola2014-07-042-5/+5
| | | | llvm-svn: 212343
* Convert a few std::strings to StringRef.Rafael Espindola2014-07-044-17/+29
| | | | llvm-svn: 212342
* Convert these functions to use ErrorOr.Rafael Espindola2014-07-042-10/+11
| | | | llvm-svn: 212341
* Remove unused old-style error handling.Rafael Espindola2014-07-042-12/+6
| | | | | | If needed, an ErrorOr should be used. llvm-svn: 212340
* GlobalDCE: Delete available_externally initializers if it allows removing ↵Benjamin Kramer2014-07-042-4/+74
| | | | | | | | | | | | the value the initializer is referring to. This is useful for functions that are not actually available externally but referenced by a vtable of some kind. Clang emits functions like this for the MS ABI. PR20182. llvm-svn: 212337
* llvm/test/CodeGen/XCore/dwarf_debug.ll: Fix not to be affected by *-win32.NAKAMURA Takumi2014-07-041-1/+1
| | | | llvm-svn: 212335
* llvm/test/CodeGen/X86/vector-gep.ll: Appease to add -mtriple=i686-linux.NAKAMURA Takumi2014-07-041-1/+1
| | | | | | This doesn't pass if stack alignment is not 16, like cygming, *bsd. llvm-svn: 212334
* ARM: when falling back to scattered relocs, keep the type.Tim Northover2014-07-042-3/+41
| | | | | | | | | | The linker relies on relocation type info (e.g. is it a branch?) to perform the correct actions, so we should keep that even when we end up using a scattered relocation for whatever reason. rdar://problem/17553104 llvm-svn: 212333
* llvm-readobj: fix MachO relocatoin printing a bit.Tim Northover2014-07-047-73/+88
| | | | | | | | | | | | | | | | There were two issues here: 1. At the very least, scattered relocations cannot use the same code to determine the corresponding symbol being referred to. For some reason we pretend there is no symbol, even when one actually exists in the symtab, so to match this behaviour getRelocationSymbol should simply return symbols_end for scattered relocations. 2. Printing "-" when we can't get a symbol (including the scattered case, but not exclusively), isn't that helpful. In both cases there *is* interesting information in that field, so we should print it. As hex will do. Small part of rdar://problem/17553104 llvm-svn: 212332
* InstCombine: Strength reduce sadd.with.overflow into a regular nsw add if we ↵Benjamin Kramer2014-07-042-0/+28
| | | | | | | | can prove that it cannot overflow. PR20194 llvm-svn: 212331
* [mips][mips64r6] Correct the encoding of dmuh, dmuhu, dmul, and dmulu.Daniel Sanders2014-07-043-12/+12
| | | | | | | | We have detected a documentation bug in the encoding tables of the released MIPS64r6 specification that has resulted in the wrong encodings being used for these instructions in LLVM. This commit corrects them. llvm-svn: 212330
* Phabricator doc: Explicit the fact that the patch needs to be there before ↵Sylvestre Ledru2014-07-041-0/+1
| | | | | | the commit llvm-svn: 212328
* [x86] Relax the line in this check to pacify build bots.Chandler Carruth2014-07-041-1/+1
| | | | | | | I still don't love testing the comments, but its the only sane way to check shuffle instructions... llvm-svn: 212326
* [x86] Move some check lines to be slightly easier for me to find.Chandler Carruth2014-07-041-2/+2
| | | | | | (meant to put this cleanup in the previous patch, sorry) llvm-svn: 212325
OpenPOWER on IntegriCloud