Const initialize LOCK_LATCH thread local#155689
Const initialize LOCK_LATCH thread local#155689rust-bors[bot] merged 1 commit intorust-lang:mainfrom
LOCK_LATCH thread local#155689Conversation
|
rustbot has assigned @ShoyuVanilla. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
I'm not sure this would give us a perf gain, since it occurs on a cold path. @bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Const initialize `LOCK_LATCH` thread local
|
FWIW, I also did this in rayon: rayon-rs/rayon@85dfae1 |
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (2ca292b): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking means the PR may be perf-sensitive. It's automatically marked not fit for rolling up. Overriding is possible but disadvised: it risks changing compiler perf. @rustbot label: -S-waiting-on-perf -perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 2.7%, secondary 1.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary 5.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis perf run didn't have relevant results for this metric. Bootstrap: 490.734s -> 492.373s (0.33%) |
|
@bors r+ rollup |
Rollup of 7 pull requests Successful merges: - #155660 (c-variadic: fix for sparc64) - #153482 (tests/ui/macros: add annotations for reference rules) - #155075 (Add docs about SDKs and C compilation on armv7a-vex-v5) - #155685 (Fix `get_child_at_index` return type hints) - #155686 (Fix array template arg lookup behavior) - #155689 (Const initialize `LOCK_LATCH` thread local) - #155690 (Fix classify_union to return Union for regular unions)
Rollup merge of #155689 - zetanumbers:lock_latch_thread_local, r=ShoyuVanilla Const initialize `LOCK_LATCH` thread local A simple refactor to avoid runtime thread-local initialization.
Rollup of 7 pull requests Successful merges: - rust-lang/rust#155660 (c-variadic: fix for sparc64) - rust-lang/rust#153482 (tests/ui/macros: add annotations for reference rules) - rust-lang/rust#155075 (Add docs about SDKs and C compilation on armv7a-vex-v5) - rust-lang/rust#155685 (Fix `get_child_at_index` return type hints) - rust-lang/rust#155686 (Fix array template arg lookup behavior) - rust-lang/rust#155689 (Const initialize `LOCK_LATCH` thread local) - rust-lang/rust#155690 (Fix classify_union to return Union for regular unions)
A simple refactor to avoid runtime thread-local initialization.