[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20241123215522.GB2171629@robin.jannau.net>
Date: Sat, 23 Nov 2024 22:55:22 +0100
From: Janne Grunau <j@...nau.net>
To: Danilo Krummrich <dakr@...nel.org>
Cc: Asahi Lina <lina@...hilina.net>, Miguel Ojeda <ojeda@...nel.org>,
Alex Gaynor <alex.gaynor@...il.com>,
Boqun Feng <boqun.feng@...il.com>, Gary Guo <gary@...yguo.net>,
Björn Roy Baron <bjorn3_gh@...tonmail.com>,
Benno Lossin <benno.lossin@...ton.me>,
Andreas Hindborg <a.hindborg@...nel.org>,
Alice Ryhl <aliceryhl@...gle.com>, Trevor Gross <tmgross@...ch.edu>,
rust-for-linux@...r.kernel.org, linux-kernel@...r.kernel.org,
asahi@...ts.linux.dev
Subject: Re: [PATCH] rust: alloc: Fix `ArrayLayout` allocations
On Sat, Nov 23, 2024 at 09:08:35PM +0100, Danilo Krummrich wrote:
> On Sat, Nov 23, 2024 at 07:29:38PM +0900, Asahi Lina wrote:
> > We were accidentally allocating a layout for the *square* of the object
> > size due to a variable shadowing mishap.
> >
> > Fixes memory bloat and page allocation failures in drm/asahi.
> >
> > Reported-by: Janne Grunau <j@...nau.net>
> > Fixes: 9e7bbfa18276 ("rust: alloc: introduce `ArrayLayout`")
> > Signed-off-by: Asahi Lina <lina@...hilina.net>
>
> Good catch!
>
> Acked-by: Danilo Krummrich <dakr@...nel.org>
>
> (I'm just back from moving and just starting to catch up on what was going on
> in the last few weeks.)
>
> Is this related to the performance regression that has been observed by Andreas?
> Or did it turn out to be a false positive?
No idea. We noticed KVec allocation errors with page order 4 to 8 under
memory pressure which weren't observed with the previous allocator (or at
least not that easily).
I haven't noticed performance regressions with asahi's usage. glmark2
score was roughly at the expected value.
Janne
Powered by blists - more mailing lists