- Jul 28, 2017
-
-
Chad Rosier authored
llvm-svn: 309417
-
Matt Arsenault authored
It is better to return arguments directly in registers if we are making a call rather than introducing expensive stack usage. In one of sample compile from one of Blender's many kernel variants, this fires on about ~20 different functions. Future improvements may be to recognize simple cases where the pointer is indexing a small array. This also fails when the store to the out argument is in a separate block from the return, which happens in a few of the Blender functions. This should also probably be using MemorySSA which might help with that. I'm not sure this is correct as a FunctionPass, but MemoryDependenceAnalysis seems to not work with a ModulePass. I'm also not sure where it should run.I think it should run before DeadArgumentElimination, so maybe either EP_CGSCCOptimizerLate or EP_ScalarOptimizerLate. llvm-svn: 309416
-
Hiroshi Yamauchi authored
Summary: LazyValueInfo currently computes the constant value of the switch condition through case edges, which allows the constant value to be propagated through the case edges. But we have seen a case where a zero-extended value of the switch condition is used past case edges for which the constant propagation doesn't occur. This patch adds a small logic to handle such a case in getEdgeValueLocal(). This is motivated by the Python 2.7 eval loop in PyEval_EvalFrameEx() where the lack of the constant propagation causes longer live ranges and more spill code than necessary. With this patch, we see that the code size of PyEval_EvalFrameEx() decreases by ~5.4% and a performance test improves by ~4.6%. Reviewers: wmi, dberlin, sanjoy Reviewed By: sanjoy Subscribers: davide, davidxl, llvm-commits Differential Revision: https://reviews.llvm.org/D34822 llvm-svn: 309415
-
Leo Li authored
Summary: Thoes files are used to build Android toolchain. D32816 makes it possible to build runtimes for targets. Reviewers: beanz, srhines Reviewed By: srhines Subscribers: pirama, jroelofs, srhines, cfe-commits, mgorny Differential Revision: https://reviews.llvm.org/D33561 llvm-svn: 309407
-
George Karpenkov authored
TSan tests on Darwin first link all libraries into a static archive file. With this change, the linking is done once per all architecture, and previously the linking step was repeated per each architecture per each add_tsan_test call. Furthermore, the code is cleared up. Differential Revision: https://reviews.llvm.org/D35913 llvm-svn: 309406
-
George Karpenkov authored
Currently there's a large amount of CMake logic duplication for compiling sanitizer tests. If we add more sanitizers, the duplication will get even worse. This change factors out common compilation commands into a macro available to all sanitizers. llvm-svn: 309405
-
Tim Northover authored
Eventually we may want to allow a pair of GPRs but absolutely nothing in the entire world is ready for that yet. llvm-svn: 309404
-
Michael Kruse authored
llvm-svn: 309403
-
Michael Kruse authored
llvm-svn: 309402
-
Michael Kruse authored
So follow-up cleanup do not need special handling for such accesses. llvm-svn: 309401
-
Reid Kleckner authored
llvm-svn: 309400
-
Reid Kleckner authored
When using win32 cmd.exe, turn off command echoing at the beginning of the script (@echo off). Replace a bash shell script with a python script for the fail_with_bad_encoding test. llvm-svn: 309399
-
Matt Arsenault authored
We need to pass something to functions for this to work. It isn't derivable just from the kernarg segment pointer because the implicit arguments are placed after the kernel arguments. Also fixes missing test for the intrinsic. llvm-svn: 309398
-
Wei Mi authored
Recommit after workaround the bug PR31652. Three bugs fixed in previous recommits: The first one is to use CurrentBlock instead of PREInstr's Parent as param of performScalarPREInsertion because the Parent of a clone instruction may be uninitialized. The second one is stop PRE when CurrentBlock to its predecessor is a backedge and an operand of CurInst is defined inside of CurrentBlock. The same value defined inside of loop in last iteration can not be regarded as available. The third one is an out-of-bound array access in a flipped if guard. Right now scalarpre doesn't have phi-translate support, so it will miss some simple pre opportunities. Like the following testcase, current scalarpre cannot recognize the last "a * b" is fully redundent because a and b used by the last "a * b" expr are both defined by phis. long a[100], b[100], g1, g2, g3; __attribute__((pure)) long goo(); void foo(long a, long b, long c, long d) { g1 = a * b; if (__builtin_expect(g2 > 3, 0)) { a = c; b = d; g2 = a * b; } g3 = a * b; // fully redundant. } The patch adds phi-translate support in scalarpre. This is only a temporary solution before the newpre based on newgvn is available. Differential Revision: https://reviews.llvm.org/D32252 llvm-svn: 309397
-
Chris Bieneman authored
Fix a quick bug from r309395. llvm-svn: 309396
-
Chris Bieneman authored
This enables libcompression when available in the CMake build system. llvm-svn: 309395
-
Chris Bieneman authored
This patch does the following: * Gets the header copy step to re-run whenever header change * Gets the header fix-up step to re-run whenever headers are copied * Removes lldb-private*.h headers from the installed headers llvm-svn: 309394
-
Chris Bieneman authored
This gets CMake to match the Xcode project build llvm-svn: 309393
-
Chris Bieneman authored
This removes the configuration order dependence between LLDB and Clang. llvm-svn: 309392
-
Rafael Espindola authored
They were being placed before sections that were listed. llvm-svn: 309391
-
Chris Bieneman authored
By creating this target other projects that depend on clang-generated headers (like LLDB) will no longer be order-dependent on Clang being processed by CMake first. Also, by creating a dummy of this target in ClangConfig.cmake, projects that can build against out-of-tree clang can freely depend on the target without needing to have conditionals for if clang is in-tree or out-of-tree. llvm-svn: 309390
-
Chris Bieneman authored
By creating a dummy of this target in LLVMConfig.cmake, projects that can build against out-of-tree LLVM can freely depend on the target without needing to have conditionals for if LLVM is in-tree or out-of-tree. llvm-svn: 309389
-
Dehao Chen authored
Summary: In the current implementation, the defaul number of values per site tracked by value profiler is 8, which is too small and could introduce inaccuracies to profile. Changing it to 16 will be able to gain more accurate value profiler. Reviewers: davidxl, tejohnson Reviewed By: tejohnson Subscribers: sanjoy, llvm-commits Differential Revision: https://reviews.llvm.org/D35964 llvm-svn: 309388
-
Siddharth Bhat authored
If we fail, throw an error for now. We can gracefully handle this later. llvm-svn: 309387
-
Alex Lorenz authored
'#pragma pack (pop)' and suspicious uses of '#pragma pack' in included files The second recommit (r309106) was reverted because the "non-default #pragma pack value chages the alignment of struct or union members in the included file" warning proved to be too aggressive for external projects like Chromium (https://bugs.chromium.org/p/chromium/issues/detail?id=749197). This recommit makes the problematic warning a non-default one, and gives it the -Wpragma-pack-suspicious-include warning option. The first recommit (r308441) caused a "non-default #pragma pack value might change the alignment of struct or union members in the included file" warning in LLVM itself. This recommit tweaks the added warning to avoid warnings for #includes that don't have any records that are affected by the non-default alignment. This tweak avoids the previously emitted warning in LLVM. Original message: This commit adds a new -Wpragma-pack warning. It warns in the following cases: - When a translation unit is missing terminating #pragma pack (pop) directives. - When entering an included file if the current alignment value as determined by '#pragma pack' directives is different from the default alignment value. - When leaving an included file that changed the state of the current alignment value. rdar://10184173 Differential Revision: https://reviews.llvm.org/D35484 llvm-svn: 309386
-
Chad Rosier authored
llvm-svn: 309385
-
Joel Jones authored
This NFC changeset standardizes the suffixes used for LSE Atomics instructions. It changes the existing suffixes - 'b', 'h', 's', 'd' - to the existing standard 'B', 'H', 'W' and 'X'. This changeset is the result of the code review discussion for D35319. Patch by: steleman Differential Revision: https://reviews.llvm.org/D35927 llvm-svn: 309384
-
Simon Pilgrim authored
llvm-svn: 309383
-
Simon Pilgrim authored
[X86] Add tests showing inability of vector non-temporal load/store intrinsic to force pointer alignment (PR33830) Clang specifies a max type alignment of 16 bytes on darwin targets, meaning that the builtin nontemporal stores don't correctly align the loads/stores to 32 or 64 bytes when required, resulting in lowering to temporal unaligned loads/stores. llvm-svn: 309382
-
Strahinja Petrovic authored
This patch enables choice for accessing thread local storage pointer (like '-mtp' in gcc). Differential Revision: https://reviews.llvm.org/D34408 llvm-svn: 309381
-
Alexander Kornienko authored
llvm-svn: 309380
-
Alexander Kornienko authored
llvm-svn: 309379
-
Ilya Biryukov authored
Previous workaround (r308959) didn't account for a case when system drive letter is not 'C:'. llvm-svn: 309378
-
Siddharth Bhat authored
Ignore all functions whose name match a regex. Useful because creating a regex that does *not* match a string is somewhat hard. Example: https://stackoverflow.com/questions/1240275/how-to-negate-specific-word-in-regex llvm-svn: 309377
-
George Rimar authored
* Removed redundant templating. * Added missing `static` keyword. llvm-svn: 309376
-
Simon Pilgrim authored
llvm-svn: 309375
-
Simon Pilgrim authored
llvm-svn: 309374
-
Tobias Grosser authored
llvm-svn: 309373
-
George Rimar authored
Previously we would crash when tried to ALIGN(0). Patch uses value 1 instead in this case, that looks to be consistent with GNU linkers and reasonable and simple behavior itself. Differential revision: https://reviews.llvm.org/D35942 llvm-svn: 309372
-
Peter Smith authored
The ARM Runtime ABI document (IHI0043) defines the AEABI floating point helper functions in section 4.1.2 The floating-point helper functions. The functions listed in this section must always use the base AAPCS calling convention. This test generates calls to all the helper functions that llvm supports and checks that the base AAPCS calling convention has been used. We test the equivalent of -mfloat-abi=soft, -mfloat-abi=softfp, -mfloat-abi=hardfp with an FPU that supports single and double precision, and one that only supports double precision. Differential Revision: https://reviews.llvm.org/D35904 llvm-svn: 309371
-