- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Open
Labels
compiler:optimizerOptimization passes (mostly in base/compiler/ssair/)Optimization passes (mostly in base/compiler/ssair/)performanceMust go fasterMust go faster
Description
I'm not sure if this can cause correctness issues, but we might be losing optimizations because of this.
julia/base/compiler/ssair/passes.jl
Line 1230 in 675e30a
# check whether this statement is `getfield` / `setfield!` (or other "interesting" statement) |
Metadata
Metadata
Assignees
Labels
compiler:optimizerOptimization passes (mostly in base/compiler/ssair/)Optimization passes (mostly in base/compiler/ssair/)performanceMust go fasterMust go faster
Type
Projects
Milestone
Relationships
Development
Select code repository
Activity
topolarity commentedon Feb 22, 2024
Not a soundness problem, since these count as an "escaping" usage:
julia/base/compiler/ssair/passes.jl
Lines 1671 to 1674 in 675e30a
But still worth fixing.
gbaraldi commentedon Feb 22, 2024
They are as escaping as setfield! (and kind of behave very much like it) with swap just being get + set.
vtjnash commentedon Feb 22, 2024
There is not usually any loss of optimization, since generally the value already "escaped" to another thread anyways