All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/10] bulk cpu removal support
@ 2006-05-08  5:45 Shaohua Li
  2006-05-08  6:29 ` Nathan Lynch
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: Shaohua Li @ 2006-05-08  5:45 UTC (permalink / raw)
  To: lkml; +Cc: Zwane Mwaikambo, Srivatsa Vaddagiri, Ashok Raj, Andrew Morton

CPU hotremove will migrate tasks and redirect interrupts off dead cpu.
To remove multiple CPUs, we should iteratively do single cpu removal.
If tasks and interrupts are migrated to a cpu which will be soon
removed, then we will trash tasks and interrupts again. The following
patches allow remove several cpus one time. It's fast and avoids
unnecessary repeated trash tasks and interrupts. This will help NUMA
style hardware removal and SMP suspend/resume. Comments and suggestions
are appreciated.

Thanks,
Shaohua

^ permalink raw reply	[flat|nested] 17+ messages in thread
* RE: [PATCH 0/10] bulk cpu removal support
@ 2006-05-14 20:49 Protasevich, Natalie
  0 siblings, 0 replies; 17+ messages in thread
From: Protasevich, Natalie @ 2006-05-14 20:49 UTC (permalink / raw)
  To: Nathan Lynch, Ashok Raj
  Cc: Martin Bligh, Andrew Morton, shaohua.li, linux-kernel, zwane,
	vatsa, nickpiggin

Ashok Raj wrote:
> > On Thu, May 11, 2006 at 01:42:47PM -0700, Martin Bligh wrote:
> > > Ashok Raj wrote:
> > > > 
> > > > 
> > > > It depends on whats running at the time... with some 
> light load, i 
> > > > measured wall clock time, i remember seeing 2 secs at 
> times, but 
> > > > its been a long time i did that.. so take that with a pinch :-)_
> > > > 
> > > > i will try to get those idle and load times worked out again... 
> > > > the best i have is a  16 way, if i get help from big 
> system oems i 
> > > > will send the numbers out
> > > 
> > > Why is taking 30s to offline CPUs a problem?
> > > 
> > 
> > Well, the real problem is that for each cpu offline we 
> schedule a RT 
> > thread
> > kstopmachine() on each cpu, then turn off interrupts until this one 
> > cpu has removed. stop_machine_run() is a big enough sledge hammer 
> > during cpu offline and doing this repeatedly... say on a 4 socket 
> > system, where each socket=16 logical cpus.
> > 
> > the system would tend to get hick ups 64 times, since we do the 
> > stopmachine thread once for each logical cpu. When we want 
> to replace 
> > a node for reliability reasons, its not clear if this hick 
> ups is a good thing.
> 
> Can you provide more detail on what you mean by hiccups?
>
> 
> > Doing kstopmachine() on a single system is in itself 
> noticable, what 
> > we heard from some OEM's is this would have other app level 
> impact as well.
> 
Per Ashok's request here is some data on offlining with cpu_bulk_remove
vs. sequentially with a shell script.
I had 64x system (physical CPU) and 128 (those 64 hyperthreaded). The
system was idle. 
Elapsed times are not strikingly different but system/user times are:

                64 CPU                                          128 CPU
(64 physical hyperthreaded)
                cpu_bulk_remove         shell script
cpu_bulk_remove         shell script
all offline     real    0m11.231s       real    0m10.775s       real
0m26.973s       real    0m16.484s
                user    0m0.000s        user    0m0.056         user
0m0.000s        user    0m0.068s
                sys     0m0.072s        sys     0m0.448         sys
0m0.132s        sys     0m1.312s

                real    0m11.977s       real    0m10.550s       real
0m28.978s       real    0m14.259s
                user    0m0.000s        user    0m0.064s        user
0m0.000s        user    0m0.060s
                sys     0m0.032s        sys     0m0.464s        sys
0m0.152s        sys     0m1.432s

32 offline      real    0m1.320s        real    0m2.422s        real
0m1.647s        real    0m1.896s
                user    0m0.000s        user    0m0.000s        user
0m0.000s        user    0m0.020s
                sys     0m0.076s        sys     0m0.232s        sys
0m0.096s        sys     0m0.456s

                real    0m1.407s        real    0m3.348s        real
0m0.418s        real    0m1.198s
                user    0m0.000s        user    0m0.012s        user
0m0.000s        user    0m0.008s
                sys     0m0.072s        sys     0m0.276s        sys
0m0.044s        sys     0m0.244s

groups of 16    real 0m5.877s           real 0m11.403s
                user 0m0.000s           user 0m0.024s
                sys 0m0.140s            sys 0m0.408s

groups of 8     real 0m8.847s           real 0m12.078s          real
0m12.311s       real    0m12.736s
                user 0m0.004s           user 0m0.028s           user
0m0.004s        user    0m0.076s
                sys 0m0.232s            sys 0m0.536s            sys
0m0.448s        sys     0m1.448s

                                                                real
0m11.968s       real    0m14.314s
                                                                user
0m0.008s        user    0m0.084s
                                                                sys
0m0.400s        sys     0m1.492s

With smaller "bulks" cpu_bulk_remove is always better, but with large
ones shell script mostly wins, especially with hyperthreading (despite
of much better system and user times!)

Thanks,
--Natalie

^ permalink raw reply	[flat|nested] 17+ messages in thread
* RE: [PATCH 0/10] bulk cpu removal support
@ 2006-05-14 21:28 Protasevich, Natalie
  0 siblings, 0 replies; 17+ messages in thread
From: Protasevich, Natalie @ 2006-05-14 21:28 UTC (permalink / raw)
  To: Protasevich, Natalie, Nathan Lynch, Ashok Raj
  Cc: Martin Bligh, Andrew Morton, shaohua.li, linux-kernel, zwane,
	vatsa, nickpiggin

[-- Attachment #1: Type: text/plain, Size: 2929 bytes --]

> Per Ashok's request here is some data on offlining with 
> cpu_bulk_remove vs. sequentially with a shell script.
> I had 64x system (physical CPU) and 128 (those 64 
> hyperthreaded). The system was idle. 
> Elapsed times are not strikingly different but system/user times are:
> 
>                 64 CPU                                        
>   128 CPU
> (64 physical hyperthreaded)
>                 cpu_bulk_remove         shell script
> cpu_bulk_remove         shell script
> all offline     real    0m11.231s       real    0m10.775s       real
> 0m26.973s       real    0m16.484s
>                 user    0m0.000s        user    0m0.056         user
> 0m0.000s        user    0m0.068s
>                 sys     0m0.072s        sys     0m0.448         sys
> 0m0.132s        sys     0m1.312s
> 
>                 real    0m11.977s       real    0m10.550s       real
> 0m28.978s       real    0m14.259s
>                 user    0m0.000s        user    0m0.064s        user
> 0m0.000s        user    0m0.060s
>                 sys     0m0.032s        sys     0m0.464s        sys
> 0m0.152s        sys     0m1.432s
> 
> 32 offline      real    0m1.320s        real    0m2.422s        real
> 0m1.647s        real    0m1.896s
>                 user    0m0.000s        user    0m0.000s        user
> 0m0.000s        user    0m0.020s
>                 sys     0m0.076s        sys     0m0.232s        sys
> 0m0.096s        sys     0m0.456s
> 
>                 real    0m1.407s        real    0m3.348s        real
> 0m0.418s        real    0m1.198s
>                 user    0m0.000s        user    0m0.012s        user
> 0m0.000s        user    0m0.008s
>                 sys     0m0.072s        sys     0m0.276s        sys
> 0m0.044s        sys     0m0.244s
> 
> groups of 16    real 0m5.877s           real 0m11.403s
>                 user 0m0.000s           user 0m0.024s
>                 sys 0m0.140s            sys 0m0.408s
> 
> groups of 8     real 0m8.847s           real 0m12.078s          real
> 0m12.311s       real    0m12.736s
>                 user 0m0.004s           user 0m0.028s           user
> 0m0.004s        user    0m0.076s
>                 sys 0m0.232s            sys 0m0.536s            sys
> 0m0.448s        sys     0m1.448s
> 
>                                                                 real
> 0m11.968s       real    0m14.314s
>                                                                 user
> 0m0.008s        user    0m0.084s
>                                                                 sys
> 0m0.400s        sys     0m1.492s
> 
> With smaller "bulks" cpu_bulk_remove is always better, but 
> with large ones shell script mostly wins, especially with 
> hyperthreading (despite of much better system and user times!)
> 
Oops it all wrapped :O 
I'm attaching the data file instead, sorry about that.

--Natalie
> 

[-- Attachment #2: cpu_data --]
[-- Type: application/octet-stream, Size: 1477 bytes --]

		64 CPU						128 CPU (64 physical hyperthreaded)		
		cpu_bulk_remove		shell script		cpu_bulk_remove		shell script
all offline	real    0m11.231s	real    0m10.775s	real    0m26.973s	real    0m16.484s
		user    0m0.000s	user    0m0.056		user    0m0.000s	user    0m0.068s
		sys     0m0.072s	sys     0m0.448		sys     0m0.132s	sys     0m1.312s
				
		real    0m11.977s	real    0m10.550s	real    0m28.978s	real    0m14.259s
		user    0m0.000s	user    0m0.064s	user    0m0.000s	user    0m0.060s
		sys     0m0.032s	sys     0m0.464s	sys     0m0.152s	sys     0m1.432s
			
32 offline	real    0m1.320s	real    0m2.422s	real    0m1.647s	real    0m1.896s
		user    0m0.000s	user    0m0.000s	user    0m0.000s	user    0m0.020s
		sys     0m0.076s	sys     0m0.232s	sys     0m0.096s	sys     0m0.456s
						
		real    0m1.407s	real    0m3.348s	real    0m0.418s	real    0m1.198s
		user    0m0.000s	user    0m0.012s	user    0m0.000s	user    0m0.008s
		sys     0m0.072s	sys     0m0.276s	sys     0m0.044s	sys     0m0.244s	

groups of 16	real 0m5.877s		real 0m11.403s					
		user 0m0.000s		user 0m0.024s					
		sys 0m0.140s		sys 0m0.408s					
							
groups of 8	real 0m8.847s		real 0m12.078s		real    0m12.311s	real    0m12.736s	
		user 0m0.004s		user 0m0.028s		user    0m0.004s	user    0m0.076s	
		sys 0m0.232s		sys 0m0.536s		sys     0m0.448s	sys     0m1.448s	
						
								real    0m11.968s	real    0m14.314s	
								user    0m0.008s	user    0m0.084s	
								sys     0m0.400s	sys     0m1.492s	


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2006-05-14 21:28 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-05-08  5:45 [PATCH 0/10] bulk cpu removal support Shaohua Li
2006-05-08  6:29 ` Nathan Lynch
2006-05-08  7:39   ` Shaohua Li
2006-05-08  6:30 ` Ashok Raj
2006-05-11  6:06 ` Andrew Morton
2006-05-11 16:53   ` Ashok Raj
2006-05-11 17:02     ` Andrew Morton
2006-05-11 17:27       ` Ashok Raj
2006-05-11 20:42         ` Martin Bligh
2006-05-11 22:09           ` Ashok Raj
2006-05-12  0:04             ` Nathan Lynch
2006-05-11 17:19     ` Nathan Lynch
2006-05-11 17:40       ` Ashok Raj
2006-05-11 19:19         ` Nathan Lynch
2006-05-11 22:17           ` Ashok Raj
  -- strict thread matches above, loose matches on Subject: below --
2006-05-14 20:49 Protasevich, Natalie
2006-05-14 21:28 Protasevich, Natalie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.