Re: why does mlockall appear to make memcpy slower ?

From: Manfred Spraul (manfreds@colorfullife.com)
Date: Mon Apr 03 2000 - 14:22:18 EST


From: "Richard B. Johnson" <root@chaos.analogic.com>
> Not here. If I just comment out your mlockall() it runs at the
> same apparent speed one way or the other. FYI, I don't understand
> how you are calculating speed, but that's another question altogether.
>
I just checked the mlock()/mlockall() implementation: it doesn't force all
pages into memory as written in the man page :-)

It's a clear violation of the POSIX standard (12.1.1.2)
"Upon successful return from the mlockall() function that specifies
MCL_CURRENT, all currentlyu mapped pages of the process's address space
shall be memory resident and locked."

I'm not sure if we must break COW sharing, but the current code is wrong.

--
    Manfred

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Apr 07 2000 - 21:00:10 EST