aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
diff options
context:
space:
mode:
authorAdrian Prantl <aprantl@apple.com>2018-02-06 22:17:45 +0000
committerAdrian Prantl <aprantl@apple.com>2018-02-06 22:17:45 +0000
commitc929f7ad423e9566dc9a06815d0f3f7f3d809db8 (patch)
tree705d15b04e8d0bf202bc035d8c981fa4eb0d6e56 /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
parent0ccef9ee1693f774a9dc23a10e0d3d7bf8b9bfbf (diff)
downloadllvm-c929f7ad423e9566dc9a06815d0f3f7f3d809db8.zip
llvm-c929f7ad423e9566dc9a06815d0f3f7f3d809db8.tar.gz
llvm-c929f7ad423e9566dc9a06815d0f3f7f3d809db8.tar.bz2
Fix a crash when emitting DIEs for variable-length arrays
VLAs may refer to a previous DIE to express the DW_AT_count of their type. Clang generates an artificial "vla_expr" variable for this. If this DIE hasn't been created yet LLVM asserts. This patch fixes this by sorting the local variables so that dependencies come before they are needed. It also replaces the linear scan in DWARFFile with a std::map, which can be faster. Differential Revision: https://reviews.llvm.org/D42940 llvm-svn: 324412
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitcodeWriter.cpp')
0 files changed, 0 insertions, 0 deletions