Remove the obsolete BlockByRefStruct flag from LLVM IR
authorAdrian Prantl <aprantl@apple.com>
Wed, 18 Sep 2019 22:38:56 +0000 (22:38 +0000)
committerAdrian Prantl <aprantl@apple.com>
Wed, 18 Sep 2019 22:38:56 +0000 (22:38 +0000)
commit0779dffbd4a927d7bf9523482481248c51796907
tree4f81626eff057e781360752c5a50bde2068a5b5c
parent69a92352022338417f27bfa45c0471beb6a92cc7
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

llvm-svn: 372272
12 files changed:
llvm/bindings/go/llvm/dibuilder.go
llvm/include/llvm-c/DebugInfo.h
llvm/include/llvm/IR/DebugInfoFlags.def
llvm/include/llvm/IR/DebugInfoMetadata.h
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
llvm/lib/CodeGen/AsmPrinter/DwarfUnit.h
llvm/lib/IR/Verifier.cpp
llvm/test/CodeGen/ARM/debug-info-blocks.ll
llvm/test/DebugInfo/Generic/block-asan.ll
llvm/test/Verifier/blockbyref.ll