Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Jul 2001 17:15:59 +0000 (GMT)
From:      "E.B. Dreger" <eddy+public+spam@noc.everquick.net>
To:        freebsd-smp@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG
Subject:   Resolved: AIO on SMP / locking / libc_r
Message-ID:  <Pine.LNX.4.20.0107011636250.1684-100000@www.everquick.net>
In-Reply-To: <Pine.LNX.4.20.0107011532020.1122-100000@www.everquick.net>

next in thread | previous in thread | raw e-mail | index | archive | help
(Responding to myself and merging two threads)

> Date: Sun, 1 Jul 2001 15:52:47 +0000 (GMT)
> From: E.B. Dreger <eddy+public+spam@noc.everquick.net>

> > I can't say very much about coherency problems on x86 but I can
> > say for shure that you have to worry about this on every other MP
> > platform including IA64.
> 
> Even if it's a non-issue on x86, I'd rather use macros to insert proper
> code on ia64, axp (if I ever port to that), and go to nothing on x86 (if
> that is indeed the correct behavior).
> 
> Looks like I need to do some digging on bus snooping, cache coherency,
> read/write reordering, MTRRs, and APICs. :-)

Once pointed in the right direction, a little Google searching turned up a
message from three years ago today, by none other than Terry Lambert.  SMP
synchronization is automatic, and Intel supports full MESI (modified,
exclusive, shared, and invalid) coherence.

Terry also mentioned that MMAP_HASSEMAPHORE was useful on MEI architecture
to flag the need for coherency.  MMAP_HASSEMAPHORE is apparently a NOP
flag on the x86.  Pointless on x86, but mandatory on MEI architectures.

Netch clarified off-list (and others on-list?) that memory IO is strictly
in-order on the x86.

I think that I have a handle on things now.  I'll try AIO on pages with
MMAP_HASSEMAPHORE set (pointless now but no-cost insurance for other
architectures), and handle locking between processes as I have been.  If
nothing else, it gives me a handy string for which to grep in my code. ;-)

Not yet sure how to handle reordering... If ia64 reorders, I guess that
I'll worry about that when FreeBSD runs on ia64. :-)

Thanks to all for putting up with this "SMP newbie".  Hopefully this post
will help summarize everything for any lurkers who were scratching their
heads in the same way that I was.


Thanks again to everyone for your help,
Eddy

---------------------------------------------------------------------------

Brotsman & Dreger, Inc.
EverQuick Internet Division

Phone: +1 (316) 794-8922 Wichita/(Inter)national
Phone: +1 (785) 865-5885 Lawrence

---------------------------------------------------------------------------

Date: Mon, 21 May 2001 11:23:58 +0000 (GMT)
From: A Trap <blacklist@brics.com>
To: blacklist@brics.com
Subject: Please ignore this portion of my mail signature.

These last few lines are a trap for address-harvesting spambots.  Do NOT
send mail to <blacklist@brics.com>, or you are likely to be blocked.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-smp" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.4.20.0107011636250.1684-100000>