Conversation
The passed in (or default) flag value was assigned instead of the calculated one. This vector of values was only used for `CheckSnapshotCompatibility`. Bug: 481846356
The goal is to separate the `GpuMode` calculating logic from the `CuttlefishConfig::MutableInstanceSpecific` mutation/setting logic. We need to be able to re-use the calculation logic for metrics without making any modifications. The plan is to pick apart the mixed logic to separate everything, then put all of the determination logic back together. Bug: 481846356
Piecemeal stripping out logic from the monolithic function with mutation. Bug: 481846356
Bug: 481846356
Bug: 481846356
Bug: 481846356
Bug: 481846356
Bug: 481846356
So both `#ifdef __APPLE__` and `#ifndef` have the same interface. This will make it easier to use for metrics. Bug: 481846356
To avoid the extra calls and conditionals in the logic for setting config values. Bug: 481846356
Bug: 481846356
The entire anonymous namespace belonged in the same block. The [[maybe_unused]] notation is not necessary with this condensing. The only remaining `#ifdef __APPLE__` code should be the alternative versions of `GetGraphicsAvailability` and `SelectGpuMode`. Bug: 481846356
The calculated, used GPU mode will be added next. Bug: 481846356
Bug: 481846356
cjreynol
commented
Oct 2, 2026
| CF_EXPECT(GpuModeFlag::FromGlobalGflags()); | ||
| std::vector<GpuMode> gpu_mode_used; | ||
| gpu_mode_used.reserve(gpu_mode_requested.Size()); | ||
| // TODO CJR: finish after rebasing with GuestConfigs and VmManagerFlag |
| const std::string& guest_renderer_preload_arg, VmmMode vmm, | ||
| const GuestConfig& guest_config, | ||
| CuttlefishConfig::MutableInstanceSpecific& instance); | ||
| Result<GpuMode> SelectGpuMode( |
Collaborator
Author
There was a problem hiding this comment.
Waiting on #3264 for this function to become available
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug: 481846356