Closed
Description
A.
All @assert
s should be exceptional, and since it's a macro already, it should outline (@noinline
) automatically, as was manually done here (to avoid 3x speed regression):
https://github.com/JuliaLang/julia/pull/34237/files
B.
I was looking into optimizing factorial myself, and think in general throws should be outlined too, i.e. all preconditions. For now A. is a low hanging-fruit I think. I'm not sure, possibly after A. is done, throws can be implemented with asserts, getting B for free?
C.
Maybe there are complications when there are two or more asserts and/or throws, still I doubt solving A. and/or B. would be slower then. However possibly in that case something even better could be done?
Metadata
Metadata
Assignees
Labels
No labels