summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [tsan] Add support for dispatch event sourcesKuba Brecka2016-04-077-0/+286
| | | | | | | | GCD has APIs for event sources, we need some more release-acquire pairs to avoid false positives in TSan. Differential Revision: http://reviews.llvm.org/D18515 llvm-svn: 265660
* [tsan] Fix synchronization in dispatch_syncKuba Brecka2016-04-072-24/+96
| | | | | | | | In the interceptor for dispatch_sync, we're currently missing synchronization between the callback and the code *after* the call to dispatch_sync. This patch fixes this by adding an extra release+acquire pair to dispatch_sync() and similar APIs. Added a testcase. Differential Revision: http://reviews.llvm.org/D18502 llvm-svn: 265659
* [tsan] Fix Darwin tests (missing FileCheck's)Kuba Brecka2016-04-0711-16/+16
| | | | | | | | A little embarrassing, but we're missing the call to FileCheck in several Darwin tests. Let's fix this. Differential Revision: http://reviews.llvm.org/D18503 llvm-svn: 265658
* InlineSpiller.cpp: Escap \@ in r265547. [-Wdocumentation]NAKAMURA Takumi2016-04-071-1/+1
| | | | llvm-svn: 265657
* Enabling AddressSanitizer tests, they should pass now (and this time I mean it).Kuba Brecka2016-04-072-2/+0
| | | | llvm-svn: 265656
* [docs] Update version (http://llvm.org/PR27253)Alexander Kornienko2016-04-071-2/+2
| | | | llvm-svn: 265655
* Move class into an anonymous namespace. NFC.Benjamin Kramer2016-04-071-0/+2
| | | | llvm-svn: 265654
* Make helper functions static. NFC.Benjamin Kramer2016-04-072-15/+11
| | | | llvm-svn: 265653
* Simplify the ASan expression (follow-up for the previous commit, r265651).Kuba Brecka2016-04-071-2/+2
| | | | llvm-svn: 265652
* Tentative fix (add `extern "C"` declarations to expression prefix) and ↵Kuba Brecka2016-04-072-40/+70
| | | | | | printing evaluation errors for AddressSanitizer (both MemoryHistoryASan.cpp and AddressSanitizerRuntime.cpp). Hopefully this will make the ASan testcases pass or at least the failure should be easier to diagnose. llvm-svn: 265651
* Enable TestDebugBreak on x86_64 as wellPavel Labath2016-04-071-1/+1
| | | | | | Test passes there, and this would have helped me catch the snafu in the previous commit. llvm-svn: 265650
* fix r265645: target dependent printf formatting flags.Valery Pykhtin2016-04-071-2/+2
| | | | llvm-svn: 265649
* [CMake] Check for sys/types.h in config-ix.cmakeJeroen Ketema2016-04-071-0/+1
| | | | | | | | | `sys/types.h` has a related define in `config.h.cmake`, but was never checked for in CMake. Sync this. Differential Revision: http://reviews.llvm.org/D18825 llvm-svn: 265648
* Revert "Reduce code duplication in ProcessGDBRemote"Pavel Labath2016-04-072-20/+39
| | | | | | | In turns out this does make a functional change, in case when the inferior hits an int3 that was not placed by the debugger. Backing out for now. llvm-svn: 265647
* [X86][SSE] Add support for VZEXT constant foldingSimon Pilgrim2016-04-074-6/+21
| | | | llvm-svn: 265646
* [AMDGPU] llvm-objdump: Minimal HSA Code Object disassembler support.Valery Pykhtin2016-04-073-0/+120
| | | | | | | | | | | | Reenable reverted r265550 with endianness issue fixed. Variables of endian-aware types such as ulittle32_t should be explicitly casted to their natural equivalent types before passing it as vararg to printf like functions (format in my case). Added lit config file depending on AMDGPU target as the testcase uses assembler. Differential revision: http://reviews.llvm.org/D16998 llvm-svn: 265645
* Symbol: fix buildSaleem Abdulrasool2016-04-071-2/+2
| | | | | | | TargetOptions is ambiguous due to a definition in LLVM and in clang. This was exposed by SVN r265640. Update to fix the build against the newer revision. llvm-svn: 265644
* [BlockPlacement] Remove an unnecessary continueAmaury Sechet2016-04-071-1/+0
| | | | | | NFC. llvm-svn: 265643
* [MBP] Remove an unused function parameterAmaury Sechet2016-04-071-5/+3
| | | | | | NFC. llvm-svn: 265642
* Do some refactoring in the LLVM C API echo test to remove duplication. NFCAmaury Sechet2016-04-071-70/+85
| | | | llvm-svn: 265641
* Basic: thread CodeGenOptions into TargetInfoSaleem Abdulrasool2016-04-077-300/+376
| | | | | | | | | This threads CodeGenOptions into the TargetInfo hierarchy. This is motivated by ARM which can change some target information based on the EABI selected (-meabi). Similar options exist for other platforms (e.g. MIPS) and thus is generally useful. NFC. llvm-svn: 265640
* Fix the sanitizer bootstrap error in r265547.Wei Mi2016-04-071-1/+8
| | | | | | | | | The iterators of SmallPtrSet SpillsInSubTreeMap[Child].first may be invalidated when SpillsInSubTreeMap grows. Rearrange the code to ensure the grow of SpillsInSubTreeMap only happens before getting the iterators of the SmallPtrSet. llvm-svn: 265639
* Revert "[BlockPlacement] Remove an unnecessary continue" and "[MBP] Remove ↵Amaury Sechet2016-04-071-3/+6
| | | | | | an unused function parameter" llvm-svn: 265638
* Revert "ValueMapper: Make LocalAsMetadata match function-local Values"Duncan P. N. Exon Smith2016-04-072-120/+16
| | | | | | | | | | | This reverts commit r265631, since it caused bot failures: http://lab.llvm.org:8011/builders/clang-ppc64be-linux/builds/3256 http://lab.llvm.org:8011/builders/clang-cmake-aarch64-42vma/builds/7272 Looks like something is depending on the old behaviour. I'll try to track it down and recommit. llvm-svn: 265637
* [X86] Reuse EFLAGS and form LOCKed ops when only user is SETCC.Ahmed Bougacha2016-04-072-39/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Re-apply r265450 which caused PR27245 and was reverted in r265559 because of a wrong generalization: the fetch_and_add->add_and_fetch combine only works in specific, but pretty common, cases: (icmp slt x, 0) -> (icmp sle (add x, 1), 0) (icmp sge x, 0) -> (icmp sgt (add x, 1), 0) (icmp sle x, 0) -> (icmp slt (sub x, 1), 0) (icmp sgt x, 0) -> (icmp sge (sub x, 1), 0) Original Message: We only generate LOCKed versions of add/sub when the result is unused. It often happens that the result is used, but only by a comparison. We can optimize those out by reusing EFLAGS, which lets us use the proper instructions, instead of having to fallback to LXADD. Instead of doing this as an MI peephole (as we do for the other non-LOCKed (really, non-MR) forms), do it in ISel. It becomes quite tricky later. This also makes it eventually possible to stop expanding and/or/xor if the only user is an icmp (also see D18141). This uses the LOCK ISD opcodes added by r262244. Differential Revision: http://reviews.llvm.org/D17633 llvm-svn: 265636
* [X86] Refresh and tweak EFLAGS reuse tests. NFC.Ahmed Bougacha2016-04-071-51/+82
| | | | | | The non-1 and EQ/NE tests were misguided. llvm-svn: 265635
* Don't use PATH_MAX.Sean Silva2016-04-071-1/+1
| | | | | | | | | | This is a SmallVector anyway, and so the exact size doesn't matter. clang\lib\Frontend\ModuleDependencyCollector.cpp(83) : error C2065: 'PATH_MAX' : undeclared identifier clang\lib\Frontend\ModuleDependencyCollector.cpp(83) : error C2975: 'InternalLen' : invalid template argument for 'llvm::SmallString', expected compile-time constant expression llvm\include\llvm/ADT/SmallString.h(24) : see declaration of 'InternalLen' llvm-svn: 265634
* ValueMapper: Allow RF_IgnoreMissingLocals and RF_NullMapMissingGlobalValuesDuncan P. N. Exon Smith2016-04-073-8/+15
| | | | | | | | | Remove the assertion that disallowed the combination, since RF_IgnoreMissingLocals should have no effect on globals. As it happens, RF_NullMapMissingGlobalValues asserted in MapValue(Constant*,...), so I also changed a cast to a cast_or_null to get my test passing. llvm-svn: 265633
* [CrashReproducer] Use toUppercase from include/clang/Basic/CharInfo.hBruno Cardoso Lopes2016-04-071-1/+2
| | | | | | Use toUppercase instead of ::toupper() llvm-svn: 265632
* ValueMapper: Make LocalAsMetadata match function-local ValuesDuncan P. N. Exon Smith2016-04-072-16/+121
| | | | | | | | | | | | | Start treating LocalAsMetadata similarly to function-local members of the Value hierarchy in MapValue and MapMetadata. - Don't memoize them. - Return nullptr if they are missing. This also cleans up ConstantAsMetadata to stop listening to the RF_IgnoreMissingLocals flag. llvm-svn: 265631
* [CrashReproducer] Change std::toupper to ::toupperBruno Cardoso Lopes2016-04-071-1/+1
| | | | | | Attempt to fix windows bots llvm-svn: 265630
* [AArch64] Teach RegisterBankInfo about the CC register bank.Quentin Colombet2016-04-072-0/+12
| | | | | | We need to cover each register class with a register bank. llvm-svn: 265629
* IR: RF_IgnoreMissingValues => RF_IgnoreMissingLocals, NFCDuncan P. N. Exon Smith2016-04-0710-18/+45
| | | | | | | | | | | | | | | | | | | | | | | Clarify what this RemapFlag actually means. - Change the flag name to match its intended behaviour. - Clearly document that it's not supposed to affect globals. - Add a host of FIXMEs to indicate how to fix the behaviour to match the intent of the flag. RF_IgnoreMissingLocals should only affect the behaviour of RemapInstruction for function-local operands; namely, for operands of type Argument, Instruction, and BasicBlock. Currently, it is *only* passed into RemapInstruction calls (and the transitive MapValue calls that it makes). When I split Metadata from Value I didn't understand the flag, and I used it in a bunch of places for "global" metadata. This commit doesn't have any functionality change, but prepares to cleanup MapMetadata and MapValue. llvm-svn: 265628
* [sancov] removing flaky test case (win)Mike Aizatsky2016-04-071-8/+1
| | | | llvm-svn: 265627
* [AArch64] Teach RegisterBankInfo about the mapping of register classesQuentin Colombet2016-04-072-0/+50
| | | | | | on register banks. llvm-svn: 265626
* Follow-up for r265605: don't mutate vector we're iterating.Michael Zolotukhin2016-04-071-4/+6
| | | | llvm-svn: 265625
* [RegisterBankInfo] Implement a target independent version ofQuentin Colombet2016-04-071-1/+40
| | | | | | | | | | | getInstrMapping. This implementation requires that the target implemented getRegBankFromRegClass. Indeed, the implementation uses the register classes for the encoding constraints for the instructions to deduce the mapping of a value. llvm-svn: 265624
* Re-commit r265039 "[X86] Merge adjacent stack adjustments in ↵Hans Wennborg2016-04-079-31/+109
| | | | | | | | | | | | | | | | eliminateCallFramePseudoInstr (PR27140)" Third time's the charm? The previous attempt (r265345) caused ASan test failures on X86, as broken CFI caused stack traces to not work. This version of the patch makes sure not to merge with stack adjustments that have CFI, and to not add merged instructions' offests to the CFI about to be generated. This is already covered by the lit tests; I just got the expectations wrong previously. llvm-svn: 265623
* [CrashReproducer] Setup 'case-sensitive' in YAML files.Bruno Cardoso Lopes2016-04-072-4/+29
| | | | | | | | | The crash reproducer was not setting up case sensitivity in the VFS yaml files, which defaults to true. Make the crash reproducer explicitly set that flag based on the case sensitivity of the .cache path where vfs and modules are dumped. llvm-svn: 265622
* [CrashReproducer] Move ModuleDependencyCollector method around. NFCBruno Cardoso Lopes2016-04-071-18/+18
| | | | llvm-svn: 265621
* [RegisterBankInfo] Add an helper function to get the size of a register.Quentin Colombet2016-04-061-8/+34
| | | | | | | The previous method to get the size was too simple and could fail for physical registers. llvm-svn: 265620
* Ignore --warn-execstack.Rui Ueyama2016-04-061-0/+1
| | | | | | | | Stack is not executable by default in LLD-built executables unless you pass -z execstack option. So --warn-execstack option does not make sense to us. llvm-svn: 265619
* Fix a race condition in support library ThreadPool.Justin Lebar2016-04-061-1/+4
| | | | | | | | | | | | | | | By running TSAN on the ThreadPool unit tests it was discovered that the threads in the pool can pop tasks off the queue at the same time the "wait" routine is trying to check if the task queue is empty. This patch fixes this problem by checking for active threads in the waiter before checking whether the queue is empty. Patch by Jason Henline. Differential Revision: http://reviews.llvm.org/D18811 Reviewers: joker.eph, jlebar llvm-svn: 265618
* NFC: use AtomicOrdering isStrongerThanJF Bastien2016-04-061-4/+6
| | | | | | | | | | Summary: As discussed in D18775. Reviewers: jyknight Differential Revision: http://reviews.llvm.org/D18840 llvm-svn: 265617
* Keep -fmodule-implementation-of as an alias of -fmodule-name.Manman Ren2016-04-062-5/+7
| | | | | | | | | This helps us transitioning to -fmodule-name. Once the transitioning is done, we can remove this alias. rdar://24800983 llvm-svn: 265616
* [sancov] enabling coverage edge pruning by default.Mike Aizatsky2016-04-064-13/+6
| | | | | | Differential Revision: http://reviews.llvm.org/D18844 llvm-svn: 265615
* [sancov] enabling coverage edge pruning by default.Mike Aizatsky2016-04-065-12/+12
| | | | | | Differential Revision: http://reviews.llvm.org/D18845 llvm-svn: 265614
* Another place for CMAKE_HOST_UNIXSean Silva2016-04-061-1/+1
| | | | | | | | | | | | | If we don't create the target, don't try to add it as a dependency. After r265595, we were only creating the SanitizerLintCheck when `CMAKE_HOST_UNIX` was true. CMake was emitting a warning: The dependency target "SanitizerLintCheck" of target "check-ubsan" does not exist. llvm-svn: 265613
* ValueMapper: clang-format ValueMapper.h, NFCDuncan P. N. Exon Smith2016-04-061-91/+92
| | | | | | Also remove duplicated identifiers from comments. llvm-svn: 265611
* Fix the compare-clang diff error introduced by r265547.Wei Mi2016-04-061-1/+2
| | | | | | | Use MapVector instead of DenseMap for MergeableSpillsMap so it will be iterated in determined order. llvm-svn: 265610
OpenPOWER on IntegriCloud