4 ms·
One of the other exciting things in this release is the almost entirely rewritten "prove" pass in the compiler: https://golang.org/doc/go1.11#performance-compi
by bradfitz 8y ago
One of the other exciting things in this release is the almost entirely rewritten "prove" pass in the compiler:
https://golang.org/doc/go1.11#performance-compiler https://golang.org/doc/go1.11#performance-compiler
> The compiler now performs significantly more aggressive bounds-check and branch elimination. Notably, it now recognizes transitive relations, so if i<j and j<len(s), it can use these facts to eliminate the bounds check for s[i]. It also understands simple arithmetic such as s[i-10] and can recognize more inductive cases in loops. Furthermore, the compiler now uses bounds information to more aggressively optimize shift operations.