bevyengine / bevyengine/bevy

Asset server file watcher is causing stuttering on OSX

Open
#8,177 0 comments 0 reactions 0 assignees View on GitHub
A-Assets C-Bug C-Performance
Dominant language
Rust
Stars
48.2k
Forks
4.8k
Avg merge
3d 16h
Merged PRs (30d)
171

Description

## 0.10.0

## \[Optional\] Relevant system information

```
2023-03-23T04:43:00.988197Z INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 13.0.1 ", kernel: "22.1.0", cpu: "Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz", core_count: "8", memory: "64.0 GiB" }
```

## What you did

After upgrading to 0.10 my app started getting slower and slower with every frame while CPU utilization wasn't changing almost at all. None of the cores were fully utilized either. Here is the perf profile suggesting that asset loader might be the bottleneck (updating/freeing function went from few ms to a hundred of ms after first minute).

Screenshot_2023-03-22_at_6 35 15_PM

Screenshot_2023-03-22_at_6 22 17_PM

Flame graph:
Screenshot 2023-03-22 at 11 39 48 PM

Flame graph after turning of file watcher:
Screenshot 2023-03-22 at 11 52 21 PM

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the reported macOS 13 performance degradation with the asset server file watcher enabled, then compare profiling results with the watcher disabled as described in the issue. Done means the progressive frame stuttering and asset-loader overhead no longer occur while the file watcher remains enabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
performance, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.