Ubuntu has a built in file cache which is mostly automatic and greatly helps with performance. I am running an application whose performance highly sensitive to memory access speeds and application is running on a 2 socket solution. Application is using GPU and memory and finally outputs to a disk.
If memory is not allocated on the correct socket, the performance degrades by half so memory control is very important. Application makes multiple iterations on the same buffer to process them iteratively. I am using numactl to pin the application to correct socket and set the preferred memory allocator.
File cache is giving me hard time here:
1. Allocating memory on the target socket, forcing app to use the wrong socket. I work around that problem by force freeing the cache memory and restart the app but that's cumbersome and takes my time for manual intervention. ( /proc/sys/vm/drop_caches )
2. Allocating memory for drives where cache is not and starving disks where the cache would help as we quickly want to offload the memory. I tried to work around this by disabling disk cache and hoping that this would also turn off memory buffer for the disk but it didn't work that way.
In short, I need to be able to turn off memory buffer/cache or set the size for some disks to ensure memory is available where it is needed. That would help me to solve ally my problems but I couldn't find any such setting. Is there one?
If memory is not allocated on the correct socket, the performance degrades by half so memory control is very important. Application makes multiple iterations on the same buffer to process them iteratively. I am using numactl to pin the application to correct socket and set the preferred memory allocator.
File cache is giving me hard time here:
1. Allocating memory on the target socket, forcing app to use the wrong socket. I work around that problem by force freeing the cache memory and restart the app but that's cumbersome and takes my time for manual intervention. ( /proc/sys/vm/drop_caches )
2. Allocating memory for drives where cache is not and starving disks where the cache would help as we quickly want to offload the memory. I tried to work around this by disabling disk cache and hoping that this would also turn off memory buffer for the disk but it didn't work that way.
In short, I need to be able to turn off memory buffer/cache or set the size for some disks to ensure memory is available where it is needed. That would help me to solve ally my problems but I couldn't find any such setting. Is there one?