only log once GPU preprocessing support#23556
Merged
alice-i-cecile merged 1 commit intobevyengine:mainfrom Mar 29, 2026
Merged
Conversation
JMS55
approved these changes
Mar 28, 2026
atlv24
approved these changes
Mar 29, 2026
Contributor
atlv24
left a comment
There was a problem hiding this comment.
yeah, for reference the reason its added twice is because of this line in bevy_pbr mesh
bevy/crates/bevy_pbr/src/render/mesh.rs
Line 234 in 2589ed2
and the reason that's needed is that we conditionally init_gpu_resource some things depending on the value of GpuPreprocessingSupport, which itself is added by init_gpu_resource. init_gpu_resource cannot run without SubApp access, so must be called in plugin code. The proper fix here would be to re-initialize gpu limit detection in the same place the render device is inserted as a resource, so everything downstream can read it fine. bevy_limits will probably fix this issue, i'll make note to remove the info_once calls here once that's in
splo
pushed a commit
to splo/bevy
that referenced
this pull request
Mar 31, 2026
# Objective - Bevy logs twice if GPU preprocessing is enabled ## Solution - Only log it once The resource `GpuPreprocessingSupport` is added twice, I don't know if it can be done only once. @atlv24 I think you were the last to touch around both place it's added, is there a reason to do it twice? You modified only one of them for renderer recovery, is there a need to keep both that way for now?
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.
Objective
Solution
The resource
GpuPreprocessingSupportis added twice, I don't know if it can be done only once.@atlv24 I think you were the last to touch around both place it's added, is there a reason to do it twice? You modified only one of them for renderer recovery, is there a need to keep both that way for now?