Add a new option compilerFilter to bootImageConfig.

After this change, the compiler filter can be specified by the option,
and profiles will not be used if the compiler filter is not
a profile-guided one.

This change also allows preloadedClassesFile to be empty.

Bug: 269230245
Test: m
Change-Id: I65e6b7209d2f0510bcc784a62623ab402b7f96bb
This commit is contained in:
Jiakai Zhang
2023-02-23 17:50:46 +00:00
parent af8b950357
commit 8e9ea8bb83
3 changed files with 23 additions and 7 deletions

View File

@@ -1291,7 +1291,7 @@ func (module *PrebuiltBootclasspathFragmentModule) produceBootImageFiles(ctx and
}
return bootImageFiles
} else {
if profile == nil {
if profile == nil && imageConfig.isProfileGuided() {
ctx.ModuleErrorf("Unable to produce boot image files: neither boot image files nor profiles exists in the prebuilt apex")
return bootImageOutputs{}
}