Skip to content

(C++ modules) two phase compilation doesn't generate reduced bmi mismatching behavior described by the documentation #159780

@Arthapz

Description

@Arthapz

Hello, the documentation say that -fexperimental-modules-reduced-bmi can be used with --precompile and generate reduced bmi where -fmodule-ouput= is set

It is also possible to produce a Reduced BMI with the two-phase compilation model. When -fexperimental-modules-reduced-bmi, --precompile, and -fmodule-output= are specified, the generated BMI specified by -o will be a full BMI and the BMI specified by -fmodule-output= will be a Reduced BMI.

but when i try it, only the full BMI is generated

> clang -std=c++20 -x c++-module --precompile -fexperimental-modules-reduced-bmi -fmodule-output=reduced.hello.pcm -o hello.pcm src\hello.mpp
> ls
src/
hello.pcm
> clang -std=c++20 -x c++-module --precompile -fmodules-reduced-bmi -fmodule-output=reduced.hello.pcm -o hello.pcm src\hello.mpp
> ls
src/
hello.pcm
// hello.mpp
export module hello;
export int foo() { return 0; }

Metadata

Metadata

Assignees

Labels

clang:modulesC++20 modules and Clang Header Modules

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions