Building gdextensions with lto=full warns about serial compilaton
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 82/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- cpp
- Domain
- build-system, performance
Research direction
Start in common_compiler_flags.py and locate the instances of '-flto'. Reproduce the warning with scons lto=full on a GD extension, then verify that the compiler uses parallel LTO without the serial-compilation warning. Confirm the relevant build checks or extension compilation still pass.
Written by the indexing model from the issue text.
Description
Godot version
4.6
godot-cpp version
3a7edf0
System information
Arch Linux
Issue description
Building GD extensions with the 'lto=full' flag produces the following warning
warning: using serial compilation of 10 LTRANS jobs
lto-wrapper: note: see the '-flto' option documentation for more information
Which slows down compilation times.
After some research the warning appears due to a change in the -flto option introduced in GCC 11.4. The -flto option only uses parallel compilation if explicitly instructed to do so. By default, it uses slow serial compilation. updating "common_compiler_flags.py" to change instances of '-flto' to '-flto=auto' will re-enable parallelization.
Steps to reproduce
Compile any GD Extension with scons lto=full
Minimal reproduction project
N/A
- Dominant language
- C++
- Stars
- 2.7k
- Forks
- 810
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 8
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from godotengine/godot-cpp
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
godotengine/godot-cpp#1969 · 4 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
godotengine/godot-cpp#1967 ·
-
bug
Difficulty 3/5 1-2 days Newbie friendliness 50/100
godotengine/godot-cpp#2042 ·
-
bug crash
Difficulty 4/5 3-5 days Newbie friendliness 35/100
godotengine/godot-cpp#2024 · 5 comments ·
-
bug
Difficulty 4/5 3-5 days Newbie friendliness 35/100
godotengine/godot-cpp#2004 · 3 comments ·
All issues in godotengine/godot-cpp
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
AXERA-TECH/ax-llm#77 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
bug-unconfirmed
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
NVIDIA/cuda-samples#453 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
infiniflow/infinity#3502 ·