SuccessChanges

Summary

  1. [WebAssembly] Restore defaults for stores per memop Summary: Large slowdowns were observed in Rust due to many small, constant sized copies in conjunction with poorly-optimized memory.copy implementations. Since memory.copy cannot be expected to be inlined efficiently by engines at this time, stop using it for the smallest copies. We continue to lower all memcpy intrinsics to memory.copy, though. Reviewers: aheejin, alexcrichton Subscribers: dschuff, sbc100, jgravelle-google, hiraditya, JDevlieghere, sunfish, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D67639
  2. [Docs] Moves topics to new categories This commit moves several topics to new categories. It also removes a few duplicate links in Subsystem Documentation.
  3. [AArch64][GlobalISel] Support lowering musttail calls Since we now lower most tail calls, it makes sense to support musttail. Instead of always falling back to SelectionDAG, only fall back when a musttail call was not able to be emitted as a tail call. Once we can handle most incoming and outgoing arguments, we can change this to a `report_fatal_error` like in ISelLowering. Remove the assert that we don't have varargs and a musttail, and replace it with a return false. Implementing this requires that we implement `saveVarArgRegisters` from AArch64ISelLowering, which is an entirely different patch. Add GlobalISel lines to vararg-tallcall.ll to make sure that we produce correct code. Right now we only fall back, but eventually this will be relevant. Differential Revision: https://reviews.llvm.org/D67681
  4. Remove the obsolete BlockByRefStruct flag from LLVM IR DIFlagBlockByRefStruct is an unused DIFlag that originally was used by clang to express (Objective-)C block captures in debug info. For the last year Clang has been emitting complex DIExpressions to describe block captures instead, which makes all the code supporting this flag redundant. This patch removes the flag and all supporting "dead" code, so we can reuse the bit for something else in the future. Since this only affects debug info generated by Clang with the block extension this mostly affects Apple platforms and I don't have any bitcode compatibility concerns for removing this. The Verifier will reject debug info that uses the bit and thus degrade gracefully when LTO'ing older bitcode with a newer compiler. rdar://problem/44304813 Differential Revision: https://reviews.llvm.org/D67453
  5. llvm-reduce: Remove inaccurate doxy comment about a return that isn't returned Addressing post-commit code review feedback from Dávid Bolvanský - thanks!
  6. llvm-reduce: Fix inconsistencies between int/unsigned usage (standardize on int)
  7. [analyzer] PR43102: Fix an assertion and an out-of-bounds error for diagnostic location construction Summary: https://bugs.llvm.org/show_bug.cgi?id=43102 In today's edition of "Is this any better now that it isn't crashing?", I'd like to show you a very interesting test case with loop widening. Looking at the included test case, it's immediately obvious that this is not only a false positive, but also a very bad bug report in general. We can see how the analyzer mistakenly invalidated `b`, instead of its pointee, resulting in it reporting a null pointer dereference error. Not only that, the point at which this change of value is noted at is at the loop, rather then at the method call. It turns out that `FindLastStoreVisitor` works correctly, rather the supplied explodedgraph is faulty, because `BlockEdge` really is the `ProgramPoint` where this happens. {F9855739} So it's fair to say that this needs improving on multiple fronts. In any case, at least the crash is gone. Full ExplodedGraph: {F9855743} Reviewers: NoQ, xazax.hun, baloghadamsoftware, Charusso, dcoughlin, rnkovacs, TWeaver Subscribers: JesperAntonsson, uabelho, Ka-Ka, bjope, whisperity, szepet, a.sidorin, mikhail.ramalho, donat.nagy, dkrupp, gamesh411, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D66716
  8. gn build: Merge r372267
Revision 372275 by tlively:
[WebAssembly] Restore defaults for stores per memop

Summary:
Large slowdowns were observed in Rust due to many small, constant
sized copies in conjunction with poorly-optimized memory.copy
implementations. Since memory.copy cannot be expected to be inlined
efficiently by engines at this time, stop using it for the smallest
copies. We continue to lower all memcpy intrinsics to memory.copy,
though.

Reviewers: aheejin, alexcrichton

Subscribers: dschuff, sbc100, jgravelle-google, hiraditya, JDevlieghere, sunfish, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D67639
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp (diff)llvm.src/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
The file was modified/llvm/trunk/test/CodeGen/WebAssembly/bulk-memory.ll (diff)llvm.src/test/CodeGen/WebAssembly/bulk-memory.ll
Revision 372274 by dr87:
[Docs] Moves topics to new categories

This commit moves several topics to new categories. It also removes a few duplicate links in Subsystem Documentation.
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/docs/ProgrammingDocumentation.rst (diff)llvm.src/docs/ProgrammingDocumentation.rst
The file was modified/llvm/trunk/docs/SubsystemDocumentation.rst (diff)llvm.src/docs/SubsystemDocumentation.rst
The file was modified/llvm/trunk/docs/UserGuides.rst (diff)llvm.src/docs/UserGuides.rst
The file was modified/llvm/trunk/docs/index.rst (diff)llvm.src/docs/index.rst
Revision 372273 by paquette:
[AArch64][GlobalISel] Support lowering musttail calls

Since we now lower most tail calls, it makes sense to support musttail.

Instead of always falling back to SelectionDAG, only fall back when a musttail
call was not able to be emitted as a tail call. Once we can handle most
incoming and outgoing arguments, we can change this to a `report_fatal_error`
like in ISelLowering.

Remove the assert that we don't have varargs and a musttail, and replace it
with a return false. Implementing this requires that we implement
`saveVarArgRegisters` from AArch64ISelLowering, which is an entirely different
patch.

Add GlobalISel lines to vararg-tallcall.ll to make sure that we produce correct
code. Right now we only fall back, but eventually this will be relevant.

Differential Revision: https://reviews.llvm.org/D67681
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/lib/Target/AArch64/AArch64CallLowering.cpp (diff)llvm.src/lib/Target/AArch64/AArch64CallLowering.cpp
The file was modified/llvm/trunk/test/CodeGen/AArch64/GlobalISel/call-translator-musttail.ll (diff)llvm.src/test/CodeGen/AArch64/GlobalISel/call-translator-musttail.ll
The file was modified/llvm/trunk/test/CodeGen/AArch64/GlobalISel/call-translator-tail-call.ll (diff)llvm.src/test/CodeGen/AArch64/GlobalISel/call-translator-tail-call.ll
The file was modified/llvm/trunk/test/CodeGen/AArch64/vararg-tallcall.ll (diff)llvm.src/test/CodeGen/AArch64/vararg-tallcall.ll
Revision 372272 by Adrian Prantl:
Remove the obsolete BlockByRefStruct flag from LLVM IR

DIFlagBlockByRefStruct is an unused DIFlag that originally was used by
clang to express (Objective-)C block captures in debug info. For the
last year Clang has been emitting complex DIExpressions to describe
block captures instead, which makes all the code supporting this flag
redundant.

This patch removes the flag and all supporting "dead" code, so we can
reuse the bit for something else in the future.

Since this only affects debug info generated by Clang with the block
extension this mostly affects Apple platforms and I don't have any
bitcode compatibility concerns for removing this. The Verifier will
reject debug info that uses the bit and thus degrade gracefully when
LTO'ing older bitcode with a newer compiler.

rdar://problem/44304813

Differential Revision: https://reviews.llvm.org/D67453
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/bindings/go/llvm/dibuilder.go (diff)llvm.src/bindings/go/llvm/dibuilder.go
The file was modified/llvm/trunk/include/llvm-c/DebugInfo.h (diff)llvm.src/include/llvm-c/DebugInfo.h
The file was modified/llvm/trunk/include/llvm/IR/DebugInfoFlags.def (diff)llvm.src/include/llvm/IR/DebugInfoFlags.def
The file was modified/llvm/trunk/include/llvm/IR/DebugInfoMetadata.h (diff)llvm.src/include/llvm/IR/DebugInfoMetadata.h
The file was modified/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp (diff)llvm.src/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
The file was modified/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (diff)llvm.src/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
The file was modified/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h (diff)llvm.src/lib/CodeGen/AsmPrinter/DwarfDebug.h
The file was modified/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfUnit.h (diff)llvm.src/lib/CodeGen/AsmPrinter/DwarfUnit.h
The file was modified/llvm/trunk/lib/IR/Verifier.cpp (diff)llvm.src/lib/IR/Verifier.cpp
The file was modified/llvm/trunk/test/CodeGen/ARM/debug-info-blocks.ll (diff)llvm.src/test/CodeGen/ARM/debug-info-blocks.ll
The file was modified/llvm/trunk/test/DebugInfo/Generic/block-asan.ll (diff)llvm.src/test/DebugInfo/Generic/block-asan.ll
The file was modified/llvm/trunk/test/Verifier/blockbyref.ll (diff)llvm.src/test/Verifier/blockbyref.ll
Revision 372271 by dblaikie:
llvm-reduce: Remove inaccurate doxy comment about a return that isn't returned

Addressing post-commit code review feedback from Dávid Bolvanský -
thanks!
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceBasicBlocks.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceBasicBlocks.cpp
Revision 372270 by dblaikie:
llvm-reduce: Fix inconsistencies between int/unsigned usage (standardize on int)
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/Delta.cpp (diff)llvm.src/tools/llvm-reduce/deltas/Delta.cpp
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/Delta.h (diff)llvm.src/tools/llvm-reduce/deltas/Delta.h
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceArguments.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceArguments.cpp
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceBasicBlocks.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceBasicBlocks.cpp
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceFunctions.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceFunctions.cpp
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceGlobalVars.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceGlobalVars.cpp
The file was modified/llvm/trunk/tools/llvm-reduce/deltas/ReduceMetadata.cpp (diff)llvm.src/tools/llvm-reduce/deltas/ReduceMetadata.cpp
Revision 372269 by szelethus:
[analyzer] PR43102: Fix an assertion and an out-of-bounds error for diagnostic location construction

Summary:
https://bugs.llvm.org/show_bug.cgi?id=43102

In today's edition of "Is this any better now that it isn't crashing?", I'd like to show you a very interesting test case with loop widening.

Looking at the included test case, it's immediately obvious that this is not only a false positive, but also a very bad bug report in general. We can see how the analyzer mistakenly invalidated `b`, instead of its pointee, resulting in it reporting a null pointer dereference error. Not only that, the point at which this change of value is noted at is at the loop, rather then at the method call.

It turns out that `FindLastStoreVisitor` works correctly, rather the supplied explodedgraph is faulty, because `BlockEdge` really is the `ProgramPoint` where this happens.
{F9855739}
So it's fair to say that this needs improving on multiple fronts. In any case, at least the crash is gone.

Full ExplodedGraph: {F9855743}

Reviewers: NoQ, xazax.hun, baloghadamsoftware, Charusso, dcoughlin, rnkovacs, TWeaver

Subscribers: JesperAntonsson, uabelho, Ka-Ka, bjope, whisperity, szepet, a.sidorin, mikhail.ramalho, donat.nagy, dkrupp, gamesh411, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D66716
Change TypePath in RepositoryPath in Workspace
The file was modified/cfe/trunk/lib/Analysis/PathDiagnostic.cpp (diff)clang.src/lib/Analysis/PathDiagnostic.cpp
The file was modified/cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp (diff)clang.src/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp
The file was added/cfe/trunk/test/Analysis/loop-widening.cppclang.src/test/Analysis/loop-widening.cpp
Revision 372268 by gnsyncbot:
gn build: Merge r372267
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/utils/gn/secondary/llvm/unittests/Bitcode/BUILD.gn (diff)llvm.src/utils/gn/secondary/llvm/unittests/Bitcode/BUILD.gn