[all-commits] [llvm/llvm-project] 2d1dd6: [LLVM][CodingStandard] More guidance for constants...
Alexis Engelke via All-commits
all-commits at lists.llvm.org
Thu Jul 2 04:54:35 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 2d1dd6c182cd1355e08319f256c81c9414334a0a
https://github.com/llvm/llvm-project/commit/2d1dd6c182cd1355e08319f256c81c9414334a0a
Author: Alexis Engelke <engelke at in.tum.de>
Date: 2026-07-02 (Thu, 02 Jul 2026)
Changed paths:
M llvm/docs/CodingStandards.md
Log Message:
-----------
[LLVM][CodingStandard] More guidance for constants (#206972)
LLVM's startup overhead is dominated by page faults caused by global
constructors (most notably cl::opt, but also some other globals (likely
inadvertantly)) and relocations. Therefore:
- Be more explicit about inadvertant global constructors and recommend
using constexpr to initialize constant global variables.
- Discourage the addition of globals that cause relocations.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list