Skip to content

Comments

Optimize core/input/input.h header #includeing#115360

Merged
Repiteo merged 1 commit intogodotengine:masterfrom
Nintorch:optimize-input-header-includes
Jan 28, 2026
Merged

Optimize core/input/input.h header #includeing#115360
Repiteo merged 1 commit intogodotengine:masterfrom
Nintorch:optimize-input-header-includes

Conversation

@Nintorch
Copy link
Contributor

@Nintorch Nintorch commented Jan 25, 2026

This PR optimizes #includeing of input.h header.
Each time I modify this header to improve an input feature I have to wait around 50 minutes (!) for the Windows editor to recompile, it's frustrating. 😅
That's why I decided to make this PR, so I (and other people that modify this file) won't have to wait too long.
I use GitHub CI to compile the engine (I think I don't have enough RAM to compile the engine on my laptop), and I think I can check the compilation times before and after this change.
I will compare between 2 CI runs, one of them was when I decided to rename the methods in my joypad motion sensors pr (sensors -> motion, so for example, has_joy_sensors() -> has_joy_motion()) and the other one is a test change just to test the compilation times after this PR.

Here are the results image

So now the engine recompiles roughly 3-5 times faster when you edit core/input/input.h! (Unless I'm misunderstanding something)

@Nintorch Nintorch requested review from a team as code owners January 25, 2026 13:12
@Nintorch Nintorch requested review from a team January 25, 2026 13:12
@Nintorch Nintorch requested review from a team as code owners January 25, 2026 13:12
@Ivorforce Ivorforce added this to the 4.x milestone Jan 25, 2026
@Repiteo Repiteo removed request for a team January 25, 2026 19:55
@Repiteo Repiteo removed request for a team January 25, 2026 19:55
@Ivorforce Ivorforce requested a review from a team January 25, 2026 22:26
Copy link
Contributor

@Repiteo Repiteo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh wow, shifting around enum scope alone making this much of an impact is impressive!

@Repiteo Repiteo removed the request for review from a team January 25, 2026 22:32
@Repiteo Repiteo modified the milestones: 4.x, 4.7 Jan 25, 2026
@Nintorch Nintorch force-pushed the optimize-input-header-includes branch 3 times, most recently from b31be62 to 4e79d48 Compare January 26, 2026 11:30
@Nintorch Nintorch force-pushed the optimize-input-header-includes branch from 4e79d48 to 5ed6dad Compare January 26, 2026 11:58
@Ivorforce
Copy link
Member

This needs a rebase.

@Nintorch Nintorch force-pushed the optimize-input-header-includes branch from 5ed6dad to 0bd4944 Compare January 28, 2026 09:19
@Nintorch
Copy link
Contributor Author

Done!

@Nintorch Nintorch force-pushed the optimize-input-header-includes branch from 0bd4944 to eb01951 Compare January 28, 2026 09:21
@Repiteo Repiteo merged commit 0b60e18 into godotengine:master Jan 28, 2026
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Jan 28, 2026

Thanks!

@Nintorch Nintorch deleted the optimize-input-header-includes branch January 28, 2026 19:05
Rubonnek added a commit to Rubonnek/limboai that referenced this pull request Jan 29, 2026
Rubonnek added a commit to Rubonnek/limboai that referenced this pull request Feb 5, 2026
rivie13 pushed a commit to rivie13/Phoenix-Agentic-Engine that referenced this pull request Feb 16, 2026
…ader-includes

Optimize `core/input/input.h` header `#include`ing
Rubonnek added a commit to Rubonnek/limboai that referenced this pull request Feb 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants