[PATCH V4 4/6] mm: mlock: Introduce VM_LOCKONFAULT and add mlock flags to enable it

2015-07-23 Thread Vlastimil Babka
On 07/22/2015 08:43 PM, Eric B Munson wrote: > On Wed, 22 Jul 2015, Vlastimil Babka wrote: > >> >> Hi, >> >> I think you should include a complete description of which >> transitions for vma states and mlock2/munlock2 flags applied on them >> are valid and what they do. It will also help with th

[PATCH V4 4/6] mm: mlock: Introduce VM_LOCKONFAULT and add mlock flags to enable it

2015-07-23 Thread Eric B Munson
On Thu, 23 Jul 2015, Vlastimil Babka wrote: > On 07/22/2015 08:43 PM, Eric B Munson wrote: > > On Wed, 22 Jul 2015, Vlastimil Babka wrote: > > > >> > >> Hi, > >> > >> I think you should include a complete description of which > >> transitions for vma states and mlock2/munlock2 flags applied on

[PATCH V4 4/6] mm: mlock: Introduce VM_LOCKONFAULT and add mlock flags to enable it

2015-07-22 Thread Eric B Munson
On Wed, 22 Jul 2015, Vlastimil Babka wrote: > On 07/21/2015 09:59 PM, Eric B Munson wrote: > >The cost of faulting in all memory to be locked can be very high when > >working with large mappings. If only portions of the mapping will be > >used this can incur a high penalty for locking. > > > >For

[PATCH V4 4/6] mm: mlock: Introduce VM_LOCKONFAULT and add mlock flags to enable it

2015-07-22 Thread Vlastimil Babka
On 07/21/2015 09:59 PM, Eric B Munson wrote: > The cost of faulting in all memory to be locked can be very high when > working with large mappings. If only portions of the mapping will be > used this can incur a high penalty for locking. > > For the example of a large file, this is the usage patte

[PATCH V4 4/6] mm: mlock: Introduce VM_LOCKONFAULT and add mlock flags to enable it

2015-07-21 Thread Eric B Munson
The cost of faulting in all memory to be locked can be very high when working with large mappings. If only portions of the mapping will be used this can incur a high penalty for locking. For the example of a large file, this is the usage pattern for a large statical language model (probably appli