diff options
author | 2024-01-23 16:38:06 -0800 | |
---|---|---|
committer | 2024-02-07 15:51:40 -0800 | |
commit | d38feb0d4aef1bc3c407900be77a887882765f85 (patch) | |
tree | 41221e07b58aec814e3b1bffe4120a986a1210b6 /rust/afdo.go | |
parent | 15fa8145609d358e27f4bcfefffb64eb33c06f00 (diff) |
Convert AFDO mutators to TransitionMutator
Convert afdoDepsMutator and afdoMutator to a TransitionMutator as a
step towards variants-on-demand.
This relands Ib05845455ccf43a07b3915a0d7b0a95896062f13 with a fix
to maintain the current behavior of not using AFDO variants for
dependencies of the linker static binary.
Bug: 319288033
Bug: 324141705
Test: afdo_test.go
Change-Id: I76e30021173fc5b7e9e1fa826039776eb3dc7b6e
Diffstat (limited to 'rust/afdo.go')
-rw-r--r-- | rust/afdo.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rust/afdo.go b/rust/afdo.go index 323ee36a5..6116c5e21 100644 --- a/rust/afdo.go +++ b/rust/afdo.go @@ -44,14 +44,14 @@ func (afdo *afdo) addDep(ctx BaseModuleContext, actx android.BottomUpMutatorCont if err != nil { ctx.ModuleErrorf("%s", err.Error()) } - if fdoProfileName != nil { + if fdoProfileName != "" { actx.AddFarVariationDependencies( []blueprint.Variation{ {Mutator: "arch", Variation: actx.Target().ArchVariation()}, {Mutator: "os", Variation: "android"}, }, cc.FdoProfileTag, - []string{*fdoProfileName}..., + []string{fdoProfileName}..., ) } } |