Changes

Summary

  1. [NFC][sanitizer] Add basic hash test (details)
  2. [NFC][sanitizer] Add MurMur2Hash64Builder (details)
  3. [NFC][sanitizers] Add StackDepotBase Node::hash_type (details)
  4. [Sanitizers] intercept md5 and sha* apis on FreeBSD. (details)
  5. [clang] Allow printing 64 bit ints in diagnostics (details)
  6. Mark PassBuilder::addPass() as minsize (details)
  7. Revert "[clang] Allow printing 64 bit ints in diagnostics" (details)
  8. [GlobalISel] Clear unreachable blocks' contents after selection. (details)
  9. tsan: don't instrument runtime callbacks in tests (details)
  10. [mlir][linalg] Update OpDSL to use the newly introduced min and max ops. (details)
  11. [NPM] Automatic 'opt' pipeline reducer script. (details)
Commit dc603b0e53053772f48f13e1f8a3186f1e9990c7 by Vitaly Buka
[NFC][sanitizer] Add basic hash test

Differential Revision: https://reviews.llvm.org/D111176
The file was modifiedcompiler-rt/lib/sanitizer_common/tests/CMakeLists.txt
The file was addedcompiler-rt/lib/sanitizer_common/tests/sanitizer_hash_test.cpp
Commit 5ae9a3e4bf9351b0bc596bd4a9ec8e881377924d by Vitaly Buka
[NFC][sanitizer] Add MurMur2Hash64Builder

Depends on D111176.

Differential Revision: https://reviews.llvm.org/D111177
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_hash.h
The file was modifiedcompiler-rt/lib/sanitizer_common/tests/sanitizer_hash_test.cpp
Commit 3129aa5caf1f9b5c48ab708f43cb3fc5173dd021 by Vitaly Buka
[NFC][sanitizers] Add StackDepotBase Node::hash_type

Depends on D111177.

Differential Revision: https://reviews.llvm.org/D111182
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.h
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.cpp
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_stackdepotbase.h
Commit 18a7ebda99044473fdbce6376993714ff54e6690 by David CARLIER
[Sanitizers] intercept md5 and sha* apis on FreeBSD.

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D110989
The file was addedcompiler-rt/test/sanitizer_common/TestCases/FreeBSD/sha2.cpp
The file was addedcompiler-rt/test/sanitizer_common/TestCases/FreeBSD/md5.cpp
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_platform_limits_freebsd.cpp
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_platform_limits_freebsd.h
Commit edfff2f8b0435bc4af94bd3b41bf57244d84d993 by aeubanks
[clang] Allow printing 64 bit ints in diagnostics

Currently we're limited to 32 bit ints in diagnostics.
With support for 4GB alignments coming soon, we need to report 4GB as the max alignment allowed.
I've tested that this does indeed properly print 2^32.

Reviewed By: rsmith

Differential Revision: https://reviews.llvm.org/D111184
The file was modifiedclang/include/clang/AST/Attr.h
The file was modifiedclang/include/clang/AST/Decl.h
The file was modifiedclang/include/clang/AST/Type.h
The file was modifiedclang/include/clang/Sema/ParsedAttr.h
The file was modifiedclang/lib/Basic/Diagnostic.cpp
The file was modifiedclang/include/clang/AST/NestedNameSpecifier.h
The file was modifiedclang/include/clang/Basic/Diagnostic.h
Commit 0f37081f989bceab5521a740ac5e92b7638b208b by aeubanks
Mark PassBuilder::addPass() as minsize

PassBuilder.cpp is the slowest LLVM file to compile (if only building X86).
This makes PassBuilder.o a little faster to compile and a little smaller
as well.

These methods are not performance critical at all but are instantiated many times.

83M -> 72M instructions according to perf stat.

Reviewed By: rnk

Differential Revision: https://reviews.llvm.org/D110782
The file was modifiedllvm/include/llvm/IR/PassManager.h
The file was modifiedllvm/include/llvm/Transforms/Scalar/LoopPassManager.h
The file was modifiedllvm/include/llvm/Support/Compiler.h
Commit cb89d3739db746ea50eb50b7208e689126394391 by aeubanks
Revert "[clang] Allow printing 64 bit ints in diagnostics"

This reverts commit edfff2f8b0435bc4af94bd3b41bf57244d84d993.

Breaks clang-tidy.
The file was modifiedclang/include/clang/AST/Type.h
The file was modifiedclang/include/clang/Sema/ParsedAttr.h
The file was modifiedclang/include/clang/AST/Decl.h
The file was modifiedclang/include/clang/Basic/Diagnostic.h
The file was modifiedclang/include/clang/AST/Attr.h
The file was modifiedclang/include/clang/AST/NestedNameSpecifier.h
The file was modifiedclang/lib/Basic/Diagnostic.cpp
Commit 6bc64e24c38a42f2797ee64c78cb2d42b245b59e by Amara Emerson
[GlobalISel] Clear unreachable blocks' contents after selection.

If these blocks are unreachable, then we can discard all of the instructions.
However, keep the block around because it may have an address taken or the
block may have a stale reference from a PHI somewhere. Instead of finding
those PHIs and fixing them up, just leave the block empty.

Differential Revision: https://reviews.llvm.org/D111201
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/select-blockaddress.mir
The file was modifiedllvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp
The file was addedllvm/test/CodeGen/AArch64/GlobalISel/select-unreachable-blocks.mir
Commit 24af1ba605364e3e91a05e47d41c2aec1b7b2d26 by dvyukov
tsan: don't instrument runtime callbacks in tests

These runtime callbacks are supposed to be non-instrumented,
we can't handle runtime recursion well, nor can we afford
explicit recursion checks in the hot functions (memory access,
function entry/exit).
It used to work (not crash), but it won't work with the new runtime.
Mark all runtime callbacks as non-instrumented.

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D111157
The file was modifiedcompiler-rt/test/tsan/debugging.cpp
The file was modifiedcompiler-rt/test/tsan/java_symbolization.cpp
The file was modifiedcompiler-rt/test/tsan/Linux/double_race.cpp
The file was modifiedcompiler-rt/test/tsan/java_symbolization_legacy.cpp
Commit a744c7e962d85a6c0b2de19eff840755ef5c2a1d by gysit
[mlir][linalg] Update OpDSL to use the newly introduced min and max ops.

Implement min and max using the newly introduced std operations instead of relying on compare and select.

Reviewed By: dcaballe

Differential Revision: https://reviews.llvm.org/D111170
The file was modifiedmlir/test/python/dialects/linalg/opdsl/emit_structured_generic.py
The file was modifiedmlir/python/mlir/dialects/linalg/opdsl/lang/emitter.py
The file was modifiedmlir/test/python/integration/dialects/linalg/opsrun.py
The file was modifiedmlir/test/Dialect/Linalg/generalize-named-polymorphic-ops.mlir
The file was modifiedmlir/lib/Dialect/Linalg/IR/LinalgOps.cpp
Commit 91d15aa0b8bff10bd1ccf279418560d17fea52ff by markus.lavin
[NPM] Automatic 'opt' pipeline reducer script.

Script for automatic 'opt' pipeline reduction for when using the new
pass-manager (NPM). Based around the '-print-pipeline-passes' option.

The reduction algorithm consists of several phases (steps).

Step #0: Verify that input fails with the given pipeline and make note of the
error code.

Step #1: Split pipeline in two starting from front and move forward as long as
first pipeline exits normally and the second pipeline fails with the expected
error code. Move on to step #2 with the IR from the split point and the
pipeline from the second invocation.

Step #2: Remove passes from end of the pipeline as long as the pipeline fails
with the expected error code.

Step #3: Make several sweeps over the remaining pipeline trying to remove one
pass at a time. Repeat sweeps until unable to remove any more passes.

Usage example:
./utils/reduce_pipeline.py --opt-binary=./build-all-Debug/bin/opt --input=input.ll --output=output.ll --passes=PIPELINE [EXTRA-OPT-ARGS ...]

Differential Revision: https://reviews.llvm.org/D110908
The file was addedllvm/utils/reduce_pipeline_test/test.py
The file was addedllvm/utils/pipeline.py
The file was addedllvm/utils/reduce_pipeline.py
The file was addedllvm/utils/reduce_pipeline_test/fake_opt.py