Without getting into the detail, can you please visually say if I need to invest the time to further optimize my code?
@code_warntype
gives
p1.png
But JET.@test_opt
gives
p2.png
@code_warntype
looks okey. Some yellows but unions are rather small (3 elements max), so I assume the compiler flats them to if
statements ?
If that's the case, I don't really get why JET says that dynamic dispatch will take place.
Is there a way to see whether dynamic dispatch is really happeping?
Profile view also looks also rather okey, right ? (No yellows and reds in the code)
p3.png
So, should I be afraid of the JET.@test_opt
report ?
Just realized the JET report appears yellow-ish, so... maybe no red and danger, but only yellow and a friendly heads-up ?
Without getting into the detail, can you please visually say if I need to invest the time to further optimize my code?
Looks reasonable to me. All code can be further optimized (or, at least, I haven't found any code that can't be). Whether or not it's worth doing depends mostly on whether the code is taking too long. If it's not a bottleneck then it's probably no worth your time to optimize it.
yeah, I am not after the julia dark magic optimizations. Just eliminating dynamic dispatch is enough but JET complains make me dubious.
Last updated: Dec 28 2024 at 04:38 UTC