Sam Kolton [Fri, 7 Oct 2016 14:46:06 +0000 (14:46 +0000)]
[AMDGPU] Assembler: support v_mac_f32 DPP and SDWA. Move getNamedOperandIdx to AMDGPUBaseInfo.h
Reviewers: artem.tamazov, tstellarAMD
Subscribers: arsenm, kzhuravl, wdng, nhaehnle, yaxunl, tony-tye
Differential Revision: https://reviews.llvm.org/D25084
llvm-svn: 283560
Simon Pilgrim [Fri, 7 Oct 2016 14:42:22 +0000 (14:42 +0000)]
[X86][SSE] Tidied up tests - use standard check prefixes
llvm-svn: 283559
Konstantin Zhuravlyov [Fri, 7 Oct 2016 14:39:53 +0000 (14:39 +0000)]
[AMDGPU] AMDGPUCodeGenPrepare: remove extra ';'
llvm-svn: 283558
Tom Stellard [Fri, 7 Oct 2016 14:23:29 +0000 (14:23 +0000)]
[ValueTracking] Fix crash in GetPointerBaseWithConstantOffset()
Summary:
While walking defs of pointer operands we were assuming that the pointer
size would remain constant. This is not true, because addresspacecast
instructions may cast the pointer to an address space with a different
pointer width.
This partial reverts r282612, which was a more conservative solution
to this problem.
Reviewers: reames, sanjoy, apilipenko
Subscribers: wdng, llvm-commits
Differential Revision: https://reviews.llvm.org/D24772
llvm-svn: 283557
Rafael Espindola [Fri, 7 Oct 2016 14:23:28 +0000 (14:23 +0000)]
Add () for clarity. NFC.
llvm-svn: 283556
Konstantin Zhuravlyov [Fri, 7 Oct 2016 14:22:58 +0000 (14:22 +0000)]
[AMDGPU] Promote uniform (i1, i16] operations to i32
Differential Revision: https://reviews.llvm.org/D25302
llvm-svn: 283555
Daniel Marjamaki [Fri, 7 Oct 2016 14:21:08 +0000 (14:21 +0000)]
[analyzer] Don't merge different return nodes in ExplodedGraph
Returns when calling an inline function should not be merged in the ExplodedGraph unless they are same.
Differential Revision: https://reviews.llvm.org/D25326
llvm-svn: 283554
Renato Golin [Fri, 7 Oct 2016 13:58:10 +0000 (13:58 +0000)]
Revert "[clang-move] Support moving multiple classes in one run."
This reverts commit r283526 et al as it keeps randomly breaking bots, even after
the commit has gone, on other people's commit ranges.
Revert "[clang-move] Simplify lint tests" (r283545).
Revert "Fix buildbot error." (r283534).
Revert "Revert "fix buildbot error" since it is not right fix." (r283538).
llvm-svn: 283553
Benjamin Kramer [Fri, 7 Oct 2016 13:46:38 +0000 (13:46 +0000)]
Remove spurious non-printable character from source file.
NFC.
llvm-svn: 283552
Javed Absar [Fri, 7 Oct 2016 13:41:55 +0000 (13:41 +0000)]
[ARM]: add missing switch case for cortex-r52
Adds a missing switch case for handling cortex-r52
in init-subtarget-features.
llvm-svn: 283551
Martin Storsjo [Fri, 7 Oct 2016 13:28:53 +0000 (13:28 +0000)]
[ARM] Reapply: Use __rt_div functions for divrem on Windows
Reapplying r283383 after revert in r283442. The additional fix
is a getting rid of a stray space in a function name, in the
refactoring part of the commit.
This avoids falling back to calling out to the GCC rem functions
(__moddi3, __umoddi3) when targeting Windows.
The __rt_div functions have flipped the two arguments compared
to the __aeabi_divmod functions. To match MSVC, we emit a
check for division by zero before actually calling the library
function (even if the library function itself also might do
the same check).
Not all calls to __rt_div functions for division are currently
merged with calls to the same function with the same parameters
for the remainder. This is more wasteful than a div + mls as before,
but avoids calls to __moddi3.
Differential Revision: https://reviews.llvm.org/D25332
llvm-svn: 283550
Simon Pilgrim [Fri, 7 Oct 2016 13:25:41 +0000 (13:25 +0000)]
Wdocumentation fix
llvm-svn: 283549
Valentina Giusti [Fri, 7 Oct 2016 13:21:59 +0000 (13:21 +0000)]
Fix build failure on lldb-amd64-ninja-freebsd11 error caused by rL283474
Differential Revision: https://reviews.llvm.org/D25362
llvm-svn: 283548
Michael Kruse [Fri, 7 Oct 2016 12:38:32 +0000 (12:38 +0000)]
[cmake] Unify disabling upstream project warnings.
Handle MSVC, ISL and PPCG in one place. The only functional change is that
warnings are also disabled for MSVC compiling PPCG (Which currently fails
anyway).
llvm-svn: 283547
Michael Kruse [Fri, 7 Oct 2016 12:38:24 +0000 (12:38 +0000)]
[cmake] Move isl_test artifacts to Polly folder.
Folders in Visual Studio solutions help organize the build artifacts from all
LLVM projects. There is a folder to keep Polly-built files in.
llvm-svn: 283546
Haojian Wu [Fri, 7 Oct 2016 12:35:37 +0000 (12:35 +0000)]
[clang-move] Simplify lint tests
No need to use compilation database.
llvm-svn: 283545
George Rimar [Fri, 7 Oct 2016 12:27:45 +0000 (12:27 +0000)]
[ELF] - Check that section alignment is a power of 2.
I found that this check still may be useful in some cases.
At fact since we use uint32_t alignment, then maximum value
that is valid for us is 0x80000000. But some broken files,
for example file from testcase may have greater value.
Because of that offset calculation overflow and crash happens.
Differential revision: https://reviews.llvm.org/D25324
llvm-svn: 283544
Javed Absar [Fri, 7 Oct 2016 12:08:41 +0000 (12:08 +0000)]
[ARM]: Add Cortex-R52 target
This patch adds Cortex-R52, the new ARM real-time processor.
Cortex-R52 implements the ARMv8-R architecture.
llvm-svn: 283543
Javed Absar [Fri, 7 Oct 2016 12:06:40 +0000 (12:06 +0000)]
[ARM]: Add Cortex-R52 target to LLVM
This patch adds Cortex-R52, the new ARM real-time processor, to LLVM.
Cortex-R52 implements the ARMv8-R architecture.
llvm-svn: 283542
Artem Dergachev [Fri, 7 Oct 2016 11:29:32 +0000 (11:29 +0000)]
Revert "[analyzer] Re-apply r283092, attempt no.3, in small chunks this time."
llvm-svn: 283541
Artem Dergachev [Fri, 7 Oct 2016 11:26:15 +0000 (11:26 +0000)]
[analyzer] Re-apply r283092, attempt no.3, in small chunks this time.
llvm-svn: 283540
Simon Pilgrim [Fri, 7 Oct 2016 11:18:38 +0000 (11:18 +0000)]
[X86][SSE] Update register class during MOVSD/MOVSS - BLENDPD/BLENDPS commutation
MOVSD/MOVSS take a 128-bit register and a FR32/FR64 register input, the commutation code wasn't taking this into account leading to verification errors.
This patch inserts a vreg copy mi to ensure that the registers are correct.
Fix for PR30607
Differential Revision: https://reviews.llvm.org/D25280
llvm-svn: 283539
Haojian Wu [Fri, 7 Oct 2016 10:59:03 +0000 (10:59 +0000)]
Revert "fix buildbot error" since it is not right fix.
llvm-svn: 283538
Artem Dergachev [Fri, 7 Oct 2016 10:56:44 +0000 (10:56 +0000)]
Revert "[analyzer] Try to re-apply r283092 "Extend bug reports with extra notes"
Vector of smart pointers wasn't the thing that caused msvc crash.
llvm-svn: 283537
Artem Dergachev [Fri, 7 Oct 2016 10:44:09 +0000 (10:44 +0000)]
[analyzer] Try to re-apply r283092 "Extend bug reports with extra notes"
Replace SmallVector<IntrusiveRefCntPtr> with a vector of plain pointers.
Would insignificantly increase memory usage.
llvm-svn: 283536
Alexey Bataev [Fri, 7 Oct 2016 09:39:22 +0000 (09:39 +0000)]
[SLPVectorizer] Fix for PR25748: reduction vectorization after loop
unrolling.
The next code is not vectorized by the SLPVectorizer:
```
int test(unsigned int *p) {
int sum = 0;
for (int i = 0; i < 8; i++)
sum += p[i];
return sum;
}
```
During optimization this loop is fully unrolled and SLPVectorizer is
unable to vectorize it. Patch tries to fix this problem.
Differential Revision: https://reviews.llvm.org/D24796
llvm-svn: 283535
Haojian Wu [Fri, 7 Oct 2016 09:23:28 +0000 (09:23 +0000)]
Fix buildbot error.
The error maybe caused by the mixed environment of the two lint tests.
Cleanup the environment before running each test.
llvm-svn: 283534
George Rimar [Fri, 7 Oct 2016 09:01:04 +0000 (09:01 +0000)]
[ELF] - Do not crash on invalid size of dynamic section.
Previously if sh_size of dynamic section was broken,
lld may crash. Or even may not crash if used 32 bits host.
(then value may be truncated to 32 bits when doing pointer arithmetic
and could be just zero).
Patch fixes the issue.
Differential revision: https://reviews.llvm.org/D25327
llvm-svn: 283533
George Rimar [Fri, 7 Oct 2016 08:51:57 +0000 (08:51 +0000)]
[ELF] - Do not crash when unable to parse ELF object file.
createELFObj() may call error(...), for example when file is too short.
In that case header is not set and following line lead to crash:
EMachine = ELFObj.getHeader()->e_machine;
Patch fixes the issue.
Differential revision: https://reviews.llvm.org/D25233
llvm-svn: 283532
Igor Kudrin [Fri, 7 Oct 2016 08:48:28 +0000 (08:48 +0000)]
Recommit r282692: [libc++abi] Use fallback_malloc to allocate __cxa_eh_globals in case of dynamic memory exhaustion.
Throwing an exception for the first time may lead to call calloc to
allocate memory for __cxa_eh_globals. If the memory pool is exhausted
at that moment, it results in abnormal termination of the program.
This patch addresses the issue by using fallback_malloc in that case.
In this revision, some restrictions were added into the test to not
run it in unsuitable environments.
Differential Revision: https://reviews.llvm.org/D17815
llvm-svn: 283531
Oliver Stannard [Fri, 7 Oct 2016 08:48:24 +0000 (08:48 +0000)]
[ARM] Don't convert switches to lookup tables of pointers with ROPI/RWPI
With the ROPI and RWPI relocation models we can't always have pointers
to global data or functions in constant data, so don't try to convert switches
into lookup tables if any value in the lookup table would require a relocation.
We can still safely emit lookup tables of other values, such as simple
constants.
Differential Revision: https://reviews.llvm.org/D24462
llvm-svn: 283530
Mehdi Amini [Fri, 7 Oct 2016 08:48:07 +0000 (08:48 +0000)]
Use StringRef in ARMELFStreamer (NFC)
llvm-svn: 283529
Nicolai Haehnle [Fri, 7 Oct 2016 08:40:14 +0000 (08:40 +0000)]
AMDGPU: Fix use-after-free in SIOptimizeExecMasking
Summary:
There was a bug with sequences like
s_mov_b64 s[0:1], exec
s_and_b64 s[2:3]<def>, s[0:1], s[2:3]<kill>
...
s_mov_b64_term exec, s[2:3]
because s[2:3] was defined and used in the same instruction, ending up with
SaveExecInst inside OtherUseInsts.
Note that the test case also exposes an unrelated bug.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98028
Reviewers: tstellarAMD, arsenm
Subscribers: kzhuravl, wdng, yaxunl, llvm-commits, tony-tye
Differential Revision: https://reviews.llvm.org/D25306
llvm-svn: 283528
Mehdi Amini [Fri, 7 Oct 2016 08:37:29 +0000 (08:37 +0000)]
Use StringReg in TargetParser APIs (NFC)
llvm-svn: 283527
Haojian Wu [Fri, 7 Oct 2016 08:29:20 +0000 (08:29 +0000)]
[clang-move] Support moving multiple classes in one run.
Reviewers: ioeric
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25309
llvm-svn: 283526
Mehdi Amini [Fri, 7 Oct 2016 08:25:42 +0000 (08:25 +0000)]
Revert "Revert "Add a static_assert to enforce that parameters to llvm::format() are not totally unsafe""
This reverts commit r283510 and reapply r283509, with updates to
clang-tools-extra as well.
llvm-svn: 283525
Craig Topper [Fri, 7 Oct 2016 06:54:43 +0000 (06:54 +0000)]
[X86] Fix patterns for VPMULLD and VPCMPEQQ to not require aligned loads.
llvm-svn: 283524
Craig Topper [Fri, 7 Oct 2016 06:54:39 +0000 (06:54 +0000)]
[X86] Remove unused PatFrags. NFC
llvm-svn: 283523
Dylan McKay [Fri, 7 Oct 2016 06:13:09 +0000 (06:13 +0000)]
[AVR] Add the AVRMCInstLower class
Summary:
This class deals with the lowering of CodeGen `MachineInstr` objects to
MC `MCInst` objects.
Reviewers: kparzysz, arsenm
Subscribers: wdng, beanz, japaric, mgorny
Differential Revision: https://reviews.llvm.org/D25269
llvm-svn: 283522
Matt Arsenault [Fri, 7 Oct 2016 03:55:04 +0000 (03:55 +0000)]
AMDGPU: Change check prefix in test
llvm-svn: 283521
Hal Finkel [Fri, 7 Oct 2016 02:26:41 +0000 (02:26 +0000)]
[lit] Don't assume you'll find debugserver
On Linux, there is no "debugserver" process, and the RUN-line substitution will
fail if you try to substitute '%debugserver' with None.
Fixes PR30492.
llvm-svn: 283520
Hal Finkel [Fri, 7 Oct 2016 02:01:03 +0000 (02:01 +0000)]
[llvm-opt-report] Left justify unrolling counts, etc.
In the left part of the reports, we have things like U<number>; if some of
these numbers use more digits than others, we don't want a space in between the
U and the start of the number. Instead, the space should come afterward. This
way it is clear that the number goes with the U and not any other optimization
indicator that might come later on the line.
Tests committed in r283518.
llvm-svn: 283519
Hal Finkel [Fri, 7 Oct 2016 01:57:06 +0000 (01:57 +0000)]
[llvm-opt-report] Left justify unrolling counts, etc.
In the left part of the reports, we have things like U<number>; if some of
these numbers use more digits than others, we don't want a space in between the
U and the start of the number. Instead, the space should come afterward. This
way it is clear that the number goes with the U and not any other optimization
indicator that might come later on the line.
llvm-svn: 283518
David Majnemer [Fri, 7 Oct 2016 01:38:35 +0000 (01:38 +0000)]
[SimplifyCFG] Correctly test for unconditional branches in GetCaseResults
GetCaseResults assumed that a terminator with one successor was an
unconditional branch. This is not necessarily the case, it could be a
cleanupret.
Strengthen the check by querying whether or not the terminator is
exceptional.
llvm-svn: 283517
Hal Finkel [Fri, 7 Oct 2016 01:30:59 +0000 (01:30 +0000)]
[llvm-opt-report] Use -no-demangle to disable demangling
As this is intended to be a user-facing option, -no-demangle seems much better
than -demangle=0. Add testing for the option.
llvm-svn: 283516
Peter Collingbourne [Fri, 7 Oct 2016 00:30:49 +0000 (00:30 +0000)]
Target: Remove unused patterns and transforms. NFC.
llvm-svn: 283515
Colin LeMahieu [Fri, 7 Oct 2016 00:15:07 +0000 (00:15 +0000)]
[Hexagon] NFC Removing 'V4_' prefix from duplex instruction names.
llvm-svn: 283514
Michael Kuperstein [Thu, 6 Oct 2016 23:57:25 +0000 (23:57 +0000)]
[LV] Remove triples from target-independent vectorizer tests. NFC.
Vectorizer tests in the target-independent directory should not have a target
triple. If a test really needs to query a specific backend, it belongs in the
right target subdirectory (which "REQUIRES" the right backend). Otherwise, it
should not specify a triple.
llvm-svn: 283512
Vedant Kumar [Thu, 6 Oct 2016 23:41:57 +0000 (23:41 +0000)]
[ubsan] More 0 -> nullptr conversions (NFC)
llvm-svn: 283511
Mehdi Amini [Thu, 6 Oct 2016 23:41:49 +0000 (23:41 +0000)]
Revert "Add a static_assert to enforce that parameters to llvm::format() are not totally unsafe"
This reverts commit r283509, clang is hitting the assert.
llvm-svn: 283510
Mehdi Amini [Thu, 6 Oct 2016 23:26:29 +0000 (23:26 +0000)]
Add a static_assert to enforce that parameters to llvm::format() are not totally unsafe
Summary:
I had for the second time today a bug where llvm::format("%s", Str)
was called with Str being a StringRef. The Linux and MacOS bots were
fine, but windows having different calling convention, it printed
garbage.
Instead we can catch this at compile-time: it is never expected to
call a C vararg printf-like function with non scalar type I believe.
Reviewers: bogner, Bigcheese, dexonsmith
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D25266
llvm-svn: 283509
Richard Smith [Thu, 6 Oct 2016 23:12:58 +0000 (23:12 +0000)]
PR25890: Fix incoherent error handling in PerformImplicitConversion and
CheckSingleAssignmentConstraints. These no longer produce ExprError() when they
have not emitted an error, and reliably inform the caller when they *have*
emitted an error.
This fixes some serious issues where we would fail to emit any diagnostic for
invalid code and then attempt to emit code for an invalid AST, and conversely
some issues where we would emit two diagnostics for the same problem.
llvm-svn: 283508
Colin LeMahieu [Thu, 6 Oct 2016 23:02:11 +0000 (23:02 +0000)]
[Hexagon] NFC. Canonicalizing absolute address instruction names.
llvm-svn: 283507
Vedant Kumar [Thu, 6 Oct 2016 22:58:45 +0000 (22:58 +0000)]
[ubsan] 0 -> nullptr (NFC)
llvm-svn: 283506
Vedant Kumar [Thu, 6 Oct 2016 22:53:43 +0000 (22:53 +0000)]
Delete some dead code in SelectionDAG (NFC)
Differential Revision: https://reviews.llvm.org/D24435
llvm-svn: 283505
Rui Ueyama [Thu, 6 Oct 2016 22:52:01 +0000 (22:52 +0000)]
Add an empty DBI stream.
llvm-svn: 283504
Dan Gohman [Thu, 6 Oct 2016 22:29:32 +0000 (22:29 +0000)]
[WebAssemby] Implement block signatures.
Per spec changes, this implements block signatures, and adds just enough
logic to produce correct block signatures at the ends of functions.
Differential Revision: https://reviews.llvm.org/D25144
llvm-svn: 283503
Dan Gohman [Thu, 6 Oct 2016 22:10:23 +0000 (22:10 +0000)]
[WebAssembly] Remove loop's bottom label.
Per spec changes, loop constructs no longer have a bottom label.
https://reviews.llvm.org/D25118
llvm-svn: 283502
Dan Gohman [Thu, 6 Oct 2016 22:08:28 +0000 (22:08 +0000)]
[WebAssembly] Remove the output operand from stores.
Per spec changes, store instructions in WebAssembly no longer have a return
value. Update the instruction descriptions.
Differential Revision: https://reviews.llvm.org/D25122
llvm-svn: 283501
Wolfgang Pieb [Thu, 6 Oct 2016 21:43:45 +0000 (21:43 +0000)]
Preserve the debug location when CodeGenPrepare sinks a compare instruction into the
basic block of a user.
Patch by Andrea DiBiagio.
Differential Revision: https://reviews.llvm.org/D24632
llvm-svn: 283500
Anton Yartsev [Thu, 6 Oct 2016 21:42:21 +0000 (21:42 +0000)]
[analyzer] Add explanation why analyzer report is not generated (fix for PR12421).
Currently if the path diagnostic consumer (e.g HTMLDiagnostics and PlistDiagnostics) do not support cross file diagnostics then the path diagnostic report is silently omitted in the case of cross file diagnostics. The patch adds a little verbosity to Clang in this case.
The patch also adds help entry for the "--analyzer-output" driver option.
llvm-svn: 283499
Richard Smith [Thu, 6 Oct 2016 21:31:04 +0000 (21:31 +0000)]
Add another .def file to module map to fix modules buildbot's displeasure.
llvm-svn: 283498
Todd Fiala [Thu, 6 Oct 2016 21:30:33 +0000 (21:30 +0000)]
disable TSAN tests on macOS i386
These are erroring out on macOS i386.
Tracked by:
rdar://
28659145
llvm-svn: 283497
Pirama Arumuga Nainar [Thu, 6 Oct 2016 21:27:05 +0000 (21:27 +0000)]
Handle *_EXTEND_VECTOR_INREG during Integer Legalization
Summary:
These nodes need legalization for 3-element vectors. This commit
handles the legalization and adds tests for zext and sext.
This fixes PR30614.
Reviewers: RKSimon, srhines
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D25268
llvm-svn: 283496
Eric Fiselier [Thu, 6 Oct 2016 21:23:38 +0000 (21:23 +0000)]
[coroutines] Fix co_return statement for initializer list arguments
Summary:
Previously the statement `co_return {42}` would be transformed into `P.return_void()`, since the type of `{42}` is represented as `void` by Clang.
This patch fixes the bug by checking for `InitListExpr` arguments and transforming them accordingly.
Reviewers: majnemer, GorNishanov, rsmith
Subscribers: mehdi_amini, cfe-commits
Differential Revision: https://reviews.llvm.org/D25296
llvm-svn: 283495
Zachary Turner [Thu, 6 Oct 2016 21:22:44 +0000 (21:22 +0000)]
Convert UniqueCStringMap to use StringRef.
llvm-svn: 283494
Todd Fiala [Thu, 6 Oct 2016 21:16:37 +0000 (21:16 +0000)]
xfail TestReportData.py on i386
Tracked by:
rdar://
28658860
llvm-svn: 283493
Todd Fiala [Thu, 6 Oct 2016 21:07:45 +0000 (21:07 +0000)]
xfail TestQueues on macOS
This test is failing on CI. I cannot get it to fail on my
local setup.
Tracked by:
rdar://
28658529
llvm-svn: 283492
Francis Ricci [Thu, 6 Oct 2016 20:41:11 +0000 (20:41 +0000)]
Fix GetDisplayName when only a demangled name is available
Summary:
GetDisplayDemangledName will already return a ConstString() when
there is neither a mangled name or a demangled name, so we don't need to special
case here. This will fix GetDisplayName in cases where m_mangled contains
only a demangled name and not a mangled name.
Reviewers: clayborg, granata.enrico, sas
Subscribers: lldb-commits
Differential Revision: https://reviews.llvm.org/D25201
llvm-svn: 283491
Rong Xu [Thu, 6 Oct 2016 20:38:13 +0000 (20:38 +0000)]
[PGO] Create weak alias for the renamed Comdat function
Add a weak alias to the renamed Comdat function in IR level instrumentation,
using it's original name. This ensures the same behavior w/ and w/o IR
instrumentation, even for non standard conforming code.
Differential Revision: http://reviews.llvm.org/D25339
llvm-svn: 283490
Richard Smith [Thu, 6 Oct 2016 20:30:51 +0000 (20:30 +0000)]
[modules] Be sure to emit local specializations of imported templates, even if
the resulting specialization is not referenced by the rest of the AST. This
both avoids performing unnecessary reinstantiations in downstream users of the
AST file and fixes a bug (breaking modules self-host right now) where we would
sometimes fail to emit a definition of a class template specialization if we
imported just a declaration of it from elsewhere (see new testcase for reduced
example).
llvm-svn: 283489
Rui Ueyama [Thu, 6 Oct 2016 20:04:54 +0000 (20:04 +0000)]
Remove useless function.
llvm-svn: 283488
Justin Lebar [Thu, 6 Oct 2016 19:47:56 +0000 (19:47 +0000)]
[Sema] Replace smart quote with "'" in comment.
Looks like the smart quote was copy/pasted from the C++ standard.
The smart quote was not encoded as valid UTF-8 (?), even though vim was
detecting the file as UTF-8. This broke the clang-format Python script,
which tried to read the file using the same encoding as vim detected.
llvm-svn: 283487
Michael Kuperstein [Thu, 6 Oct 2016 19:31:27 +0000 (19:31 +0000)]
[X86] Preserve BasePtr for LEA64_32r
When replacing FrameIndex with BasePtr, we must preserve BasePtr for
LEA64_32r since BasePtr is used later for stack adjustment if it is
the same as StackPtr.
Patch by H.J Lu <hjl.tools@gmail.com>
Differential Revision: https://reviews.llvm.org/D23575
llvm-svn: 283486
Simon Pilgrim [Thu, 6 Oct 2016 19:29:25 +0000 (19:29 +0000)]
[X86][SSE] Add f16/f80/f128 vector sitofp test cases
As discussed on D23808
llvm-svn: 283485
Todd Fiala [Thu, 6 Oct 2016 19:23:29 +0000 (19:23 +0000)]
xfail TestSBTypeTypeClass.py on macOS i386
Tracked by:
rdar://
28656677
llvm-svn: 283484
Todd Fiala [Thu, 6 Oct 2016 19:18:48 +0000 (19:18 +0000)]
xfail TestDataFormatterNSIndexPath.py on macOS i386
Tracked by:
rdar://
28656605
llvm-svn: 283483
Todd Fiala [Thu, 6 Oct 2016 19:12:05 +0000 (19:12 +0000)]
xfail TestExec.py on macOS i386
Tracked by:
rdar://
28656532
llvm-svn: 283482
Todd Fiala [Thu, 6 Oct 2016 19:04:58 +0000 (19:04 +0000)]
xfail TestDiagnoseDereferenceFunctionReturn.py on macOS i386
Tracked by:
rdar://
28656408
llvm-svn: 283481
Michael Kuperstein [Thu, 6 Oct 2016 18:58:24 +0000 (18:58 +0000)]
[DAG] Generalize build_vector -> vector_shuffle combine for more than 2 inputs
This generalizes the build_vector -> vector_shuffle combine to support any
number of inputs. The idea is to create a binary tree of shuffles, where
the first layer performs pairwise shuffles of the input vectors placing each
input element into the correct lane, and the rest of the tree blends these
shuffles together.
This doesn't try to be smart and create any sort of "optimal" shuffles.
The assumption is that even a "poor" shuffle sequence is better than extracting
and inserting the elements one by one.
Differential Revision: https://reviews.llvm.org/D24683
llvm-svn: 283480
Jim Ingham [Thu, 6 Oct 2016 18:57:30 +0000 (18:57 +0000)]
StringRef::front asserts on empty strings, causing "break modify -c ''" to assert.
Added a check for empty at the point where we were going to crash.
<rdar://problem/
28654032>
llvm-svn: 283479
Michael Ilseman [Thu, 6 Oct 2016 18:30:26 +0000 (18:30 +0000)]
Revert "Add -strip-nonlinetable-debuginfo capability"
This reverts commit r283473.
Reverted until review is completed.
llvm-svn: 283478
Todd Fiala [Thu, 6 Oct 2016 18:25:54 +0000 (18:25 +0000)]
xfail TestDarwinLogBasic.py for i386 macOS
Tracked by:
rdar://
28655626
llvm-svn: 283477
Matt Arsenault [Thu, 6 Oct 2016 18:12:13 +0000 (18:12 +0000)]
AMDGPU: Don't fold undef uses or copies with implicit uses
llvm-svn: 283476
Matt Arsenault [Thu, 6 Oct 2016 18:12:07 +0000 (18:12 +0000)]
AMDGPU: Remove scheduling info from si_mask_branch
llvm-svn: 283475
Valentina Giusti [Thu, 6 Oct 2016 18:05:12 +0000 (18:05 +0000)]
Add bound violation handling for Intel(R) Memory Protection Extensions (Intel(R) MPX)
Summary:
This patch adds support for handling the SIGSEGV signal with 'si_code ==
SEGV_BNDERR', which is thrown when a bound violation is caught by the
Intel(R) MPX technology.
Differential Revision: https://reviews.llvm.org/D25329
llvm-svn: 283474
Michael Ilseman [Thu, 6 Oct 2016 17:58:38 +0000 (17:58 +0000)]
Add -strip-nonlinetable-debuginfo capability
This adds a new function to DebugInfo.cpp that takes an llvm::Module
as input and removes all debug info metadata that is not directly
needed for line tables, thus effectively stripping all type and
variable information from the module.
The primary motivation for this feature was the bitcode work flow
(cf. http://lists.llvm.org/pipermail/llvm-dev/2016-June/100643.html
for more background). This is not wired up yet, but will be in
subsequent patches. For testing, the new functionality is exposed to
opt with a -strip-nonlinetable-debuginfo option.
The secondary use-case (and one that works right now!) is as a
reduction pass in bugpoint. I added two new bugpoint options
(-disable-strip-debuginfo and -disable-strip-debug-types) to control
the new features. By default it will first attempt to remove all debug
information, then only the type info, and then proceed to hack at any
remaining MDNodes.
llvm-svn: 283473
Ed Maste [Thu, 6 Oct 2016 17:55:22 +0000 (17:55 +0000)]
Match printf field width arg and type
A '*' as a field width or precision specifies that the field width or
precision is supplied by an int argument.
llvm-svn: 283472
Matt Arsenault [Thu, 6 Oct 2016 17:54:30 +0000 (17:54 +0000)]
AMDGPU: Remove leftover implicit operands when folding immediates
When constant folding an operation to a copy or an immediate
mov, the implicit uses/defs of the old instruction were left behind,
e.g. replacing v_or_b32 left the implicit exec use on the new copy.
llvm-svn: 283471
Matt Arsenault [Thu, 6 Oct 2016 17:19:11 +0000 (17:19 +0000)]
Reapply "AMDGPU: Support using tablegened MC pseudo expansions"
Fix bad merge
llvm-svn: 283470
Matt Arsenault [Thu, 6 Oct 2016 17:08:01 +0000 (17:08 +0000)]
Revert "AMDGPU: Support using tablegened MC pseudo expansions"
llvm-svn: 283469
Jim Ingham [Thu, 6 Oct 2016 17:01:00 +0000 (17:01 +0000)]
These test cases don't test different debug info formats.
llvm-svn: 283468
Matt Arsenault [Thu, 6 Oct 2016 16:56:41 +0000 (16:56 +0000)]
AMDGPU: Support using tablegened MC pseudo expansions
Make the necessary refactorings to make use of PseudoInstExpansion
llvm-svn: 283467
Vedant Kumar [Thu, 6 Oct 2016 16:45:40 +0000 (16:45 +0000)]
[ubsan] Turn on 'Has CXXABI' to enable support for -fsanitize=vptr on Darwin
Differential Revision: https://reviews.llvm.org/D24990
llvm-svn: 283466
Brian Gesiak [Thu, 6 Oct 2016 16:39:22 +0000 (16:39 +0000)]
[docs] Add PR to Lexicon
Summary:
The acronym PR could be ambiguous to some users, especially those who
are used to interpreting it as GitHub's "pull request".
Reviewers: ddunbar, jordan_rose, void, beanz
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D25331
llvm-svn: 283465
Matt Arsenault [Thu, 6 Oct 2016 16:20:41 +0000 (16:20 +0000)]
BranchRelaxation: Support expanding unconditional branches
AMDGPU needs to expand unconditional branches in a new
block with an indirect branch.
llvm-svn: 283464
Krzysztof Parzyszek [Thu, 6 Oct 2016 16:18:04 +0000 (16:18 +0000)]
[Hexagon] Avoid replacing full regs with subregisters in tied operands
Doing so will result in the two-address pass generating incorrect code.
llvm-svn: 283463
Matt Arsenault [Thu, 6 Oct 2016 16:00:58 +0000 (16:00 +0000)]
BranchRelaxation: Account for function alignment
llvm-svn: 283462
Valentina Giusti [Thu, 6 Oct 2016 15:49:10 +0000 (15:49 +0000)]
Improve test for Intel(R) MPX registers.
Summary:
Let the inferior test code determine if CPU and kernel support Intel(R)
MPX and cleanup test script.
Differential Revision: https://reviews.llvm.org/D25328
llvm-svn: 283461
David Sheinkman [Thu, 6 Oct 2016 15:47:36 +0000 (15:47 +0000)]
[OpenMP] Check if the template specialization is mappable instead of specialized template Differential Revision: https://reviews.llvm.org/D25252
llvm-svn: 283460