Re: Multi pthreaded RT application - mlock doubt

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

 



Gentle ping on my below doubt...

Thanks,
Best Regards,
Dipen Patel

On 3/31/21 7:06 PM, Dipen Patel wrote:
> Hi,
> 
> I was following https://rt.wiki.kernel.org/index.php/Threaded_RT-application_with_memory_locking_and_stack_handling_example with some below changes:
> 
> 1. Added 8 threads
> 2. Moved show_new_pagefault_count logic inside thread function once thread starts running as below:
> 
> thread_fn {
> 
> 	getrusage(RUSAGE_SELF, &usage);
> 	
> 	print and save usage.ruminflt;
> 
> 	prove_thread_stack_use_is_safe
> 
> 	getrusage(RUSAGE_SELF, &usage);
> 
> 	print usage.ruminflt - last_saved_cnt;
> }
> 
> I observed there are still page faults (although not in big numbers as if there was no mlock), after touching stack in prove_thread_stack_use_is_safe call. I played around with MY_STACK_SIZE (from 1KB to 1MB) but still see minor page faults.
> 
> I am running 4.9.201_rt134 kernel. Any idea what I will be missing?
> 
> Best Regards,
> Dipen Patel
> 



[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux