PistonDevelopers / PistonDevelopers/piston

Noticable update event slow down, when laptop is disconnected from power

Open
#1,389 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

discussion
Dominant language
Rust
Stars
4.7k
Forks
235
Avg merge
1m
Merged PRs (30d)
4

Description

Hello,

I noticed today when I disconnected my development laptop from power, game updates in my, very simple, Tetris clone slow down noticeably.

To confirm the issue is not with my game code, I tested this on the piston getting started tutorial code and see the same slowdown occurs there. Attached a GIF of what I am seeing. You can clearly see the slowdown when the laptop is disconnected from power, and then speeds up when reconnected shortly after.

Update Slowdown

This seems like it shouldn't be normal behavior, right?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the slowdown with the Piston getting started tutorial, comparing behavior while the laptop is connected to power and on battery. Trace the update loop and timing behavior involved; done means the tutorial and similar games no longer visibly slow down when disconnected from power.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.