[PATCH] D27668: Remove IsMetadataMaterialized from BitcodeReader (NFC)

Teresa Johnson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 12 10:48:35 PST 2016

tejohnson added a comment.

Not sure I understand the flow requiring this either. LGTM

Comment at: llvm/lib/Bitcode/Reader/BitcodeReader.cpp:3962
       case bitc::METADATA_BLOCK_ID:
-        if (ShouldLazyLoadMetadata && !IsMetadataMaterialized) {
           if (Error Err = rememberAndSkipMetadata())
The existing IsMetadataMaterialized flag would only ever make a difference here if we already materialized some functions (which materializes any already deferred metadata and sets IsMetadataMaterialized=true). It isn't clear to me when we would encounter a module-level metadata block after materializing a function. Even if we did, removing this flag just means deferring these newly encountered blocks, then we would materialize the newly deferred metadata block once we materialize the next GV anyway.


More information about the llvm-commits mailing list