aboutsummaryrefslogtreecommitdiff
path: root/backend/lib/CodeGen/MIRParser/MIRParser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'backend/lib/CodeGen/MIRParser/MIRParser.cpp')
-rw-r--r--backend/lib/CodeGen/MIRParser/MIRParser.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/backend/lib/CodeGen/MIRParser/MIRParser.cpp b/backend/lib/CodeGen/MIRParser/MIRParser.cpp
index 3b89491..c7e92a0 100644
--- a/backend/lib/CodeGen/MIRParser/MIRParser.cpp
+++ b/backend/lib/CodeGen/MIRParser/MIRParser.cpp
@@ -290,6 +290,12 @@ bool MIRDocumentParser::parseFunction(const yaml::Node &Root, MIRDocument &Docum
return IRFunction->block(BlockName) != nullptr;
};
}
+ if (Document.EmbeddedIR) {
+ const EmbeddedIRReferenceIndex *Embedded = &*Document.EmbeddedIR;
+ Context.GlobalValuePropertiesForName = [Embedded](std::string_view GlobalName) {
+ return Embedded->globalObjectProperties(GlobalName).value_or(GlobalValueProperties{});
+ };
+ }
std::vector<PendingJumpTable> PendingJumpTables;
if (parseFunctionScalars(Root, Function, DocumentInfo) ||