On Tue, 2024-12-17 at 11:44 +0000, Indan Zupancic wrote:
Hello yf,
On 2024-12-17 06:26, Yanfeng Liu wrote:
Thanks for this information. Here I use it to get unused space for an Untyped object as `((1 << capBlockSize) - (capFreeIndex << seL4_MinUntypedBits))` following above information.
I also sum up the size of all unique Frame objects (indexed by capFrameBasePtr) as spaces used for Frames.
Then I noticed at some point of `sel4test-driver` app, the sum of total free Untyped in all CSpaces plus total unique frame size is still far less than total size of all original Untypeds.
I am wondering how can we explain this gap?
sel4test creates a lot of threads and objects, it doesn't create that much frames in general, except for the frame tests, so I would say that what you see is to be expected for sel4test. It's not like a typical program which would mostly use heap memory.
Thank you. I further checked the types of `mdbNext` and `mdbPrev` node of Untyped objects in the lists and noticed that most of them are of `Untyped` and `Frame` types! This is ture for several seL4 demos including sel4test. As per manual, Untyped can be split as smaller Untypeds and retyped to other objects. I can't understand why many `Frame` objects are before Untyped objects? maybe those Frame objects before Untyped objects aren't related to the latter, they are there due to the flattening effect only?
Greetings,
Indan
Regards, yf