[PATCH] D33513: [ThinLTO] Fix ThinLTO crash while destroying context

Charles Saternos via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 25 10:35:47 PDT 2017


ncharlie added a comment.

In https://reviews.llvm.org/D33513#763708, @davide wrote:

> Thanks for your first contribution, great GSoC start!


Thanks! This was a good chance to look closely at the code to start learning how it works.

> One note: this manifests with ThinLTO, but it might be a more generic metadata issue. Are you able to reproduce without ThinLTO  (and maybe with a single file?)

The bug only happens when lazy loading Metadata. Lazy loading occurs when module level metadata is being imported by ThinLTO (see https://reviews.llvm.org/diffusion/L/browse/llvm/trunk/lib/Bitcode/Reader/MetadataLoader.cpp;303885$781). I believe this is the only path that leads to lazy loading, so I don't think it can happen elsewhere.


Repository:
  rL LLVM

https://reviews.llvm.org/D33513





More information about the llvm-commits mailing list