Category "memory-management"

Linux: buddy system free memory

Could anyone explain this code? page_idx = page_to_pfn(page) & ((1 << MAX_ORDER) - 1); page_to_pfn() have already return the page_idx, so what does

How to check c++ pointer pointing to invalid memory address?

Is there anyone show me how to check my pointer is pointing to an invalid memory address. #include<iostream> class Node{ public: int data; Node * ne

How is a Vector of Vector aligned in memory?

I understand as Set size of vector of vectors at run time describes, one can declare vector of vector as vector<vector<int> > ref; then resize t