Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-07 Thread Peter Zijlstra
On Sat, Oct 05, 2024 at 09:56:24AM -0700, Linus Torvalds wrote: > On Sat, 5 Oct 2024 at 09:16, Peter Zijlstra wrote: > > > > On Wed, Oct 02, 2024 at 10:39:15AM -0700, Linus Torvalds wrote: > > > So I think the real issue is that "active_mm" is an old hack from a > > > bygone era when we didn't hav

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-05 Thread Linus Torvalds
On Sat, 5 Oct 2024 at 09:16, Peter Zijlstra wrote: > > On Wed, Oct 02, 2024 at 10:39:15AM -0700, Linus Torvalds wrote: > > So I think the real issue is that "active_mm" is an old hack from a > > bygone era when we didn't have the (much more involved) full TLB > > tracking. > > I still seem to have

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-05 Thread Peter Zijlstra
On Wed, Oct 02, 2024 at 10:39:15AM -0700, Linus Torvalds wrote: > So I think the real issue is that "active_mm" is an old hack from a > bygone era when we didn't have the (much more involved) full TLB > tracking. I still seem to have these patches that neither Andy nor I ever managed to find time

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Linus Torvalds
On Tue, 1 Oct 2024 at 18:04, Mathieu Desnoyers wrote: > > Hazard pointers appear to be a good fit for replacing refcount based lazy > active mm tracking. If the mm refcount is this expensive, I suspect we really shouldn't use it at all. The thing is, we don't _need_ to use the mm refcount - the

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Jens Axboe
On 10/2/24 10:02 AM, Mathieu Desnoyers wrote: > On 2024-10-02 17:58, Jens Axboe wrote: >> On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: >>> On 2024-10-02 17:36, Mathieu Desnoyers wrote: On 2024-10-02 17:33, Matthew Wilcox wrote: > On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 17:58, Jens Axboe wrote: On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: On 2024-10-02 17:36, Mathieu Desnoyers wrote: On 2024-10-02 17:33, Matthew Wilcox wrote: On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue,

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Jens Axboe
On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: > On 2024-10-02 17:36, Mathieu Desnoyers wrote: >> On 2024-10-02 17:33, Matthew Wilcox wrote: >>> On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: > On Tue, Oct 01, 2024 at 09:02:01P

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 17:33, Matthew Wilcox wrote: On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: Hazard pointers appear to be a good fit for replacing refcount based laz

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Matthew Wilcox
On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: > On 2024-10-02 16:09, Paul E. McKenney wrote: > > On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: > > > Hazard pointers appear to be a good fit for replacing refcount based lazy > > > active mm tracking. > > > >

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: Hazard pointers appear to be a good fit for replacing refcount based lazy active mm tracking. Highlight: will-it-scale context_switch1_threads nr threads (-t) speedup 24

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Paul E. McKenney
On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: > Hazard pointers appear to be a good fit for replacing refcount based lazy > active mm tracking. > > Highlight: > > will-it-scale context_switch1_threads > > nr threads (-t) speedup > 24+3% > 48

[RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-01 Thread Mathieu Desnoyers
Hazard pointers appear to be a good fit for replacing refcount based lazy active mm tracking. Highlight: will-it-scale context_switch1_threads nr threads (-t) speedup 24+3% 48 +12% 96 +21% 192 +28% I'm curious to see w