Re: MLock errors on Intel 8-core systems
Re: MLock errors on Intel 8-core systems
- Subject: Re: MLock errors on Intel 8-core systems
- From: Terry Lambert <email@hidden>
- Date: Mon, 6 Oct 2008 12:49:16 -0700
On Oct 4, 2008, at 4:30 PM, Tony Scaminaci wrote:
I'm the author of memtestosx and I recently started receiving
reports of mlock failures in single-user mode. Specifically, I've
had 3 users report that mlock fails to lock more than 4GB of memory
in a single process. I see in the mlock man pages that this indeed
appears to be the limit and that a few new error codes were added
since the last time I did any work with mlock. However, the strange
thing is that this error is only appearing on 8-core Intel machines.
I've received no reports of problems from any other users. Here's
the error returned by memtest which is mlock error code EAGAIN:
Mac OS X 10.5.4 (9E25) running in single user mode
Memory Page Size: 4096
System has 8 Intel core(s) with SSE
Requested memory: 9756MB (10230386688 bytes)
Available memory: 9756MB (10230386688 bytes)
NOTE: Memory request is too large, reducing to acceptable value...
Allocated memory: 9483MB (9943935808 bytes) at local address
0x0000000101000000
Attempting memory lock... ERROR: System or per-process limit
exceeded - reducing and trying again...
Users are reporting that reducing the requested test allocation to
4GB rather than all installed ram allows mlock to succeed on the 8-
core systems.
So this raises a few questions:
1. Why is this error only occuring on 8-core systems?
No idea.
2. Why is there a lock limit of 4GB now when there hasn't been in
the past? I've had many users with 16GB of installed ram who never
saw this error on other platforms. Or maybe the limit has always
been there and is only manifesting itself on the 8-core machines?
Because each mapping range is limited to 4G. We could have made it
work by causing multiple mapping ranges to be iterated, but we
didn't. In general, we view mlock as a necessary-for-UNIX-conformance
evil. If you want to lock a larger region than 4G, you'll need to
call it multiple times.
3. Is locking memory for mass testing even necessary in single-user
mode? Would I be better off skipping the mlock process for single-
user runs?
I don't think you will be able to identify the faulty chips from an
mlocked region, since the addresses are virtual and you will have a
hard time figuring out the correspondance. That said, if the regions
are locked, the physical/virtual mapping will not move around on you
or get paged, and ou are more likely to get a reproducible result.
-- Terry
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden