Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Shared Memory (Semaphore and mutex)



On Oct 1, 2004, at 7:43 AM, Marc Colosimo wrote:

On Sep 30, 2004, at 5:40 PM, Shaun Wexler wrote:
You can sometimes use light-weight sync 1 "lwsync" on G5-MP's, which allows loads to happen speculatively across the barrier **, but you probably need to leave the full sync instruction in there for G4-MP's... that's why the instruction exists: to ensure that modifications to a shared data structure (memory) is forced to a known state with respect to all other processors and concerned mechanisms in the system.

Crap. Is there a way with defines to do this; i.e., tell a G5 (power4 > models) from lesser powerpcs?

If you posted the entire code to your lock functions (ie what you need to do in the middle), maybe we could recommend something?


BTW, the commpage ...
What is this?

The commpage is in the first 0x1000 of an application's address space, and contains a jump table to many common functions such as simple locks, bzero, memcpy, etc. At startup, Mac OS X sets these pointers to optimized functions for the particular hardware config. Common library functions and macros are usually built upon these primitives.
--
Shaun Wexler
MacFOH
http://www.macfoh.com


Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
PerfOptimization-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/perfoptimization-dev/email@hidden

This email sent to email@hidden

References: 
 >Re: Shared Memory (Semaphore and mutex) (From: Marc Colosimo <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.