-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Slower binaries since some days #42935
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
I compile with: |
Old asm compared to the new asm: (Moved to a gist after suggestion by @pnkfelix). |
I also observe a time slowdown on when
(I note this largely to add the data point that this is not just a windows issue.) |
@leonardo-m it might be good to move those asm dumps to a gist; they're pretty long to scroll through on the thread... |
(Seems obvious from the asm dumps that one piece of low hanging fruit would be to add some inlining directives to |
I have few other similar small programs that got slower in this timeframe (but their slowdown is smaller. On average I've seen a 10%+ increase of run-time).
Yes, compilation time of my programs is also increased (perhaps because the compiler as well is slower). |
Sorry, I meant "executing this benchmark when compiled with new Allocator support." (The part I was trying to emphasize was that I duplicated the problem on a non-Windows platform) |
Yeah, this was picked up by perf.rlo as well. MIR end regions and then allocators slowed down compilation time in all crates, I believe. |
(yeah a little embarrassing to have authored both of those PRs and have to deal with the fallout now...) |
A collection of judiciously placed |
Very nice. I'll test your changes when they are in a Nightly. And I'll report if there are other performance regressions. |
However, the |
Also, it seems like @alexcrichton has independently added many of the same |
(yes, I just built a |
Replacing the step_by feature with iterator_step_by, and using .step_by(pp as usize), now the best-of-three run-time is 0.47 seconds. |
Hmm indeed, seems like the running times regressed further between |
1.20 is now beta |
Looking into this, some things I've learned:
tl;dr this is fixed, no need for a backport, closing. |
Thank you, this specific program is indeed fixed (run-time is now 0.40 s), but other performance regressions are not yet fixed, so I'll open other bug reports. |
Yes that'd be much appreciated, thanks @leonardo-m! |
This could have the same causes of Issue 42808 (i.e. regression due to #42313), or perhaps not.
This small test program solves the Euler problem number 214:
On my PC using nightly-2017-06-18-x86_64-pc-windows-gnu it runs in about 0.39 seconds, while using a more recent Nightly, like the current rustc 1.19.0-nightly (78d8416 2017-06-17), it runs in about 0.87 seconds.
The text was updated successfully, but these errors were encountered: