Frontend: teach -compile-module-from-interface action to emit ABI descriptor as byproduct

We have implemented a libSwiftDriver-based tool to generate prebuilt module cache for
entire SDKs. Anchored on the same infrastructure, we could also generate ABI baselines
for entire SDKs.
This commit is contained in:
Xi Ge
2021-08-20 13:41:33 -07:00
parent f737043607
commit 1a660c08ca
15 changed files with 103 additions and 10 deletions

View File

@@ -284,6 +284,9 @@ bool ModuleInterfaceBuilder::buildSwiftModuleInternal(
if (SubInstance.getDiags().hadAnyError()) {
return std::make_error_code(std::errc::not_supported);
}
if (!ABIDescriptorPath.empty()) {
swift::ide::api::dumpModuleContent(Mod, ABIDescriptorPath, true);
}
return std::error_code();
});
}, ThreadStackSize);