Date: Wed, 2 Apr 2003 17:16:25 -0800 (PST) From: Nate Lawson <nate@root.org> To: Peter Wemm <peter@FreeBSD.org> Cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/conf options.i386 src/sys/i386/i386machdep.c mp_machdep.c pmap.c swtch.s src/sys/i386/include md_var.h pmap.h smp.h src/sys/i386/isa apic_vector.s intr_machdep.h src/sys/kern kern_switch.c kern_synch.c kern_thr.c kern_thread.c subr_witness.c ... Message-ID: <Pine.BSF.4.21.0304021706050.12767-100000@root.org> In-Reply-To: <20030402235345.90F4737B418@hub.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 2 Apr 2003, Peter Wemm wrote: > Commit a partial lazy thread switch mechanism for i386. it isn't as lazy > as it could be and can do with some more cleanup. Currently its under > options LAZY_SWITCH. What this does is avoid %cr3 reloads for short > context switches that do not involve another user process. This is awesome! > One non-trivial change was to select a new thread before calling > cpu_switch() in the first place. This allows us to catch the silly > case of doing a cpu_switch() to the current process. This happens > uncomfortably often. This simplifies a bit of the asm code in cpu_switch > (no longer have to call choosethread() in the middle). This has been > implemented on i386 and (thanks to jake) sparc64. The others will come > soon. This is actually seperate to the lazy switch stuff. Shouldn't there be a "if (thread == curthread) return;" in the scheduling code somewhere? -Nate
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0304021706050.12767-100000>