-
Notifications
You must be signed in to change notification settings - Fork 13.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
miri
is incorrectly built with jemalloc on some targets
#133748
Comments
Foe context: jemalloc does not work on Linux with 16k pages, it hardcodes 4k: jemalloc/jemalloc#467 |
That issue makes it sound like jemalloc should be able to work on this system (i.e., the hardcoding was removed?) if we (or maybe jemalloc-sys?) compiled it with e.g. a 64k "page" target? At least, that's my impression of the closing comment. |
Yes, we could compile jemalloc to make it work properly (and actually maybe that's what's already happening for rustc? unsure) |
Yes, 64K page mode is universal. For some vague performance-related reasons, jemalloc refuse to default to that on ARM64 and instead use 4K mode, which does not work with any other page size. You have to set |
bootstrap: Build jemalloc with support for 64K pages By default, jemalloc is built to only support the same page size as the host machine. Set an env variable so that jemalloc is built with support for page sizes up to 64K regardless of the host machine. r? `@Kobzol` Resolves rust-lang#134563 Potentially resolves rust-lang#133748 (needs verification) ---- Results from local rustc-perf testing below, within 0.5% on every metric except max-rss. AArch64:  x86_64: 
bootstrap: Build jemalloc with support for 64K pages By default, jemalloc is built to only support the same page size as the host machine. Set an env variable so that jemalloc is built with support for page sizes up to 64K regardless of the host machine. r? `@Kobzol` Resolves rust-lang#134563 Potentially resolves rust-lang#133748 (needs verification) ---- Results from local rustc-perf testing below, within 0.5% on every metric except max-rss. AArch64:  x86_64: 
Rollup merge of rust-lang#135081 - mrkajetanp:jemalloc-64k, r=Kobzol bootstrap: Build jemalloc with support for 64K pages By default, jemalloc is built to only support the same page size as the host machine. Set an env variable so that jemalloc is built with support for page sizes up to 64K regardless of the host machine. r? `@Kobzol` Resolves rust-lang#134563 Potentially resolves rust-lang#133748 (needs verification) ---- Results from local rustc-perf testing below, within 0.5% on every metric except max-rss. AArch64:  x86_64: 
This should be reopened after all, it needs its own fix. I think the miri you get from |
I tried to run
cargo miri run
in (any) workspace on Asahi Linux (which has 16k page kernels)I expected to see this happen: The program runs under miri similarly to how rustc works
Instead, this happened:
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: