Commit Graph

350821 Commits

Author SHA1 Message Date
Vedant Kumar 381bdd546c unittest: Disable MachineInstrClone.CopyCallSiteInfo on Windows
A bot error (http://45.33.8.238/win/12463/step_11.txt) reports 'unknown
file: error: SEH exception with code 0x3221225477 thrown in the test
body', but I don't know what causes this.

It looks like this has come up before, but afaict the root causes could
be different:

  https://reviews.llvm.org/rL329195, and in
  http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20180910/587425.html

I tried testing locally with UBSan, but that didn't uncover anything.
2020-04-08 12:11:53 -07:00
Fangrui Song 969b91af73 [Driver] Default arm-linux-androideabi to -z max-page-size=4096
Similar to D55029. The requirement arises when discussing increasing
default max-page-size for lld ARM (D77330).

For the record, the default max-page-size on the 3 commonly used linkers:

* GNU ld since 2014 (https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=7572ca8989ead4c3425a1500bc241eaaeffa2c89) defaults to 65536
* GNU gold remains 4096
* lld<=10 uses 4096. lld from 11 onwards will use 65536 (D77330)

Reviewed By: srhines, thieta

Differential Revision: https://reviews.llvm.org/D77746
2020-04-08 12:05:28 -07:00
Louis Dionne 82bec93181 [libc++] Update the documentation for running Lit to reflect reality
Our documentation for running LIT is basically wrong, since it doesn't
mention `llvm-lit`, and nothing works without it. Note that this
documentation improvement reflects the current reality outside of
the recent efforts on improving the test suite. My goal is to document
the current way of running the test suite, so that everybody agrees on
how things currently work. As the configuration system for libc++ gets
simplified, we can come back and keep this documentation up to date to
reflect those changes.

Differential Revision: https://reviews.llvm.org/D77673
2020-04-08 15:04:16 -04:00
Michael Wyman 3d4d25fb4d First test commit - empty 2020-04-08 11:31:51 -07:00
Matt Arsenault c42cc7fd24 CodeGen: Use Register in MachineSSAUpdater 2020-04-08 14:29:01 -04:00
Artem Belevich d2e498b172 [CUDA] Improve testing of libdevice detection.
Added new testcases for libdevice in CUDA-9+ and removed unused checks.

Differential Revision: https://reviews.llvm.org/D77688
2020-04-08 11:19:45 -07:00
Artem Belevich a9627b7ea7 [CUDA] Add partial support for recent CUDA versions.
Generate PTX using newer versions of PTX and allow using sm_80 with CUDA-11.
None of the new features of CUDA-10.2+ have been implemented yet, so using these
versions will still produce a warning.

Differential Revision: https://reviews.llvm.org/D77670
2020-04-08 11:19:44 -07:00
Artem Belevich 33386b20aa [CUDA] Simplify GPU variant handling. NFC.
Instead of hardcoding individual GPU mappings in multiple functions, keep them
all in one table and use it to look up the mappings.

We also don't care about 'virtual' architecture much, so the API is trimmed down
down to a simpler GPU->Virtual arch name lookup.

Differential Revision: https://reviews.llvm.org/D77665
2020-04-08 11:19:43 -07:00
Davide Italiano d51b38f1b3 [DWARF] Not all the constant variables are "static".
Fixes rdar://problem/61402307

Differential Revision: https://reviews.llvm.org/D77698
2020-04-08 11:07:19 -07:00
Vedant Kumar 48e65fc630 MachineFunction: Copy call site info when duplicating insts
Summary:
Preserve call site info for duplicated instructions. We copy over the
call site info in CloneMachineInstrBundle to avoid repeated calls to
copyCallSiteInfo in CloneMachineInstr.

(Alternatively, we could copy call site info higher up the stack, e.g.
into TargetInstrInfo::duplicate, or even into individual backend passes.
However, I don't see how that would be safer or more general than the
current approach.)

Reviewers: aprantl, djtodoro, dstenb

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77685
2020-04-08 11:06:14 -07:00
Walter Erquinigo be3f8a8e1b [commands] Support autorepeat in SBCommands
Summary:
This adds support for commands created through the API to support autorepeat.
This covers the case of single word and multiword commands.

Comprehensive tests are included as well.

Reviewers: labath, clayborg

Subscribers: lldb-commits

Tags: #lldb

Differential Revision: https://reviews.llvm.org/D77444
2020-04-08 10:54:14 -07:00
Walter Erquinigo 8e40987e18 Fix e796c77b26
Failure:
http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/14556/testReport/junit/lldb-api/tools_lldb-vscode_breakpoint-events/TestVSCode_breakpointEvents_py/

Diff:
[lldb-vscode] Correctly return source mapped breakpoints for setBreakpoints request
https://reviews.llvm.org/D76968

It failed a test TestVSCode_breakpointEvents that only runs Darwin that needed to be updated to match the current logic.
The change is simple.
2020-04-08 10:48:01 -07:00
Matt Arsenault 586769cce2 DAG: Use Register 2020-04-08 13:44:31 -04:00
Sean Fertile d0b57b41f4 [PowerPC][AIX][NFC] Replace deprecated getByValAlign call.
Replace call to deprecated 'getByValAlign()' with
'getNonZeroByValAlign()'.
2020-04-08 13:27:39 -04:00
Paula Toth 66d00feb18 [libc][NFC] Make all top of file comments consistent.
Summary:
Made all header files consistent based of this documentation: https://llvm.org/docs/CodingStandards.html#file-headers.
And did the same for all source files top of file comments.

Reviewers: sivachandra, abrachet

Reviewed By: sivachandra, abrachet

Subscribers: MaskRay, tschuett, libc-commits

Tags: #libc-project

Differential Revision: https://reviews.llvm.org/D77533
2020-04-08 10:18:37 -07:00
Simon Pilgrim 94121c60d6 [InstCombine] Regenerate phi-preserve-ir-flags.ll test checks to fix issue reported on D77354 2020-04-08 18:13:24 +01:00
zoecarver b25ec45809 Fix __is_pointer builtin type trait to work with Objective-C pointer types.
Summary: 5ade17e broke __is_pointer for Objective-C pointer types. This patch fixes the builtin and re-applies the change to type_traits.

Tags: #clang, #libc

Differential Revision: https://reviews.llvm.org/D77519
2020-04-08 10:02:53 -07:00
Simon Pilgrim c8dfd0008b [PowerPC] Regenerate optcmp.ll test checks to fix issue reported on D77354 2020-04-08 18:00:43 +01:00
Walter Erquinigo e796c77b26 [lldb-vscode] Correctly return source mapped breakpoints for setBreakpoints request
Summary:
When using source maps for a breakpoint, in order to find the actual source that breakpoint has resolved, we
need to use a query similar to what CommandObjectSource::DumpLinesInSymbolContexts does, which is the logic
used by the CLI to display the source line at a given breakpoint. That's necessary because from a breakpoint
location you only have an address, which points to the original source location, not the source mapped one.

in the setBreakpoints request handler, we haven't been doing such query and we were returning the original
source location, which was breaking the UX of VSCode, as many breakpoints were being set but not displayed
in the source file next to each line. Besides, clicking the source path of a breakpoint in the breakpoints
view in the debug tab was not working for this case, as VSCode was trying to open a non-existent file, thus
showing an error to the user.

Ideally, we should do the query mentioned above to find the actual source location to respond to the IDE,
however, that query is expensive and users can have an arbitrary number of breakpoints set. As a simpler fix,
the request sent by VSCode already contains the full source path, which exists because the user set it from
the IDE itself, so we can simply reuse it instead of querying from the SB API.

I wrote a test for this, and found out that I had to move SetSourceMapFromArguments after RunInitCommands in
lldb-vscode.cpp, because an init command used in all tests is `settings clear -all`, which would clear the
source map unless specified after initCommands. And in any case, I think it makes sense to have initCommands
run before anything the debugger would do.

Reviewers: clayborg, kusmour, labath, aadsm

Subscribers: lldb-commits

Tags: #lldb

Differential Revision: https://reviews.llvm.org/D76968
2020-04-08 09:52:59 -07:00
Uday Bondhugula ae8ebeca51 [MLIR] Fix test case typos in unroll.mlir
Fix check line typos in test/Dialect/Affine/unroll.mlir.

Differential Revision: https://reviews.llvm.org/D77738
2020-04-08 22:21:07 +05:30
zoecarver 7a0dc1a9e7 [libc++] Remove std::optional from ObjC is_scalar test.
std::optional requires C++17. Instead of only running the test above
C++14, this commit removes uses of std::optional from the test (it's
already tested in block.objc.pass.mm).
2020-04-08 09:44:49 -07:00
Simon Pilgrim ca5af4b649 [PowerPC] Fix fold-rlwinm.mir typos in checks to fix issue reported on D77354 2020-04-08 17:42:07 +01:00
Fangrui Song a27a7b98cd [ELF] --warn-backrefs: don't warn if -u/--export-dynamic-symbol
Reviewed By: grimar

Differential Revision: https://reviews.llvm.org/D77630
2020-04-08 09:33:22 -07:00
Nikita Popov 4007e5f32e [RDA] Try to fix build, again (NFC) 2020-04-08 18:30:53 +02:00
Simon Pilgrim 68c6d7e11c [PowerPC] Fix fold-frame-offset-using-rr.mir typos in checks to fix issue reported on D77354
Extra spaces, copy+paste duplicates and missing test name check
2020-04-08 17:18:01 +01:00
Nikita Popov b5d941ea58 [RDA] Try to fix build (NFC)
fuchsia-x86_64-linux builder fails with:

/b/fuchsia-x86_64-linux/llvm.src/llvm/include/llvm/ADT/TinyPtrVector.h:85:15:
error: no matching conversion for C-style cast from 'nullptr_t' to 'llvm::ReachingDef'
    RHS.Val = (EltTy)nullptr;

Let's see whether adding an explicit nullptr_t constructor helps.
2020-04-08 18:15:01 +02:00
Matt Arsenault dcce3ef1d2 FastISel: Partially use Register
Doesn't try to convert the cases that depend on generated code.
2020-04-08 12:10:58 -04:00
Matt Arsenault 7a46e36d51 CodeGen: Use Register more in CallLowering
Some of these MCPhysReg uses should probably be MCRegister, but right
now this would require more invasive changes.
2020-04-08 12:10:58 -04:00
Matt Arsenault ca0ace7298 CodeGen: Use Register in MachineBasicBlock 2020-04-08 12:10:58 -04:00
Matt Arsenault 84aa58cbe2 CodeGen: Use Register in TargetLowering 2020-04-08 12:10:58 -04:00
Simon Pilgrim 54502476e7 [AMDGPU] Refresh fmin_legacy.ll checks to fix issue reported on D77354
Some of the condition codes had inverted since this was generated
2020-04-08 17:05:29 +01:00
Kirill Naumov 0125db9ab2 [TimePasses] Small fix in "-time-passes" flag that makes it more stable
Adds StringMap for TimingData.

Differential Revision: https://reviews.llvm.org/D76946
Reviewed By: fedor.sergeev
2020-04-08 15:59:45 +00:00
Andy Davis 7006daa548 [MLIR][Vector] Update ShapeCastOp folder to use producer-consumer value forwarding.
Summary:
Update ShapeCastOp folder to use producer-consumer value forwarding.
Support is added for tracking sub-vectors through trivial shape cast operations,
where the sub-vector shape is preserved across shape cast operations and only
leading ones are added or removed.
Support is preserved for cancelling shape cast operations.
One unit test is added and two are updated.

Reviewers: aartbik, nicolasvasilache

Reviewed By: aartbik, nicolasvasilache

Subscribers: frgossen, mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, arpith-jacob, mgester, lucyrfox, liufengdb, Joonsoo, grosul1, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77253
2020-04-08 08:55:37 -07:00
Nikita Popov 952c274159 [RDA] Use TinyPtrVector to store reaching defs (NFCI)
RDA currently uses SmallVector<int, 1> to store reaching definitions.
A SmallVector<int, 1> is 24 bytes large, and X86 currently has
164 register units, which means we need 3936 bytes per block.
If you have a large function with 1000 blocks, that's already 4MB.

A large fraction of these reg units will not have any reaching defs
(say, those corresponding to zmm registers), and many will have just
one. A TinyPtrVector serves this use-case much better, as it only
needs 8 bytes per register if it has 0 or 1 reaching defs.

As the name implies, TinyPtrVector is designed to work with pointers,
so we need to add some boilerplate to treat our reaching def integers
as pointers, using an appropriate encoding. We need to keep the low
bit free for tagging, and make sure at least one bit is set to
distinguish the null pointer.

Differential Revision: https://reviews.llvm.org/D77513
2020-04-08 17:46:24 +02:00
Sean Fertile 8abfd2c3bb [PowerPC][AIX] Enable passing byval formal arguments in multiple registers.
Any or all the argument registers can be used to pass a byval formal
argument, with the limitation that the argument must fit in the
available registers (ie: is not split between registers and stack).

Differential Revision: https://reviews.llvm.org/D76902
2020-04-08 11:16:33 -04:00
Simon Pilgrim 5f25d22d3f [ARM] Fix thumb1_return_sequence typo in check to fix issue reported on D77354 2020-04-08 16:00:45 +01:00
Louis Dionne 6f1d558db4 [libunwind] Fix incorrect lit substitutions in tests
The LIT substitutions used in libunwind are the same as those from
libc++, and we forgot to update the libunwind tests after the libc++
substitutions started being delimited by braces.
2020-04-08 10:50:09 -04:00
Simon Pilgrim 7b65b1ecd1 [ARM] Fix misched-int-basic-thumb2.mir typo in check to fix issue reported on D77354 2020-04-08 15:48:18 +01:00
Bevin Hansson e4ca64f1ae [Fixed Point] Add triples to test cases.
This was causing some test failures.
2020-04-08 16:31:36 +02:00
Simon Pilgrim c6cd0936be [AARCH64][GISEL] arm64-fallback.ll - Refresh remarks to fix issue reported on D77354 2020-04-08 15:28:54 +01:00
Florian Hahn 4184b2e034 [DSE,MSSA] Add additional test cases for multi-path elimination (NFC).
This adds additional test cases for more scenarios and also with objects
that are accessible after the functions return and allocas.
2020-04-08 15:26:26 +01:00
Pierre Gousseau 937e63b8d5 [X86] Fix x86-header-warnings.c test not detecting regressions as intended.
Use -verify -fsyntax-only and expected-no-diagnostics as
recommended by Paul.

Reviewed By: probinson

Differential Revision: https://reviews.llvm.org/D77393
2020-04-08 15:22:44 +01:00
Simon Pilgrim 898e22908c [MemorySSA] invariant-groups.ll - add missing check to fix issue reported on D77354 2020-04-08 15:18:04 +01:00
Florian Hahn bbbec71609 [DSE.MSSA] Only use callCapturesBefore for calls.
callCapturesBefore always returns ModRef , if UseInst isn't a call. As
we only call it if we already know Mod is set, this only destroys the
Must bit for non-calls.
2020-04-08 15:12:33 +01:00
Florian Hahn a6353fdf3b [DSE,MSSA] Hoist getMemoryAccess call (NFC). 2020-04-08 15:10:05 +01:00
Clement Courbet 7c6514bc22 [llvm-exegesis] Fix build with !HAS_LIBPFM.
Fixes 9fb871866e.
2020-04-08 16:02:11 +02:00
Simon Pilgrim 0c2ab63689 [CodeExtractor] Fix typo in check label to fix issue reported on D77354 2020-04-08 14:59:15 +01:00
Uday Bondhugula 3156b5422e [MLIR] Fix more gcc-5 build issues from D77528
820c420d4e1c630b5ead285917c6ecdd2f5092ad did not really fix all build
issues by D77528. This gets rid of two unnecessary 'using' declarations.

Differential Revision: https://reviews.llvm.org/D77726
2020-04-08 19:21:50 +05:30
Alexey Lapshin 0ed2170dc4 [DWARFLinker][dsymutil] followup for 88c2137b6d
That patch is a followup for "Move DwarfStreamer into DWARFLinker".
It fixes build with LLVM_LINK_LLVM_DYLIB.
2020-04-08 16:46:52 +03:00
Clement Courbet 9fb871866e [llvm-exegesis][NFC] Let the pfm::Counter own the PerfHelper.
A perf helper is always only ever cretaed to be checked for validity
then passed as Counter ctor argument, never to be touched again.
Its lifetime should outlive that of the counter, and there is never any
reason to have two different counters of top of the perf helper.
Make sure these assumptions always hold by making the Counter consume the
PerfHelper.
2020-04-08 15:37:30 +02:00