Open
Description
We can find the reproducer at: https://discourse.llvm.org/t/modules-increased-build-times/68755/7
For short:
// test.cppm
module;
#include <iostream>
export module test;
import vulkan; // Vulcan is constructed big module.
will take 3~4s to generate the PCM.
And
module;
#include <iostream>
export module test.without.import;
will take about 0.5s to complete only.
Note that:
#include <iostream>
import vulkan;
will take 0.5s to complete too.
Currently I located in ASTWriter::WriteDecl
. But I am not sure if this can be fixed simply.