summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ARM / x86_64 varargs: Don't save regparms in prologue without va_startReid Kleckner2014-08-2212-7/+61
| | | | | | | | | | | | There's no need to do this if the user doesn't call va_start. In the future, we're going to have thunks that forward these register parameters with musttail calls, and they won't need these spills for handling va_start. Most of the test suite changes are adding va_start calls to existing tests to keep things working. llvm-svn: 216294
* Clear the clang release notes to make room for 3.6.Rafael Espindola2014-08-221-80/+11
| | | | llvm-svn: 216293
* Clear the llvm release notes to make room for 3.6.Rafael Espindola2014-08-221-153/+11
| | | | llvm-svn: 216292
* DebugInfo: Provide scopes for C++11 range-for loop variables similar to ↵David Blaikie2014-08-222-10/+11
| | | | | | r216288 (which was for plain-for loop condition variables). llvm-svn: 216291
* [UBSan] Add support for printing backtraces to all UBSan handlersAlexey Samsonov2014-08-227-73/+112
| | | | llvm-svn: 216289
* DebugInfo: Scope for condition variables more narrowly than the loop variable.David Blaikie2014-08-223-32/+40
| | | | | | | | for loops introduce two scopes - one for the outer loop variable and its initialization, and another for the body of the loop, including any variable declared inside the loop condition. llvm-svn: 216288
* Fix a CMake error when using CMake 3.0.1Zachary Turner2014-08-221-5/+1
| | | | llvm-svn: 216286
* Add the start of the support for llvm-objdump’s -private-headers for ↵Kevin Enderby2014-08-225-0/+302
| | | | | | | | Mach-O files. This adds the printing of the mach header. Load command printing will be next. llvm-svn: 216285
* Add a few missing mach header flags.Kevin Enderby2014-08-221-1/+4
| | | | llvm-svn: 216284
* Ignore -Wunsupported-dll-base-class-template by defaultHans Wennborg2014-08-223-9/+9
| | | | | | | | The situation it is warning about (see PR20725) is not very likely to be a real problem, and it is unclear what action the user should take if the warning does fire. llvm-svn: 216283
* Objective-C. Update my previous patch to not warn ifFariborz Jahanian2014-08-222-3/+6
| | | | | | | +initialize is called on 'super' in its implementation. rdar://16628028 llvm-svn: 216282
* Fix PR17239 by changing the semantics of the RemainingArgsClass Option kindReid Kleckner2014-08-225-4/+60
| | | | | | | | | | | | | | | | | | | | | | | This patch aims at fixing PR17239. This bug happens because the /link (clang-cl.exe argument) is marked as "consume all remaining arguments". However, when inside a response file, /link should only consume all remaining arguments inside the response file where it is located, not the entire command line after expansion. The LLVM side of the patch will change the semantics of the RemainingArgsClass kind to always consume only until the end of the response file when the option originally came from a response file. There are only two options in this class: dash dash (--) and /link. This is the Clang side of the patch in http://reviews.llvm.org/D4899 Reviewered By: rafael, rnk Differential Revision: http://reviews.llvm.org/D4900 Patch by Rafael Auler! llvm-svn: 216281
* Fix PR17239 by changing the semantics of the RemainingArgsClass Option kindReid Kleckner2014-08-225-20/+70
| | | | | | | | | | | | | | | | | | | | | | | This patch contains the LLVM side of the fix of PR17239. This bug that happens because the /link (clang-cl.exe argument) is marked as "consume all remaining arguments". However, when inside a response file, /link should only consume all remaining arguments inside the response file where it is located, not the entire command line after expansion. My patch will change the semantics of the RemainingArgsClass kind to always consume only until the end of the response file when the option originally came from a response file. There are only two options in this class: dash dash (--) and /link. Reviewed By: rnk Differential Revision: http://reviews.llvm.org/D4899 Patch by Rafael Auler! llvm-svn: 216280
* R600/SI: Use READ2/WRITE2 instructions for 64-bit mem ops with 32-bit alignmentTom Stellard2014-08-225-4/+116
| | | | llvm-svn: 216279
* R600/SI: Use a ComplexPattern for DS loads and storesTom Stellard2014-08-228-120/+169
| | | | llvm-svn: 216278
* R600/SI: Wrap local memory pointer in AssertZExt on SITom Stellard2014-08-221-0/+12
| | | | | | | | | These pointers are really just offsets and they will always be less than 16-bits. Using AssertZExt allows us to use computeKnownBits to prove that these values are positive. We will use this information in a later commit. llvm-svn: 216277
* R600/SI: Use correct helper class for DS_WRITE2 instructionsTom Stellard2014-08-221-1/+1
| | | | | | | DS_1A uses a single offset encoding, so offset1 wasn't being encoded. llvm-svn: 216276
* [test/CodeGen/ARM] Adpat test to match new codegen after r216274.Quentin Colombet2014-08-221-29/+29
| | | | | | | | | | | Moreover, rework some patterns to actually check the emitted instructions instead of matching unrelated string! E.g., some of the "// CHECK: vmov" were matching stuff like ".globl funcname_with_vmov" instead of actual instructions. llvm-svn: 216275
* [ARM] Move the implementation of the target hooks related to copy-relatedQuentin Colombet2014-08-225-116/+118
| | | | | | | | | instruction from ARMInstrInfo to ARMBaseInstrInfo. That way, thumb mode can also benefit from the advanced copy optimization. <rdar://problem/12702965> llvm-svn: 216274
* InstCombine: Don't unconditionally preserve 'nuw' when shrinking constantsDavid Majnemer2014-08-222-6/+24
| | | | | | | | | | | | Consider: %add = add nuw i32 %a, -16777216 %and = and i32 %add, 255 Regardless of whether or not we demand the sign bit of %add, we cannot replace -16777216 with 2130706432 without also removing 'nuw' from the instruction. llvm-svn: 216273
* [analyzer] Remove check covered by -Wobjc-missing-super-calls.Jordan Rose2014-08-221-39/+0
| | | | | | | | | The ObjCDealloc checker is currently disabled because it was too aggressive, but this is a good first step in getting it back to a useful state. Patch by David Kilzer! llvm-svn: 216272
* Objective-C. Warn if user has made explicit callFariborz Jahanian2014-08-228-0/+47
| | | | | | | to +initilize as this results in an extra call to this method. rdar://16628028 llvm-svn: 216271
* -fms-extensions: Alias _intNN to __intNNReid Kleckner2014-08-222-0/+9
| | | | | | | | | | Fixes build for SPEC 2000 CPU. MSVC disables these aliases under /Za, which enables stricter standards compliance. We don't currently have any way to disable them. Patch by Kevin Smith! llvm-svn: 216270
* InstCombine: sub nsw %x, C -> add nsw %x, -C if C isn't INT_MINDavid Majnemer2014-08-224-1/+38
| | | | | | We can preserve nsw during this transform if -C won't overflow. llvm-svn: 216269
* [Support] Fix the overflow bug in ULEB128 decoding.Alex Lorenz2014-08-222-1/+2
| | | | | | Differential Revision: http://reviews.llvm.org/D5029 llvm-svn: 216268
* Fixing MSVC warning: "warning C4373: 'blah': virtual function overrides ↵Aaron Ballman2014-08-221-4/+2
| | | | | | | | 'blah', previous versions of the compiler did not override when parameters only differed by const/volatile qualifiers." This warning is basically useless because the "previous versions" being referred to is MSVC 2005 and earlier, and we obviously do not care about them. However, this warning isn't particularly chatty (I don't recall ever seeing it previously), and it has the opportunity to point out cases where the cv-qualifiers differ unintentionally (like this case), so I am leaving it enabled for now. llvm-svn: 216267
* [ubsan] Follow-up for r216263: fix the expected line number.Alexander Potapenko2014-08-221-1/+1
| | | | llvm-svn: 216266
* [ASan/Win] Land the trivial bits of -MD RTL support (PR20214)Timur Iskhodzhanov2014-08-225-10/+11
| | | | llvm-svn: 216265
* [ASan] Use check_library_exists to determine if libc/libstdc++ are availableTimur Iskhodzhanov2014-08-222-3/+7
| | | | llvm-svn: 216264
* [ubsan] Do not run Function/function.cpp on Darwin where -fsanitize=function ↵Alexander Potapenko2014-08-221-0/+3
| | | | | | is not supported. llvm-svn: 216263
* [mips] Don't use odd-numbered float registers for double arguments for fastccSasa Stankovic2014-08-222-2/+88
| | | | | | | | calling convention if FP is 64-bit and +nooddspreg is used. Differential Revision: http://reviews.llvm.org/D4981.diff llvm-svn: 216262
* InstCombine: Don't unconditionally preserve 'nsw' when shrinking constantsDavid Majnemer2014-08-222-1/+21
| | | | | | | | | | | | | | Consider: %add = add nsw i32 %a, -16777216 %and = and i32 %add, 255 Regardless of whether or not we demand the sign bit of %add, we cannot replace -16777216 with 2130706432 without also removing 'nsw' from the instruction. This fixes PR20377. llvm-svn: 216261
* [AArch64, inline-asm] Improve diagnostic that is printed when the size of aAkira Hatanaka2014-08-229-28/+128
| | | | | | | | | | | | | | | | | variable that has regiser constraint "r" is not 64-bit. General register operands are output using 64-bit "x" register names, regardless of the size of the variable, unless the asm operand is prefixed with the "%w" modifier. This surprises and confuses many users who aren't familiar with aarch64 inline assembly rules. With this commit, a note and fixit hint are printed which tell the users that they need modifier "%w" in order to output a "w" register instead of an "x" register. <rdar://problem/12764785> llvm-svn: 216260
* MS ABI: Don't use the Itanium scheme for numbering lambdasDavid Majnemer2014-08-226-56/+85
| | | | | | | | | | | The Itanium ABI will give out the same mangling number for two different lambdas if their call operators have different types. The MS ABI cannot do the same because it does not mangle the return type into it's lambdas. This fixes PR20719. llvm-svn: 216259
* When adding a dSYM to an existing ObjectFile, we can have a situationJason Molenda2014-08-229-0/+91
| | | | | | | | | | | | | | | | | | with binaries in the dyld shared cache (esp on iOS) where the file address for the executable binary (maybe from memory, maybe from an expanded copy of the dyld shared cache) is different from the file address in the dSYM. In that case, ObjectFileMachO replaces the file addresses from the original binary with the dSYM file addresses (usually 0-based) -- lldb doesn't have a notion of two file addresses for a given module so they need to agree. There was a cache of file addresses over in the Symtab so I added a method to the Module and the objects within to clear any file address caches if they exist, and added an implementation in the Symtab module to do that. <rdar://problem/16929569> llvm-svn: 216258
* Simplify. No functionality changes.Rui Ueyama2014-08-221-6/+3
| | | | llvm-svn: 216257
* fix: SLPVectorizer crashes for unreachable blocks containing not schedulable ↵Erik Eckstein2014-08-222-0/+48
| | | | | | | | | | | | instructions. In unreachable blocks it's legal to have instructions like "%x = op %x". Such instuctions are not schedulable. Therefore the SLPVectorizer has to check for unreachable blocks and ignore them. Fixes bug 20646. llvm-svn: 216256
* [dfsan] Fix non-determinism bug in non-zero label check annotator.Peter Collingbourne2014-08-222-15/+16
| | | | | | | We now use a std::vector instead of a DenseSet to store the list of label checks so that we can iterate over it deterministically. llvm-svn: 216255
* Fix PR20705, crash on invalid.Richard Trieu2014-08-222-1/+22
| | | | | | dyn_cast -> dyn_cast_or_null to handle a null pointer. llvm-svn: 216254
* [PECOFF] Fix PE+ relocationsRui Ueyama2014-08-2219-58/+279
| | | | | | | | | | | | | The implementation of AMD64 relocations was imcomplete and wrong. On AMD64, we of course have to use AMD64 relocations instead of i386 ones. This patch fixes the issue. LLD is now able to link hello64.obj (created from hello64.asm) against user32.lib and kernel32.lib to create a Win64 binary. llvm-svn: 216253
* Fix build after r216223: Explicitly pass ownership of the MemoryBuffer to ↵Hans Wennborg2014-08-222-2/+2
| | | | | | AddNewSourceBuffer using std::unique_ptr llvm-svn: 216252
* CGCall: Factor out the logic mapping call arguments to LLVM IR arguments.Alexey Samsonov2014-08-222-235/+323
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This refactoring introduces ClangToLLVMArgMapping class, which encapsulates the information about the order in which function arguments listed in CGFunctionInfo should be passed to actual LLVM IR function, such as: 1) positions of sret, if there is any 2) position of inalloca argument, if there is any 3) position of helper padding argument for each call argument 4) positions of regular argument (there can be many if it's expanded). Simplify several related methods (ConstructAttributeList, EmitFunctionProlog and EmitCall): now they don't have to maintain iterators over the list of LLVM IR function arguments, dealing with all the sret/inalloca/this complexities, and just use expected positions of LLVM IR arguments stored in ClangToLLVMArgMapping. This may increase the running time of EmitFunctionProlog, as we have to traverse expandable arguments twice, but in further refactoring we will be able to speed up EmitCall by passing already calculated CallArgsToIRArgsMapping to ConstructAttributeList, thus avoiding traversing expandable argument there. No functionality change. Test Plan: regression test suite Reviewers: majnemer, rnk Reviewed By: rnk Subscribers: cfe-commits, rjmccall, timurrrr Differential Revision: http://reviews.llvm.org/D4938 llvm-svn: 216251
* ValueTracking: Figure out more bits when looking at add/subDavid Majnemer2014-08-222-66/+51
| | | | | | | | | Given something like X01XX + X01XX, we know that the result must look like X1XXX. Adapted from a patch by Richard Smith, test-case written by me. llvm-svn: 216250
* [test/CodeGen/ARM] Adpat test to match new codegen after r216236.Quentin Colombet2014-08-221-9/+9
| | | | llvm-svn: 216249
* SROA: Handle a case of store size being smaller than allocation sizeReid Kleckner2014-08-222-5/+54
| | | | | | | | | | | | | | | | In this case, we are creating an x86_fp80 slice for a union from C where the padding bytes may contain real data. An x86_fp80 alloca is 16 bytes, and that's just fine. We can't, however, use regular loads and stores to access the slice, because the store size is only 10 bytes / 80 bits. Instead, use memcpy and memset. Fixes PR18726. Reviewed By: chandlerc Differential Revision: http://reviews.llvm.org/D5012 llvm-svn: 216248
* Fixes a few more places where we were manually setting the filename.Zachary Turner2014-08-213-3/+3
| | | | llvm-svn: 216247
* Revert "X86: Align the stack on word boundaries in LowerFormalArguments()"Duncan P. N. Exon Smith2014-08-212-8/+2
| | | | | | | | | | | | | This (mostly) reverts commit r216119. Somewhere during the review Reid committed r214980 which fixed this another way, and I neglected to check that the testcase still failed before committing. I've left test/CodeGen/X86/aligned-variadic.ll around in case it adds extra coverage. llvm-svn: 216246
* Bump the verison number in the xcode project files.Jason Molenda2014-08-215-35/+35
| | | | llvm-svn: 216245
* Add an explicit move constructor to SrcBufferReid Kleckner2014-08-211-0/+5
| | | | | | | MSVC can't synthesize the explicit one. Instead it tries to emit a copy ctor which would call the deleted copy ctor of unique_ptr. llvm-svn: 216244
* Two small fixes to get Mac native + debugserver working after theJason Molenda2014-08-212-3/+3
| | | | | | | HostInfo et al changes from Zachary. Changes suggested by Zachary - fixes the problems I was seeing. llvm-svn: 216243
OpenPOWER on IntegriCloud