6682 Commits

Author SHA1 Message Date
Alex Bradbury
4387849902 [Docs] Update CodingStandards to recommend range-based for loops
The CodingStandards section on avoiding the re-evaluation of end() hasn't been
updated since range-based for loops were adopted in the LLVM codebase. This
patch adds a very brief section that documents how range-based for loops
should be used wherever possible. It also moves example code in
CodingStandards to use range-based for loops and auto when appropriate.

Differential Revision: https://reviews.llvm.org/D37264


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312236 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-31 12:34:20 +00:00
Sean Eveson
10edef110e [llvm-cov] Read in function names for filtering from a text file.
Summary: Add a -name-whitelist option, which behaves in the same way as -name, but it reads in multiple function names from the given input file(s).

Reviewers: vsk

Reviewed By: vsk

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D37111

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312227 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-31 09:11:31 +00:00
Hans Wennborg
d3f69d797e docs: remove dead doxygen tarball link
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312142 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-30 17:40:28 +00:00
Reid Kleckner
87b9591eee [cmake] Stop putting the revision info in LLVM_VERSION_STRING
Summary:
This reduces the number of build actions after a no-op commit from
thousands to about six, which should be acceptable. If six actions is
still too many, developers can disable the LLVM_APPEND_VC_REV cmake
option.

llvm-config.h is a widely included header that should rarely change.
Before this patch, it would change after every re-configure. Very few
users of llvm-config.h need to know the precise version, and those that
do can migrate to incorporating LLVM_REVISION as provided by
llvm/Support/VCSRevision.h.

This should bring LLVM back to the behavior that it had before r306858
from June 30 2017. Most LLVM tools will now print a version string like
"6.0.0svn" instead of "6.0.0-git-c40c2a23de4".

Fixes PR34308

Reviewers: pcc, rafael, hans

Subscribers: mgorny, llvm-commits

Differential Revision: https://reviews.llvm.org/D37272

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312043 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-29 21:44:21 +00:00
Kostya Kortchinsky
db2668663f [docs] Fix Scudo documentation error
Summary: No Pygments lexer found for "none".

Reviewers: flowerhack

Reviewed By: flowerhack

Differential Revision: https://reviews.llvm.org/D37270

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312027 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-29 19:54:19 +00:00
Kostya Kortchinsky
a135575b29 Update Scudo allocator documentation.
Summary:
QuarantineSizeMb is deprecated, and QuarantineChunksUpToSize has been added as a new tunable option.


Reviewers: cryptoad

Reviewed By: cryptoad

Differential Revision: https://reviews.llvm.org/D37238

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312025 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-29 19:42:50 +00:00
Lang Hames
5a19c2915c [docs] In the CMake primer, correct the description of the ARGV/ARGN variables.
ARGN is the sublist of unnamed arguments, not the count of the arguments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311632 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-24 05:38:39 +00:00
Wei Ding
75acc65cb3 Add ‘llvm.experimental.constrained.fma‘ Intrinsic.
Differential Revision: http://reviews.llvm.org/D36335

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311629 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-24 04:18:24 +00:00
Pete Couperus
333b7c6706 Test commit.
Fix instrinsic -> intrinsic typo.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311598 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-23 20:58:22 +00:00
Erich Keane
93fb9f24a3 Emit section information for extern variables
Update IR generated to retain section information for external declarations. 
This is related to https://reviews.llvm.org/D36487

Patch By: eandrews
Differential Revision: https://reviews.llvm.org/D36712


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311459 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-22 15:30:43 +00:00
Brian Gesiak
0d642908ab [Lexicon] Add "GEP"
Summary:
`getelementptr` is frequently abbreviated as "GEP", often in source files that
do not ever reference the full name of the instruction. Add it to the Lexicon,
in case readers go to look for what it means there.

Test plan:
1. `ninja sphinx`
2. Confirm that the rendered docs HTML contains the new "GEP" entry



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311168 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-18 15:35:53 +00:00
Alex Bradbury
b24452bf84 Refine report_fatal_error guidance after post-commit review
Use text suggested by Justin Bogner in post-commit review of r311146 
<http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20170814/479898.html>, 
which makes it clear that report_fatal_error shouldn't be used when there is a 
practicable alternative. Also make this clearer in CodingStandards.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311147 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-18 06:45:34 +00:00
Alex Bradbury
d8824ebc53 Give guidance on report_fatal_error in CodingStandards.rst and ProgrammersManual.rst
The current ProgrammersManual.rst document has a lot of well-written 
documentation on error handling thanks to @lhames. It suggests errors can be 
split cleanly into "programmatic" and "recoverable" errors. However, the 
reality in current LLVM seems to be there are a number of cases where a 
non-programmatic error is not easily recoverable. Therefore, add a note to 
indicate the existence of report_fatal_error for these cases. I've also added 
a reminder to CodingStandards.rst in the section on assertions, to indicate 
that llvm_unreachable and assertions should not be relied upon to report 
errors triggered by user input.

The ProgrammersManual is also silent on the use of LLVMContext::diagnose, 
which is used in BPF+WebAssembly+AMDGPU to report some errors during 
instruction selection. I don't address that in this patch, as it's not quite 
clear how to fit in to the current error handling story

Differential Revision: https://reviews.llvm.org/D36826


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311146 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-18 05:29:21 +00:00
Lang Hames
35adac2ab6 [docs] Tweak phrasing of the varargs explanation in the command section of the
CMake primer.

This moves the introduction of the ARGV/ARGN variables up to immmediately follow
the introduction of the concept of variable argument functions, and explicitly
connects this concept to C varargs functions.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311113 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-17 18:21:53 +00:00
Lang Hames
d17c970ac7 [docs] Fix typo and tweak wording of special variable handling in CMake primer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@311112 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-17 18:00:28 +00:00
Quentin Colombet
8e98e02784 Reapply "[GlobalISel] Remove the GISelAccessor API."
This reverts commit r310425, thus reapplying r310335 with a fix for link
issue of the AArch64 unittests on Linux bots when BUILD_SHARED_LIBS is ON.

Original commit message:
[GlobalISel] Remove the GISelAccessor API.

Its sole purpose was to avoid spreading around ifdefs related to
building global-isel. Since r309990, GlobalISel is not optional anymore,
thus, we can get rid of this mechanism all together.

NFC.

----
The fix for the link issue consists in adding the GlobalISel library in
the list of dependencies for the AArch64 unittests. This dependency
comes from the use of AArch64Subtarget that needs to know how
to destruct the GISel related APIs when being detroyed.

Thanks to Bill Seurer and Ahmed Bougacha for helping me reproducing and
understand the problem.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310969 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-15 22:31:51 +00:00
Tony Tye
1a0450faf1 Update AMDGPUUsage.rst documentation:
1. Correct description of the kernel initial state for FLAT_SCRATCH_INIT.
    2. Add link to GFX9 architecture documentation.
    3. Update product names.
    4. Rename note record from NT_AMD_AMDGPU_METADATA to NT_AMD_AMDGPU_HSA_METADATA and move description to the AMDHSA coding convention section.
    5. Minor typo corrections.

Differential Revision: https://reviews.llvm.org/D36549


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310954 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-15 20:47:41 +00:00
Lang Hames
a7007af1c7 [ORC][Kaleidoscope] Update Chapter 1 of BuildingAJIT to incorporate recent ORC
API changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310947 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-15 19:20:10 +00:00
Steven Wu
8cf654979b [Doc] Update LangRef for new Module Flag Behavior
Summary:
Add the documentation for the new module flag behavior. The new
ModFlagBehavior is added in r303590.

Reviewers: tejohnson

Reviewed By: tejohnson

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D36557

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310926 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-15 16:16:33 +00:00
Andrew Kaylor
68d0bd1ed4 Add strictfp attribute to prevent unwanted optimizations of libm calls
Differential Revision: https://reviews.llvm.org/D34163



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310885 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-14 21:15:13 +00:00
Sean Eveson
8574d59a97 [llvm-cov] Add an option which maps the location of source directories on another machine to your local copies
Summary:
This patch adds the -path-equivalence option (example: llvm-cov show -path-equivalence=/origin/path,/local/path) which maps the source code path from one machine to another when using `llvm-cov show`. This is similar to the -filename-equivalence option, but doesn't require you to specify all the source files on the command line.

This allows you to generate the coverage data on one machine (e.g. in a CI system), and then use llvm-cov on another machine where you have the same code base on a different path.

Reviewers: vsk

Reviewed By: vsk

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D36391

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310827 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-14 10:20:12 +00:00
Sylvestre Ledru
0fa72c3eef Fix some minor typos in the llvm XRay exemple
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310777 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-12 15:08:11 +00:00
Kostya Serebryany
0a4c4a2bdd [libFuzzer] recommend Clang Coverage for coverage visualization
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310751 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-11 20:32:47 +00:00
Zachary Turner
88fcc3a2fb Add documentation for llvm-pdbutil.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310744 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-11 19:00:22 +00:00
George Karpenkov
41ae6058c0 Update libFuzzer documentation for -fsanitize=fuzzer-no-link flag
Differential Revision: https://reviews.llvm.org/D36602

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310734 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-11 17:23:45 +00:00
Craig Topper
ebdb044915 [DebugCounter] Move the semicolon out of the DEBUG_COUNTER macro and require it to be placed at the end of each use.
This make it consistent with STATISTIC which it will often appears near.

While there move one DEBUG_COUNTER instance out of an anonymous namespace. It's already declaring a static variable so the namespace is unnecessary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310637 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-10 17:48:11 +00:00
Matthias Braun
21784bb6fb LangRef: Fix/improve cmpxchg wording
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310533 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-09 22:22:04 +00:00
Craig Topper
fe294dbbe4 [Docs] Remove a stray period from a code example in the Programmer's Manual.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310520 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-09 20:55:33 +00:00
Quentin Colombet
f6b5ea76fb Revert "[GlobalISel] Remove the GISelAccessor API."
This reverts commit r310115.

It causes a linker failure for the one of the unittests of AArch64 on one
of the linux bot:
http://lab.llvm.org:8011/builders/clang-ppc64le-linux-multistage/builds/3429

: && /home/fedora/gcc/install/gcc-7.1.0/bin/g++   -fPIC
-fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W
-Wno-unused-parameter -Wwrite-strings -Wcast-qual
-Wno-missing-field-initializers -pedantic -Wno-long-long
-Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment
-ffunction-sections -fdata-sections -O2
-L/home/fedora/gcc/install/gcc-7.1.0/lib64 -Wl,-allow-shlib-undefined
-Wl,-O3 -Wl,--gc-sections
unittests/Target/AArch64/CMakeFiles/AArch64Tests.dir/InstSizes.cpp.o  -o
unittests/Target/AArch64/AArch64Tests
lib/libLLVMAArch64CodeGen.so.6.0.0svn lib/libLLVMAArch64Desc.so.6.0.0svn
lib/libLLVMAArch64Info.so.6.0.0svn lib/libLLVMCodeGen.so.6.0.0svn
lib/libLLVMCore.so.6.0.0svn lib/libLLVMMC.so.6.0.0svn
lib/libLLVMMIRParser.so.6.0.0svn lib/libLLVMSelectionDAG.so.6.0.0svn
lib/libLLVMTarget.so.6.0.0svn lib/libLLVMSupport.so.6.0.0svn -lpthread
lib/libgtest_main.so.6.0.0svn lib/libgtest.so.6.0.0svn -lpthread
-Wl,-rpath,/home/buildbots/ppc64le-clang-multistage-test/clang-ppc64le-multistage/stage1/lib
&& :
unittests/Target/AArch64/CMakeFiles/AArch64Tests.dir/InstSizes.cpp.o:(.toc+0x0):
undefined reference to `vtable for llvm::LegalizerInfo'
unittests/Target/AArch64/CMakeFiles/AArch64Tests.dir/InstSizes.cpp.o:(.toc+0x8):
undefined reference to `vtable for llvm::RegisterBankInfo'

The particularity of this bot is that it is built with
BUILD_SHARED_LIBS=ON

However, I was not able to reproduce the problem so far.
Reverting to unblock the bot.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310425 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-08 22:22:30 +00:00
Konstantin Zhuravlyov
84577c6f35 AMDGPU: Also remove SI from docs
Differential Revision: https://reviews.llvm.org/D36424


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310335 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-08 04:28:31 +00:00
Quentin Colombet
f646c27631 [GlobalISel] Remove the GISelAccessor API.
Its sole purpose was to avoid spreading around ifdefs related to
building global-isel. Since r309990, GlobalISel is not optional anymore,
thus, we can get rid of this mechanism all together.

NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310115 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-04 20:15:46 +00:00
George Karpenkov
ba96863e68 [libFuzzer tests] Only enable libFuzzer tests if
-DLIBFUZZER_ENABLE_TESTS=ON is set.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310100 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-04 19:29:16 +00:00
George Karpenkov
32fab3343b Port libFuzzer tests to LIT. Do not require two-stage build for check-fuzzer.
This revision ports all libFuzzer tests apart from the unittest to LIT.
The advantages of doing so include:

 - Tests being self-contained
 - Much easier debugging of a single test
 - No need for using a two-stage compilation

The unit-test is still compiled using CMake, but it does not need a
freshly built compiler.

NOTE: The previous two-stage bot configuration will NOT work, as in the
second stage build LLVM_USE_SANITIZER is set, which disables ASAN from
being built.
Thus bots will be reconfigured in the next few commits.

Differential Revision: https://reviews.llvm.org/D36295

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310075 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-04 17:19:45 +00:00
Vedant Kumar
f6b53455df [llvm-cov] Respect the value of the -show-instantiations option
Make `-show-instantiations=false` actually skip displaying instantiation
sub-views, instead of simply ignoring the option.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309903 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-02 23:35:24 +00:00
Keith Wyss
630a4acf81 Xray docs with description of Flight Data Recorder binary format.
Summary:
Adding a new restructuredText file to document the trace format produced with
an FDR mode handler and read by llvm-xray toolset.

Fixed two problems in the documentation from differential review. One bad table
and a missing link in the toc.

Original commit was e97c5836a77db803fe53319c53f3bf8e8b26d2b7.

Reviewers: dberris, pelikan

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D36041

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309891 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-02 21:47:27 +00:00
Keith Wyss
3e9e87e5ea Revert "Xray docs with description of Flight Data Recorder binary format."
This reverts commit 3462b8ad41a840fd54dbbd0d3f2a514c5ad6f656.

The docs-llvm-html target failed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309842 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-02 17:36:52 +00:00
Keith Wyss
e97c5836a7 Xray docs with description of Flight Data Recorder binary format.
Summary:
Adding a new restructuredText file to document the trace format produced with
an FDR mode handler and read by llvm-xray toolset.

Reviewers: dberris, pelikan

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D36041

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309836 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-02 17:27:20 +00:00
Vedant Kumar
e72b881e28 [llvm-cov] Allow specifying distinct architectures for each loaded binary
The coverage tool needs to know which slice to look at when it's handed
a universal binary. Some projects need to look at aggregate coverage
reports for a variety of slices in different binaries: this patch adds
support for these kinds of projects to llvm-cov.

rdar://problem/33579007

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309747 91177308-0d34-0410-b5e6-96231b3b80d8
2017-08-01 21:23:26 +00:00
Sumanth Gundapaneni
2286bba978 Add documentation for the attribute "no-jump-tables"
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309445 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-28 22:26:22 +00:00
Adrian Prantl
abecca79fb Reword sentence in LangRef
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309431 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-28 20:44:29 +00:00
Adrian Prantl
5d0334a48c Remove the obsolete offset parameter from @llvm.dbg.value
There is no situation where this rarely-used argument cannot be
substituted with a DIExpression and removing it allows us to simplify
the DWARF backend. Note that this patch does not yet remove any of
the newly dead code.

rdar://problem/33580047
Differential Revision: https://reviews.llvm.org/D35951

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309426 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-28 20:21:02 +00:00
Nuno Lopes
2cc32b10c0 [docs] change a few code-blocks to llvm from text
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309117 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-26 14:11:23 +00:00
Stephen Hines
75c17877dc [docs] Fix a typo: iteratation -> iteration
Reviewers: dgross

Reviewed By: dgross

Subscribers: dgross, llvm-commits

Differential Revision: https://reviews.llvm.org/D35822

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308994 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-25 17:52:55 +00:00
Kostya Serebryany
a575cf69b3 [libFuzzer] enable reduce_inputs=1 by default (seems to be a big win usually)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308541 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-19 22:10:30 +00:00
Joel Jones
d5c3125bd4 [docs] Document how to debug instruction scheduling model generation
Describe:

+ Exact tablegen command and how to get it
+ tablegen command debug option for subtarget generation
+ Use of schedcover.py on the debug output to determine coverage

Differential Revision: https://reviews.llvm.org/D35058 


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308476 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-19 14:10:42 +00:00
Hans Wennborg
f1a2d4d9d7 Clear release notes for 6.0.0
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308474 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-19 14:09:16 +00:00
Hans Wennborg
89fb1f68e3 Update trunk version to 6.0.0svn
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308442 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-19 12:19:01 +00:00
Hiroshi Inoue
4ea9a7811e fix typos in a document; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308331 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-18 17:52:47 +00:00
Nuno Lopes
4b03014d14 [docs] AliasAnalysis: clarify that PartialAlias doesn't enforce
objects to start at the same address

As discussed on the ML, there's consensus that this is what the implementations
do and it seems sensible.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308090 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-15 09:09:24 +00:00
George Karpenkov
92aa19c981 [lit] add a -vv option to echo all executed commands.
Debugging LIT scripts can be rather painful, as LIT directly does not
specify which line has failed.
Rather, FileCheck is expected to report the failing location, but it can
be often ambiguous if multiple commands are tested against the same
prefix.  This change adds a -vv option, which echoes all output.
Then detecting the error becomes straightforward: last printed line is
the failing one.

Of course, it could be desired to try to get failing line number
directly from bash, but it involves excessive hacks on older bash
versions (cf.
https://stackoverflow.com/questions/24398691/how-to-get-the-real-line-number-of-a-failing-bash-command)

Differential Revision: https://reviews.llvm.org/D35330

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@307938 91177308-0d34-0410-b5e6-96231b3b80d8
2017-07-13 19:26:27 +00:00