Perf regression related to cold path code size growth in #2075 #2132
Labels
A-aliasing
Area: This affects the aliasing model (Stacked/Tree Borrows)
C-bug
Category: This is a bug.
I-slow
Impact: Makes Miri even slower than it already is
#2075 added a small but significant (~8%) runtime regression to Miri because it changed a simple comparison of an
Option<NonZeroU64>
to aHashSet::contains
call. This causes significant code size growth in a few functions, most notablyStack::check_protector
(now calleditem_popped
), which no longer gets inlined. The perf hit is particularly outsized here due to the large total size of all the arguments passed toStack::check_protector
.I suspect some strategic outlining of the tag tracking and error creation code paths would fix this, with the caution that the sheer size of the arguments required for all outlining sites may be an obstacle.
This perf regression will become much more noticeable once #1935 lands because currently it's easy to miss such perf issues due to the amount of time spent searching borrow stacks.
The text was updated successfully, but these errors were encountered: