Conversation
base/compiler/ssair/passes.jl
Outdated
| end | ||
|
|
||
| function simple_walk(compact::IncrementalCompact, @nospecialize(defssa#=::AnySSAValue=#), pi_callback=(pi, idx)->false) | ||
| function simple_walk(compact::IncrementalCompact, @nospecialize(defssa::AnySSAValue), |
There was a problem hiding this comment.
Declaring a type on a @nospecialize argument is normally a bad idea, as it may severely penalize the call
There was a problem hiding this comment.
Would you mind elaborating it ?
@nospecialize influences dispatches only at this moment, and I think every call of this function will be statically resolved anyway. And so I don't think there is any other effects than now we can get MethodError for wrong defssa types.
There was a problem hiding this comment.
it removes it from the dispatch cache
base/compiler/ssair/passes.jl
Outdated
| end | ||
|
|
||
| function simple_walk_constraint(compact::IncrementalCompact, @nospecialize(defidx), @nospecialize(typeconstraint) = types(compact)[defidx]) | ||
| function simple_walk_constraint(compact::IncrementalCompact, @nospecialize(defssa::AnySSAValue), @nospecialize(typeconstraint) = types(compact)[defssa]) |
| # global assertion_counter | ||
| # assertion_counter::Int += 1 |
There was a problem hiding this comment.
We need another optimizer that optimizes our optimizer :p
There was a problem hiding this comment.
A bit seriously, we may want to put more efforts on integrating JET with Julia base.
a023da6 to
d936b81
Compare
|
Should be good to go once CI passes successfully. |
Built on top of #42355: - add more type signatures - add more `@nospecialize` decls - remove dead/debug code - add some docs on SROA and ADCE passes
- add more type signatures - add more `@nospecialize` decls - remove dead/debug code - add some docs on SROA and ADCE passes
- add more type signatures - add more `@nospecialize` decls - remove dead/debug code - add some docs on SROA and ADCE passes
Built on top of #42355:
@nospecializedecls for callbacks