llvm-project/llvm
Arthur Eubanks 9adbb5cb3a [SCEV] Fix ScalarEvolution tests under NPM
Many tests use opt's -analyze feature, which does not translate well to
NPM and has better alternatives. The alternative here is to explicitly
add a pass that calls ScalarEvolution::print().

The legacy pass manager RUNs aren't changing, but they are now pinned to
the legacy pass manager.  For each legacy pass manager RUN, I added a
corresponding NPM RUN using the 'print<scalar-evolution>' pass. For
compatibility with update_analyze_test_checks.py and existing test
CHECKs, 'print<scalar-evolution>' now prints what -analyze prints per
function.

This was generated by the following Python script and failures were
manually fixed up:

import sys
for i in sys.argv:
    with open(i, 'r') as f:
        s = f.read()
    with open(i, 'w') as f:
        for l in s.splitlines():
            if "RUN:" in l and ' -analyze ' in l and '\\' not in l:
                f.write(l.replace(' -analyze ', ' -analyze -enable-new-pm=0 '))
                f.write('\n')
                f.write(l.replace(' -analyze ', ' -disable-output ').replace(' -scalar-evolution ', ' "-passes=print<scalar-evolution>" ').replace(" | ", " 2>&1 | "))
                f.write('\n')
            else:
                f.write(l)

There are a couple failures still in ScalarEvolution under NPM, but
those are due to other unrelated naming conflicts.

Reviewed By: asbirlea

Differential Revision: https://reviews.llvm.org/D83798
2020-07-16 11:24:07 -07:00
..
benchmarks
bindings
cmake Revert "[CMake] Simplify CMake handling for zlib" 2020-07-14 19:56:10 -07:00
docs [docs] fix ident in llvm-exegesis.rst 2020-07-16 17:30:09 +00:00
examples [examples] fix ExceptionDemo 2020-07-11 12:38:27 -07:00
include MIR Statepoint refactoring. Part 1: Basic MI level changes. 2020-07-17 00:57:21 +07:00
lib [SCEV] Fix ScalarEvolution tests under NPM 2020-07-16 11:24:07 -07:00
projects
resources
runtimes [CMake][runtimes] Pass the CMAKE_ARGS to runtimes build correctly 2020-07-15 09:25:18 -07:00
test [SCEV] Fix ScalarEvolution tests under NPM 2020-07-16 11:24:07 -07:00
tools [llvm-exegesis] Add benchmark latency option on X86 that uses LBR for more precise measurements. 2020-07-16 12:12:46 -04:00
unittests Add hashing support for std::tuple 2020-07-16 19:01:25 +02:00
utils [gn build] Fix merge script mishap 2020-07-16 13:46:45 -04:00
.clang-format
.clang-tidy
.gitattributes
.gitignore [clangd] Store index in '.cache/clangd/index' instead of '.clangd/index' 2020-07-07 14:53:45 +02:00
CMakeLists.txt [CMake] Enforce the minimum CMake version to be at least 3.13.4 2020-07-16 10:49:11 -04:00
CODE_OWNERS.TXT
CREDITS.TXT
LICENSE.TXT
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT
configure
llvm.spec.in

README.txt

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.