From the whole thread I get an impression OP has interesting imagination how memory management should work.
Matthew van Eerde
After looking at the traces, we see that your realtime thread is running into page faults when doing memcpy.
In simple words, the buffers was swapped to HDD...
People try to write "real time" code without explicit lock on used memory. So they complain the system has not automatically locked REQUIRED memory (how system should deduct which memory app developers are going to use for real time and which not?)
Later they complain that in case they start to lock memory, they will get out of memory quickly.
Well... if you have insufficient memory, it is not possible to keep things in it. They do not "fit". So the system swap. And so there can be hard locks. More or less logical, no?
As a practical advise, disabling swap can prevent many problems. That can also trigger "Out of memory", but then it is explicitly clear its time to get more RAM.