SuccessChanges

Summary

  1. [gcov] Silence warning: comparison of integers of different signs (details)
  2. [benchmark] Silence 'suggest override' and 'missing override' warnings (details)
  3. LLVM Detailed IR tests for introduction of flag -fsanitize-address-detect-stack-use-after-return-mode. (details)
  4. [sanitizer] Let glibc aarch64 use O(1) GetTls (details)
  5. [OpaquePtr] Create new bitcode encoding for atomicrmw (details)
  6. [LTT] Handle merged llvm.assume when dropping type tests (details)
  7. [lldb] Avoid format string in LLDB_SCOPED_TIMER (details)
  8. Revert "[lldb] Avoid format string in LLDB_SCOPED_TIMER" (details)
Commit dd2be15ff91a9a93387afbe0789f4de3376c0c0f by alexandre.ganea
[gcov] Silence warning: comparison of integers of different signs

When building with Clang 11 on Windows, silence the following:

[432/5643] Building C object projects\compiler-rt\lib\profile\CMakeFiles\clang_rt.profile-x86_64.dir\GCDAProfiling.c.obj
F:\aganea\llvm-project\compiler-rt\lib\profile\GCDAProfiling.c(464,13): warning: comparison of integers of different signs: 'uint32_t' (aka 'unsigned int') and 'int' [-Wsign-compare]
    if (val != (gcov_version >= 90 ? GCOV_TAG_OBJECT_SUMMARY
        ~~~ ^   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
The file was modifiedcompiler-rt/lib/profile/GCDAProfiling.c
Commit 20c9a44ac0164a657329020c0b3deabab3625688 by alexandre.ganea
[benchmark] Silence 'suggest override' and 'missing override' warnings

When building with Clang 11 on Windows, silence the following:

F:\aganea\llvm-project\llvm\utils\benchmark\include\benchmark/benchmark.h(955,8): warning: 'Run' overrides a member function but is not marked 'override' [-Wsuggest-override]
  void Run(State& st);
       ^
F:\aganea\llvm-project\llvm\utils\benchmark\include\benchmark/benchmark.h(895,16): note: overridden virtual function is here
  virtual void Run(State& state) = 0;
               ^
1 warning generated.
The file was modifiedllvm/utils/benchmark/include/benchmark/benchmark.h
Commit 52ac1147713db35f6ff644fc8a40f08944ce3292 by kda
LLVM Detailed IR tests for introduction of flag -fsanitize-address-detect-stack-use-after-return-mode.

Rework all tests that interact with use after return to correctly handle the case where the mode has been explicitly set to Never or Always.

for issue: https://github.com/google/sanitizers/issues/1394

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D102462
The file was modifiedllvm/test/Instrumentation/AddressSanitizer/fake-stack.ll
The file was modifiedllvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
The file was modifiedllvm/test/Instrumentation/AddressSanitizer/stack-poisoning.ll
The file was modifiedllvm/test/Instrumentation/AddressSanitizer/lifetime-uar-uas.ll
The file was modifiedllvm/test/Instrumentation/AddressSanitizer/localescape.ll
The file was modifiedllvm/include/llvm/Transforms/Instrumentation/AddressSanitizerOptions.h
The file was modifiedllvm/test/Instrumentation/AddressSanitizer/stack_dynamic_alloca.ll
Commit e67259531d7385fece6873b1da57e7cf84f110b3 by i
[sanitizer] Let glibc aarch64 use O(1) GetTls

The generic approach can still be used by musl and FreeBSD. Note: on glibc
2.31, TLS_PRE_TCB_SIZE is 0x700, larger than ThreadDescriptorSize() by 16, but
this is benign: as long as the range includes pthread::{specific_1stblock,specific}
pthread_setspecific will not cause false positives.

Note: the state before afec953857ffd682cb4119e7950f3593efbaaa81 underestimated
the TLS size a lot (nearly ThreadDescriptorSize() = 1776).
That may explain why afec953857ffd682cb4119e7950f3593efbaaa81 actually made some
tests pass.
The file was modifiedcompiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp
Commit ad90a6be219a547873beb80f977e45e23e9247ac by aeubanks
[OpaquePtr] Create new bitcode encoding for atomicrmw

Since the opaque pointer type won't contain the pointee type, we need to
separately encode the value type for an atomicrmw.

Emit this new code for atomicrmw.

Handle this new code and the old one in the bitcode reader.

Reviewed By: dblaikie

Differential Revision: https://reviews.llvm.org/D103123
The file was modifiedllvm/lib/Bitcode/Writer/BitcodeWriter.cpp
The file was modifiedllvm/lib/Bitcode/Reader/BitcodeReader.cpp
The file was addedllvm/test/Bitcode/atomicrmw-upgrade.ll
The file was addedllvm/test/Bitcode/atomicrmw-upgrade.ll.bc
The file was modifiedllvm/include/llvm/Bitcode/LLVMBitCodes.h
Commit d35fe04fa35a080cb024ecb56db67dc822c70740 by tejohnson
[LTT] Handle merged llvm.assume when dropping type tests

When the lower type test pass is invoked a second time with
DropTypeTests set to true, it expects that all remaining type tests feed
assume instructions, which are removed along with the type tests.

In some cases the llvm.assume might have been merged with another one,
i.e. from a builtin_assume instruction, in which case the type test
would actually feed a phi that in turn feeds the merged assume
instruction. In this case we can simply replace that operand of the phi
with "true" before removing the type test.

Differential Revision: https://reviews.llvm.org/D103073
The file was addedllvm/test/Transforms/LowerTypeTests/drop_type_test_phi.ll
The file was modifiedllvm/lib/Transforms/IPO/LowerTypeTests.cpp
Commit bbcb3433d4e8f5fa385b14e74d4314bd5409022d by Jonas Devlieghere
[lldb] Avoid format string in LLDB_SCOPED_TIMER

Pass LLVM_PRETTY_FUNCTION directly for the no-argument macro.
The file was modifiedlldb/include/lldb/Utility/Timer.h
Commit 564eb20e0deecd173a7b990dcfd0e57fb045c522 by Jonas Devlieghere
Revert "[lldb] Avoid format string in LLDB_SCOPED_TIMER"

Right after pushing, I remembered that this was added to silence a GCC
warning (https://reviews.llvm.org/D99120). This reverts my patch and
adds a comment.
The file was modifiedlldb/include/lldb/Utility/Timer.h