Commit Graph

20 Commits

Author SHA1 Message Date
Oli Scherer 9a2362e5a9 Shrink the size of Rvalue by 16 bytes 2021-03-05 09:33:01 +00:00
Tomasz Miąsko 508eec49e9 Combine instructions immediately
No functional changes intended
2021-01-18 13:15:27 +01:00
Tomasz Miąsko a9292d871c Remove disabled transformation from instcombine 2021-01-18 13:15:27 +01:00
Olivia Crain 65b5e4386b Use PlaceRef more consistently in rustc_mir 2021-01-16 10:44:23 -06:00
bors e2a2592885 Auto merge of #79084 - simonvandel:instcombine-perf, r=oli-obk
Small perf changes for InstCombine
2020-12-29 06:21:18 +00:00
Simon Vandel Sillesen 0010fc8fec use exhaustive pattern match to prevent future bugs 2020-12-28 23:19:35 +01:00
cjkenn 51c2218d1f move fuel checks to later points in instcombine and const_prop, add opt level flag to test 2020-11-18 08:49:46 -05:00
cjkenn 78a37f888a add optimization fuel checks to some mir passes 2020-11-16 18:09:10 -05:00
Simon Vandel Sillesen 3d5a1e330f Only go through the body if something can be optimized 2020-11-15 22:34:54 +01:00
Simon Vandel Sillesen 307c60843c Do not call super_rvalue if not needed 2020-11-15 22:34:53 +01:00
Jonas Schievink 0be35cf9c7 Disable "optimization to avoid load of address" in InstCombine 2020-10-27 10:59:28 +01:00
Simon Vandel Sillesen 57d01a9aee Check which places are dead
Fixes #78192
2020-10-22 22:23:56 +02:00
Tomasz Miąsko e200a4a0d2 Disable "optimization to avoid load of address" in InstCombine 2020-10-21 00:00:00 +00:00
Dylan MacKenzie 6f61e71648 Remember the `MirSource` for each `Body` 2020-10-04 11:01:38 -07:00
Simon Vandel Sillesen 2bb3844820 Add optimization to avoid load of address 2020-09-21 22:08:27 +02:00
Matthias Krüger 73d4171ea6 fix a couple of stylistic clippy warnings
namely:

clippy::redundant_pattern_matching
clippy::redundant_pattern
clippy::search_is_some
clippy::filter_next
clippy::into_iter_on_ref
clippy::clone_on_copy
clippy::needless_return
2020-09-15 22:44:54 +02:00
Simon Vandel Sillesen 9b0fc6202b Generalize to Eq(true, _place) and Eq(_place, true) 2020-09-06 11:51:44 +02:00
Simon Vandel Sillesen c2693db264 Add peephold optimization that simplifies Ne(_1, false) and Ne(false, _1) into _1
This was observed emitted from the MatchBranchSimplification pass.
2020-09-06 11:51:44 +02:00
LeSeulArtichaut 3e14b684dd Change ty.kind to a method 2020-09-04 17:47:51 +02:00
mark 9e5f7d5631 mv compiler to compiler/ 2020-08-30 18:45:07 +03:00