Re: mlock in cache

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/02/2013 03:12 PM, Christos wrote:
> Hi everyone,
> 
> I am developing a program in C and I want to lock some memory pages in 
> cache, particularly in the core specific level (i.e. level 1). As far as 
> I know the C libraries do not provide an interface to do that so I guess 
> that there must be some particular directives in gcc to do so.

__builtin_prefetch() is what you need.  However, there's no way you'll be
able to lock anything in L1: it'll be evicted very shortly afterwards.

Andrew.





[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux