summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* SanitizerCoverage: Use `createSanitizerCtor` to create ctor and call initIsmail Pazarbasi2015-05-071-16/+11
| | | | | | | | | | Reviewers: kcc, samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8780 llvm-svn: 236780
* MSan: Use `createSanitizerCtor` to create ctor, and call `__msan_init`Ismail Pazarbasi2015-05-071-3/+12
| | | | | | | | | | Reviewers: kcc, eugenis Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8781 llvm-svn: 236779
* TSan: Use `createSanitizerCtor` to create ctor, and call `__tsan_init`Ismail Pazarbasi2015-05-071-6/+13
| | | | | | | | | | Reviewers: kcc, dvyukov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8779 llvm-svn: 236778
* ASan: Use `createSanitizerCtor` to create ctor, and call `__asan_init`Ismail Pazarbasi2015-05-071-10/+4
| | | | | | | | | | Reviewers: kcc, samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8778 llvm-svn: 236777
* Change getTargetNodeName() to produce compiler warnings for missing cases, ↵Matthias Braun2015-05-0726-41/+125
| | | | | | fix them llvm-svn: 236775
* [lib/Fuzzer] change the way we use taint information for fuzzing. Now, we ↵Kostya Serebryany2015-05-074-49/+84
| | | | | | run a single unit and collect suggested mutations based on tracing+taint data, then apply the suggested mutations one by one. The previous scheme was slower and more complex. llvm-svn: 236772
* Use auto instead of the long type name. NFC.Steven Wu2015-05-071-2/+1
| | | | llvm-svn: 236768
* [AArch64] Fix sext/zext folding in address arithmetic.Pete Cooper2015-05-071-29/+32
| | | | | | | | We were accidentally folding a sign/zero extend in to address arithmetic in a different BB when the extend wasn't available there. Cross BB fast-isel isn't safe, so restrict this to only when the extend is in the same BB as the use. llvm-svn: 236764
* [lib/Fuzzer] minor refactoring/simplification, NFCKostya Serebryany2015-05-073-31/+41
| | | | llvm-svn: 236757
* Add VSX Scalar loads and stores to the PPC back endNemanja Ivanovic2015-05-078-8/+150
| | | | | | | | | | | This patch corresponds to review: http://reviews.llvm.org/D9440 It adds a new register class to the PPC back end to contain single precision values in VSX registers. Additionally, it adds scalar loads and stores for VSX registers. llvm-svn: 236755
* YAML: Enable the YAMLParser tests. Alex Lorenz2015-05-071-9/+14
| | | | | | | | | | | | | | | | | | | | | | | | | This commit enables the tests located in test/YAMLParser directory. Those tests were never actually enabled, as llvm-lit didn't pick up the files with the 'data' extension. The commit renames those test files to files with the 'test' extension so that llvm-lit would find them. This commit also modifies yaml-bench so that it returns an error status if an error occurred during parsing. It also adds the '-use-color' command line option to yaml-bench (to make sure that file check matches the error messages in the output stream). This commit modifies some of the renamed tests so that they wouldn't fail. It gets rid of XFAILs and uses the 'not' command instead for some of the tests that have to fail during parsing. This commit also adds some 'FIXME' comments to a couple of tests that are supposed to fail but currently pass because of various bugs in the implementation of the yaml parser. Reviewers: Justin Bogner Differential Revision: http://reviews.llvm.org/D9448 llvm-svn: 236754
* Recommit r236670: [opaque pointer type] Pass explicit pointer type through ↵David Blaikie2015-05-074-16/+36
| | | | | | | | | | GEP constant folding"" Clang regressions were caused by more stringent assertion checking introduced by this change. Small fix needed to clang has been committed in r236751. llvm-svn: 236752
* Fix information loss in branch probability computation.Diego Novillo2015-05-071-12/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This addresses PR 22718. When branch weights are too large, they were being clamped to the range [1, MaxWeightForBB]. But this clamping is only applied to edges that go outside the range, so it distorts the relative branch probabilities. This patch changes the weight calculation to scale every branch so the relative probabilities are preserved. The scaling is done differently now. First, all the branch weights are added up, and if the sum exceeds 32 bits, it computes an integer scale to bring all the weights within the range. The patch fixes an existing test that had slightly wrong branch probabilities due to the previous clamping. It now gets branch weights scaled accordingly. Reviewers: dexonsmith Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9442 llvm-svn: 236750
* [mips][microMIPSr6] Implement JIALC and JIC instructionsJozef Kolek2015-05-072-3/+30
| | | | | | | | This patch implements JIALC and JIC instructions using mapping. Differential Revision: http://reviews.llvm.org/D8389 llvm-svn: 236748
* Populate list of vectorizable functions for Accelerate library.Michael Zolotukhin2015-05-071-4/+32
| | | | | | | | | | | | | | | | | | | Summary: This patch adds majority of supported by Accelerate library functions to the list of vectorizable functions. The full list of available vector functions could be found here: https://developer.apple.com/library/mac/documentation/Performance/Conceptual/vecLib/index.html Test Plan: Unit tests are added. Reviewers: hfinkel, aschwaighofer, nadav Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9543 llvm-svn: 236747
* R600: Fix comment that mentions AMDILMatt Arsenault2015-05-071-2/+2
| | | | llvm-svn: 236745
* Use intrinsic pattern to make a simpler matchSanjay Patel2015-05-071-3/+2
| | | | | | | | | | | | This is a follow-on to r236740 where I took Andrea's advice in D9504 to remove a redundant pattern...except that I removed the wrong pattern! AFAICT, there is no change in the final code produced because subsequent passes would clean up the extra instructions created by the more complicated pattern. llvm-svn: 236743
* Fix another hang caused by ManagedStatic in SignalHandlerSteven Wu2015-05-071-4/+11
| | | | | | | | | Fix two other variables that might cause the same hang fixed in r235914. The hang is caused by constructing ManagedStatic in signalhandler. In this case, if FileToRemove or CallBacksToRun is not contructed, it means there is no work to do. llvm-svn: 236741
* [x86] eliminate unnecessary shuffling/moves with unary scalar math ops (PR21507)Sanjay Patel2015-05-072-10/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Finish the job that was abandoned in D6958 following the refactoring in http://reviews.llvm.org/rL230221: 1. Uncomment the intrinsic def for the AVX r_Int instruction. 2. Add missing r_Int entries to the load folding tables; there are already tests that check these in "test/Codegen/X86/fold-load-unops.ll", so I haven't added any more in this patch. 3. Add patterns to solve PR21507 ( https://llvm.org/bugs/show_bug.cgi?id=21507 ). So instead of this: movaps %xmm0, %xmm1 rcpss %xmm1, %xmm1 movss %xmm1, %xmm0 We should now get: rcpss %xmm0, %xmm0 And instead of this: vsqrtss %xmm0, %xmm0, %xmm1 vblendps $1, %xmm1, %xmm0, %xmm0 ## xmm0 = xmm1[0],xmm0[1,2,3] We should now get: vsqrtss %xmm0, %xmm0, %xmm0 Differential Revision: http://reviews.llvm.org/D9504 llvm-svn: 236740
* Switch lowering: handle zero-weight branch probabilitiesHans Wennborg2015-05-071-16/+7
| | | | | | | | | | After r236617, branch probabilities are no longer guaranteed to be >= 1. This patch makes the swich lowering code handle that correctly, without bumping the branch weights by 1 which might cause overflow and skews the probabilities. Covered by @zero_weight_tree in test/CodeGen/X86/switch.ll. llvm-svn: 236739
* [obj2yaml/yaml2obj] Add SHT_MIPS_ABIFLAGS section supportSimon Atanasyan2015-05-071-0/+119
| | | | | | | This change adds support for the SHT_MIPS_ABIFLAGS section reading/writing to the obj2yaml and yaml2obj tools. llvm-svn: 236738
* [MIPS] Move MIPS ABI flags structure constants to the separate headerSimon Atanasyan2015-05-072-84/+26
| | | | | | | | | | | http://reviews.llvm.org/D9517 The separate header file allows to reuse the MIPS ABI flags structure constants in other LLVM tools like the llvm-readobj. No functional changes. llvm-svn: 236732
* [llvm-readobj/obj2yaml/yaml2obj] Support more MIPS ELF header flagsSimon Atanasyan2015-05-071-1/+6
| | | | llvm-svn: 236728
* AVX-512: Added all forms of FP compare instructions for KNL and SKX.Elena Demikhovsky2015-05-078-111/+165
| | | | | | | | Added intrinsics for the instructions. CC parameter of the intrinsics was changed from i8 to i32 according to the spec. By Igor Breger (igor.breger@intel.com) llvm-svn: 236714
* [mips] Add the SoftFloat MipsSubtarget feature.Toma Tabacu2015-05-0711-87/+105
| | | | | | | | | | | | | | Summary: This will enable the IAS to reject floating point instructions if soft-float is enabled. Reviewers: dsanders, echristo Reviewed By: dsanders Subscribers: jfb, llvm-commits, mpf Differential Revision: http://reviews.llvm.org/D9053 llvm-svn: 236713
* Scalar/PlaceSafepoints.cpp: Fix a warning introduced in r228090. ↵NAKAMURA Takumi2015-05-071-4/+2
| | | | | | [-Wunused-variable] llvm-svn: 236711
* Update InstCombine to transform aggregate loads into scalar loads.Mehdi Amini2015-05-071-3/+32
| | | | | | | | | | | | | | | | | | | | | Summary: One step further getting aggregate loads and store being optimized properly. This will only handle struct with one element at this point. Test Plan: Added unit tests for the new supported cases. Reviewers: chandlerc, joker-eph, joker.eph, majnemer Reviewed By: majnemer Subscribers: pete, llvm-commits Differential Revision: http://reviews.llvm.org/D8339 Patch by Amaury Sechet. From: Amaury Sechet <amaury@fb.com> llvm-svn: 236695
* [SanitizerCoverage] Introduce SanitizerCoverageOptions struct.Alexey Samsonov2015-05-071-30/+68
| | | | | | | | | | | | | | | | | | | Summary: This gives frontend more precise control over collected coverage information. User can still override these options by passing -mllvm flags. No functionality change. Test Plan: regression test suite. Reviewers: kcc Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9539 llvm-svn: 236687
* InstrProf: Simplify looking up sections for coverage dataJustin Bogner2015-05-071-18/+19
| | | | llvm-svn: 236685
* [JumpThreading] Simplify comparisons when simplifying branchesPhilip Reames2015-05-071-0/+11
| | | | | | | | | | If we have recognized that a conditional is constant at a particular location in the code (while trying to decide if we can simplify a conditional branch), we can eagerly replace that condition with a constant if it's definition is post dominated by the branch in question. In practice, this ends up being a compile time savings at most. JumpThreading would have visited each using branch anyways. CVP would have visited the cmp itself again. Unless LVI gives up early, we shouldn't gain any addition power by doing this transformation early. What we do gain is simplicity and compile time. Differential Revision: http://reviews.llvm.org/D9312 llvm-svn: 236684
* [lib/Fuzzer] add dfsan_weak_hook_memcmp, enable the test that uses it, ↵Kostya Serebryany2015-05-076-17/+35
| | | | | | simplify the test runner llvm-svn: 236683
* Added support for building against Android API-9 SDKVince Harron2015-05-071-1/+1
| | | | | | | | | | Created an abstraction for log2, llvm::Log2 in Support/MathExtras.h Hid Android problems inside of it Differential Revision: http://reviews.llvm.org/D9467 llvm-svn: 236680
* Revert "[opaque pointer type] Pass explicit pointer type through GEP ↵David Blaikie2015-05-064-36/+16
| | | | | | | | | | constant folding" Causes regressions in Clang. Reverting while I investigate. This reverts commit r236670. llvm-svn: 236678
* Let llc and opt override "-target-cpu" and "-target-features" via command lineAkira Hatanaka2015-05-061-0/+13
| | | | | | | | | | | options. This commit fixes a bug in llc and opt where "-mcpu" and "-mattr" wouldn't override function attributes "-target-cpu" and "-target-features" in the IR. Differential Revision: http://reviews.llvm.org/D9537 llvm-svn: 236677
* [X86MCInst] Move LowerSTATEPOINT to inside X86AsmPrinter. NFC.Sanjoy Das2015-05-062-11/+8
| | | | llvm-svn: 236676
* [X86MCInst] Clean up LowerSTATEPOINT: variable names. NFC.Sanjoy Das2015-05-061-16/+15
| | | | llvm-svn: 236675
* [Statepoints] Clean up PlaceSafepoints.cpp: de-duplicate code.Sanjoy Das2015-05-061-21/+19
| | | | | | Common duplicated code and remove unnecessary code. llvm-svn: 236674
* [Statepoints] Clean up PlaceSafepoints.cpp: variable naming.Sanjoy Das2015-05-061-31/+29
| | | | | | Use CamelCase. NFC. llvm-svn: 236673
* [IRBuilder] Add a CreateGCStatepointInvoke.Sanjoy Das2015-05-062-53/+82
| | | | | | | | | | | Renames the original CreateGCStatepoint to CreateGCStatepointCall, and moves invoke creating functionality from PlaceSafepoints.cpp to IRBuilder.cpp. This changes the labels generated for PlaceSafepoints/invokes.ll so use a regex there to make the basic block labels more resilient. llvm-svn: 236672
* [opaque pointer type] Pass explicit pointer type through GEP constant foldingDavid Blaikie2015-05-064-16/+36
| | | | llvm-svn: 236670
* Change typeIncompatible to return an AttrBuilder instead of new-ing an ↵Pete Cooper2015-05-065-38/+22
| | | | | | | | | | AttributeSet. This makes use of the new API which can remove attributes from a set given a builder. This is much faster than creating a temporary set and reduces llc time by about 0.3% which was all spent creating temporary attributes sets on the context. llvm-svn: 236668
* Add remove method to operate on AttrBuilder instead of AttributeSet.Pete Cooper2015-05-061-3/+76
| | | | | | | | | | Prior to this change we would have to construct a temporary AttributeSet (which isn't temporary at all given that its allocated on the context), just to contain the attributes in the builder, then call remove on that. Now we can just remove any attributes from the (lightweight and really temporary) builder itself. Will be used in a future commit to remove some temporary attributes sets. llvm-svn: 236666
* InstrProf: Give coverage its own errors instead of piggy backing on instrprofJustin Bogner2015-05-063-33/+64
| | | | | | | | | | | | Since the coverage mapping reader and the instrprof reader were emitting a shared set of error codes, the error messages you'd get back from llvm-cov were ambiguous about what was actually wrong. Add another error category to fix this. I've also improved the wording on a couple of the instrprof errors, for consistency. llvm-svn: 236665
* InstrProf: Remove a function that just returns its argument (NFC)Justin Bogner2015-05-061-20/+20
| | | | llvm-svn: 236664
* YAML: Extract the code that skips a comment into a separate method, NFC. Alex Lorenz2015-05-061-12/+19
| | | | | | | | | | | This commit extracts the code that skips over a YAML comment from the 'scanToNextToken' method into a separate 'skipComment' method. This refactoring is motivated by a patch that implements parsing of YAML block scalars (http://reviews.llvm.org/D9503), as the method that parses a block scalar reuses the 'skipComment' method. llvm-svn: 236663
* Remove unnecessary #ifndef NDEBUG guard around assert. NFC.Pete Cooper2015-05-061-2/+0
| | | | | | Found by Hal Finkel in the review of AttributeSets. http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20150504/275058.html llvm-svn: 236662
* Bitcode: Set LastDL after writing DebugLocsDuncan P. N. Exon Smith2015-05-061-0/+2
| | | | | | | | | | Somehow I dropped this in r233585, and we haven't had `DEBUG_LOC_AGAIN` records since. Add it back. Also tests that the output assembly looks okay. Fixes PR23436. llvm-svn: 236661
* Handle dead defs in the if converter.Pete Cooper2015-05-062-5/+16
| | | | | | | | | | | | | | | | | | | | | | | | We had code such as this: r2 = ... t2Bcc label1: ldr ... r2 label2; return r2<dead, def> The if converter was transforming this to r2<def> = ... return [pred] r2<dead,def> ldr <r2, kill> return which fails the machine verifier because the ldr now reads from a dead def. The fix here detects dead defs in stepForward and passes them back to the caller in the clobbers list. The caller then clears the dead flag from the def is the value is live. llvm-svn: 236660
* [lib/Fuzzer] remove dfsan_fuzzer_abi.list -- its contents are now moved to ↵Kostya Serebryany2015-05-063-17/+2
| | | | | | dfsan proper llvm-svn: 236659
* [RegisterCoalescer] Make sure each live-range has only one component, asQuentin Colombet2015-05-061-4/+30
| | | | | | | | | | | | | demanded by the machine verifier. After shrinking a live-range to its uses, it is possible to create several smaller live-ranges. When this happens, shrinkToUses returns true and we need to split the different components into their own live-ranges. The problem does not reproduce on any in-tree target but Jonas Paulsson <jonas.paulsson@ericsson.com>, who reported the problem, checked that this patch fixes the issue. llvm-svn: 236658
OpenPOWER on IntegriCloud