[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0d336a3f-f317-4a70-942a-d87a3faa3a89@gmail.com>
Date: Tue, 10 Feb 2026 19:08:09 +0530
From: Shivam Kalra <shivamkalra98@...il.com>
To: Danilo Krummrich <dakr@...nel.org>,
Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
Vlastimil Babka <vbabka@...e.cz>, "Liam R. Howlett"
<Liam.Howlett@...cle.com>, Uladzislau Rezki <urezki@...il.com>,
Miguel Ojeda <ojeda@...nel.org>, Boqun Feng <boqun.feng@...il.com>,
Gary Guo <gary@...yguo.net>, Björn Roy Baron
<bjorn3_gh@...tonmail.com>, Benno Lossin <lossin@...nel.org>,
Andreas Hindborg <a.hindborg@...nel.org>, Alice Ryhl <aliceryhl@...gle.com>,
Trevor Gross <tmgross@...ch.edu>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Arve Hjønnevåg <arve@...roid.com>,
Todd Kjos <tkjos@...roid.com>, Christian Brauner <brauner@...nel.org>,
Carlos Llamas <cmllamas@...gle.com>
Cc: rust-for-linux@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 0/4] rust: alloc: add Vec shrinking methods
This is a follow-up to my v3 series:
https://lore.kernel.org/rust-for-linux/20260207-binder-shrink-vec-v3-v3-0-8ff388563427@cock.li/
Hi all,
Thanks for the feedback on v3. Before I respin, I want to confirm
the direction for v4 to avoid unnecessary iterations.
Proposed changes for v4:
1. Drop the Shrinkable trait entirely. Make shrink_to() a normal
method on Vec<T, A> that calls A::realloc(). (Danilo)
2. Add a temporary ShrinkQuirk trait to handle the vmalloc workaround
(page-boundary check + manual alloc+copy+free) until vrealloc
gains in-place shrinking support. (Danilo)
3. In the binder patch, use a less aggressive shrink strategy to
avoid shrink-then-regrow oscillation: (Alice)
if len < cap / 4 {
shrink_to(cap / 2);
}
4. Fix commit prefix to rust_binder: instead of rust: binder:. (Alice)
Also noting that starting from v4, I will be sending patches from
a new email address: shivamkalra98@...il.com
Does this look right? Any other concerns before I send v4?
Thanks,
Shivam
Note: I previously sent patches as shivamklr@...k.li. That account
has run out of quota, so I'm continuing from shivamkalra98@...il.com
going forward. All future patches (v4+) will come from this address.
Powered by blists - more mailing lists