- Aug 11, 2016
-
-
Tim Shen authored
It's a fix for the original patch r278251. llvm-svn: 278298
-
Lang Hames authored
Using vmsize to populate this file works when outputing MachO images, but fails when outputting relocatable objects. This patch fixes the computation to use file offsets, which works for both output types. Fixes <rdar://problem/27727666> llvm-svn: 278297
-
Tim Northover authored
llvm-svn: 278296
-
Eugene Zelenko authored
Mention Clang-rename Emacs integration in release notes. llvm-svn: 278295
-
Sanjoy Das authored
llvm-svn: 278294
-
Tim Northover authored
We're still limited in the arguments we support, but this at least handles the basic cases. llvm-svn: 278293
-
Adhemerval Zanella authored
Current AArch64 {sig}{set,long}jmp interposing requires accessing glibc private __pointer_chk_guard to get process xor mask to demangled the internal {sig}jmp_buf function pointers. It causes some packing issues, as described in gcc PR#71042 [1], and is is not a godd practice to rely on a private glibc namespace (since ABI is not meant to be stable). This patch fixes it by changing how libtsan obtains the guarded pointer value: at initialization a specific routine issues a setjmp call and using the mangled function pointer and the original value derive the random guarded pointer. Checked on aarch64 39-bit VMA. [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71042 llvm-svn: 278292 -
Changpeng Fang authored
Summary: This patch define and implement amdgcn image intrinsics with sampler. 1. define vdata type to be llvm_anyfloat_ty, address type to be llvm_anyfloat_ty, and rsrc type to be llvm_anyint_ty. As a result, we expect the intrinsics name to have three suffixes to overload each of these three types; 2. D128 as well as two other flags are implied in the three types, for example, if you use v8i32 as resource type, then r128 is 0! 3. don't expose TFE flag, and other flags are exposed in the instruction order: unrm, glc, slc, lwe and da. Differential Revision: http://reviews.llvm.org/D22838 Reviewed by: arsenm and tstellarAMD llvm-svn: 278291 -
Piotr Padlewski authored
Summary: I think it is much better this way. When I firstly saw line: Cost += InlineConstants::LastCallToStaticBonus; I though that this is a bug, because everywhere where the cost is being reduced it is usuing -=. Reviewers: eraman, tejohnson, mehdi_amini Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D23222 llvm-svn: 278290
-
Todd Fiala authored
Tracked by: rdar://27792848 llvm-svn: 278289
-
Kyle Butt authored
If AnalyzeBranch can't analyze a block and it is possible to fallthrough, then duplicating the block doesn't make sense, as only one block can be the layout predecessor for the un-analyzable fallthrough. Submitted wit a test case, but NOTE: the test case doesn't currently fail. However, the test case fails with D20505 and would have saved me some time debugging. llvm-svn: 278288
-
Kyle Butt authored
The following function currently relies on tail-merging for if conversion to succeed. The common tail of cond_true and cond_false is extracted, and this then forms a diamond pattern that can be successfully if converted. If this block does not get extracted, either because tail-merging is disabled or the threshold is higher, we should still recognize this pattern and if-convert it. Fixed a regression in the original commit. Need to un-reverse branches after reversing them, or other conversions go awry. define i32 @t2(i32 %a, i32 %b) nounwind { entry: %tmp1434 = icmp eq i32 %a, %b ; <i1> [#uses=1] br i1 %tmp1434, label %bb17, label %bb.outer bb.outer: ; preds = %cond_false, %entry %b_addr.021.0.ph = phi i32 [ %b, %entry ], [ %tmp10, %cond_false ] %a_addr.026.0.ph = phi i32 [ %a, %entry ], [ %a_addr.026.0, %cond_false ] br label %bb bb: ; preds = %cond_true, %bb.outer %indvar = phi i32 [ 0, %bb.outer ], [ %indvar.next, %cond_true ] %tmp. = sub i32 0, %b_addr.021.0.ph %tmp.40 = mul i32 %indvar, %tmp. %a_addr.026.0 = add i32 %tmp.40, %a_addr.026.0.ph %tmp3 = icmp sgt i32 %a_addr.026.0, %b_addr.021.0.ph br i1 %tmp3, label %cond_true, label %cond_false cond_true: ; preds = %bb %tmp7 = sub i32 %a_addr.026.0, %b_addr.021.0.ph %tmp1437 = icmp eq i32 %tmp7, %b_addr.021.0.ph %indvar.next = add i32 %indvar, 1 br i1 %tmp1437, label %bb17, label %bb cond_false: ; preds = %bb %tmp10 = sub i32 %b_addr.021.0.ph, %a_addr.026.0 %tmp14 = icmp eq i32 %a_addr.026.0, %tmp10 br i1 %tmp14, label %bb17, label %bb.outer bb17: ; preds = %cond_false, %cond_true, %entry %a_addr.026.1 = phi i32 [ %a, %entry ], [ %tmp7, %cond_true ], [ %a_addr.026.0, %cond_false ] ret i32 %a_addr.026.1 } Without tail-merging or diamond-tail if conversion: LBB1_1: @ %bb @ =>This Inner Loop Header: Depth=1 cmp r0, r1 ble LBB1_3 @ BB#2: @ %cond_true @ in Loop: Header=BB1_1 Depth=1 subs r0, r0, r1 cmp r1, r0 it ne cmpne r0, r1 bgt LBB1_4 LBB1_3: @ %cond_false @ in Loop: Header=BB1_1 Depth=1 subs r1, r1, r0 cmp r1, r0 bne LBB1_1 LBB1_4: @ %bb17 bx lr With diamond-tail if conversion, but without tail-merging: @ BB#0: @ %entry cmp r0, r1 it eq bxeq lr LBB1_1: @ %bb @ =>This Inner Loop Header: Depth=1 cmp r0, r1 ite le suble r1, r1, r0 subgt r0, r0, r1 cmp r1, r0 bne LBB1_1 @ BB#2: @ %bb17 bx lr llvm-svn: 278287 -
Greg Clayton authored
llvm-svn: 278286
-
Reid Kleckner authored
Undoes some of the effect of r278271 llvm-svn: 278285
-
Reid Kleckner authored
The export table is not considered part of the object file symbol table, so we have to look through it separately. Reviewers: kcc Differential Revision: https://reviews.llvm.org/D23321 llvm-svn: 278284
-
Marshall Clow authored
llvm-svn: 278282
-
Jonathan Roelofs authored
i64 -1, whose sign bit is the 0th one, can't be left shifted without invoking UB. https://reviews.llvm.org/D23362 llvm-svn: 278280
-
Eugene Zelenko authored
[Documentation] Fix style and grammar mistake in Clang-tidy readability-else-after-return description spotted by Alexander Kornienko. llvm-svn: 278279
-
Matt Arsenault authored
llvm-svn: 278278
-
Matt Arsenault authored
llvm-svn: 278276
-
Matt Arsenault authored
llvm-svn: 278275
-
Matt Arsenault authored
llvm-svn: 278274
-
Matt Arsenault authored
Insert before the skip branch if one is created. This is a somewhat more natural placement relative to the skip branches, and makes it possible to implement analyzeBranch for skip blocks. The test changes are mostly due to a quirk where the block label is not emitted if there is a terminator that is not also a branch. llvm-svn: 278273
-
Matt Arsenault authored
I'm not sure what the difference is, but no other target uses this for emergency spill slots. llvm-svn: 278272
-
Reid Kleckner authored
Add the $arch-registered-target features that clang uses to disable tests that require a registered backend, so that we can run the sancov tests on Windows. LLVM's lit suite did not appear to have a per-test way to do this, and I would rather not split up the sancov tests into architecture directories. Split out of https://reviews.llvm.org/D23321 llvm-svn: 278271
-
Sanjay Patel authored
This handles the case in: https://llvm.org/bugs/show_bug.cgi?id=28895 ...but we are not getting all of the possibilities yet. Eg, we use 'X86::FANDN' for scalar FP select combines. That enhancement is filed as: https://llvm.org/bugs/show_bug.cgi?id=28925 Differential Revision: https://reviews.llvm.org/D23337 llvm-svn: 278270
-
Andrew Kaylor authored
Patch by Li Huang Differential Revision: https://reviews.llvm.org/D18867 llvm-svn: 278269
-
Nicolai Haehnle authored
Summary: See the new test case for one that was (non-deterministically) crashing on trunk and deterministically hit the assertion that I added in D23302. Basically, the machine function contains a sequence DS_WRITE_B32 %vreg4, %vreg14:sub0, ... DS_WRITE_B32 %vreg4, %vreg14:sub0, ... %vreg14:sub1<def> = COPY %vreg14:sub0 and SILoadStoreOptimizer::mergeWrite2Pair merges the two DS_WRITE_B32 instructions into one before calling repairIntervalsInRange. Now repairIntervalsInRange wants to repair %vreg14, in particular, and ends up trying to repair %vreg14:sub1 as well, but that only becomes active _after_ the range that is to be repaired, hence the crash due to LR.find(...) == LR.begin() at the start of repairOldRegInRange. I believe that just skipping those subrange is fine, but again, not too familiar with that code. Reviewers: MatzeB, kparzysz, tstellarAMD Subscribers: llvm-commits, MatzeB Differential Revision: https://reviews.llvm.org/D23303 llvm-svn: 278268 -
Andrew Kaylor authored
Patch by Li Huang Differential Revision: https://reviews.llvm.org/D18777 llvm-svn: 278267
-
Krzysztof Parzyszek authored
llvm-svn: 278266
-
Kyle Butt authored
This change makes it possible for tail-duplication and tail-merging to be disjoint. By being less aggressive when merging during layout, there are no overlapping cases between tail-duplication and tail-merging, provided the thresholds are disjoint. There is a remaining TODO to benchmark the succ_size() test for non-layout tail merging. llvm-svn: 278265
-
Bruno Cardoso Lopes authored
Reapply r277787. For memset (and others) we can get diagnostics like: struct stat { int x; }; void foo(struct stat *stamps) { bzero(stamps, sizeof(stamps)); memset(stamps, 0, sizeof(stamps)); } t.c:7:28: warning: 'memset' call operates on objects of type 'struct stat' while the size is based on a different type 'struct stat *' [-Wsizeof-pointer-memaccess] memset(stamps, 0, sizeof(stamps)); ~~~~~~ ^~~~~~ t.c:7:28: note: did you mean to dereference the argument to 'sizeof' (and multiply it by the number of elements)? memset(stamps, 0, sizeof(stamps)); ^~~~~~ This patch implements the same class of warnings for bzero. Differential Revision: https://reviews.llvm.org/D22525 rdar://problem/18963514 llvm-svn: 278264 -
Eugene Zelenko authored
[Documentation] Highlighting consistency and spelling mistake fix in Clang-tidy readability-else-after-return description. llvm-svn: 278263
-
Eugene Zelenko authored
llvm-svn: 278262
-
Eugene Leviant authored
llvm-svn: 278261
-
Simon Pilgrim authored
[X86][SSE] Dropped blend(insertps(x,y),zero) combine - this is now handled by target shuffle chain combining llvm-svn: 278260
-
Tim Shen authored
llvm-svn: 278259
-
Matthias Braun authored
Differential Revision: https://reviews.llvm.org/D22708 llvm-svn: 278258
-
Kirill Bobyrev authored
`readability-else-after-return` only warns about `return` calls, but LLVM Coding Standars stat that `throw`, `continue`, `goto`, etc after `return` calls are bad, too. Reviwers: alexfh, aaron.ballman Differential Revision: https://reviews.llvm.org/D23265 llvm-svn: 278257
-
Krzysztof Parzyszek authored
llvm-svn: 278256
-