[PATCH] D51651: [ThinLTO] Fix memory corruption in ThinLTOCodeGenerator when CodeGenOnly was specified

Alex Borcan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 4 13:15:36 PDT 2018


alexbdv added a comment.

Indeed it can, that is another fix. I was just doing the "obvious" fix since I assume there is a reason why the ::codegen(Module &TheModule) function exists. 
Should we just remove the function altogether ? As-is it is not thread-safe = results in crashes.
Also, a clone of TMBuilder is not expensive considering the context.


Repository:
  rL LLVM

https://reviews.llvm.org/D51651





More information about the llvm-commits mailing list