# Rethinking optimization, lower ok for all Julia code (for e.g. faster startup) as a default?

**URL:** https://discourse.julialang.org/t/rethinking-optimization-lower-ok-for-all-julia-code-for-e-g-faster-startup-as-a-default/39843
**Category:** General Usage
**Created:** [May 20, 2020, 4:22pm UTC](https://discourse.julialang.org/t/rethinking-optimization-lower-ok-for-all-julia-code-for-e-g-faster-startup-as-a-default/39843 "2020-05-20T16:22:39Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![Palli](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/palli/32/3380_2.png) [@Palli](https://discourse.julialang.org/u/Palli)
#### Post date: [May 20, 2020, 10:19pm UTC](https://discourse.julialang.org/t/rethinking-optimization-lower-ok-for-all-julia-code-for-e-g-faster-startup-as-a-default/39843/4 "2020-05-20T22:19:11Z")

</div>

About the superoptimizer:

> **[1711.04422.pdf](https://arxiv.org/pdf/1711.04422.pdf)**
>
> 333.36 KB

> If we can automatically derive compiler optimizations, we might be able to sidestep some of the substantial engineering challenges involved in creating and maintaining a high-quality compiler.

Don’t get me wrong, I like how Julia is fast as C (while ironically it may feel slower than Python), and `@code_native` etc. It was made for technical computing/HPC, and I can see how people may think this suggestion of lower opt. is admitting defeat. But less optimization gives you time to use your time more wisely, with e.g. (always targeted) superoptimization.

@Elrod’s work with `@avx` may not be one in a strict sense, while it feels like it to me.

The way I see it, is, people giving up on Julia, for some work, where e.g. Python (or Perl) are good, so we’re sacrificing world dominance for the smaller HPC/Fortran environment/language replacement:

> [@Precompile a script?](https://discourse.julialang.org/t/precompile-a-script/5364/13):
>
> I guess maybe Julia is just at the point right now where it makes more sense not to use one for short scripts

I would hate to throw the bath out with the bathwater, and succeed at neither. It doesn’t have to be either or. I mean, to me (not all) Julia has proven to be a Fortran (and MATLAB) replacement. It’s the only inherently fast interactive language I know, but we know about the endless (well until recently) time-to-first-plot issue, and the “short script” problem above is just the same. Most people aren’t going to accept Julia as a Python/MATLAB replacement, until those issues go away, and they will stay to some degree with the current default.

---

_[View the full topic](https://discourse.julialang.org/t/rethinking-optimization-lower-ok-for-all-julia-code-for-e-g-faster-startup-as-a-default/39843)._
