I’ve got some C++ class used in a project.
After I introduced some interfaces and implementation (no data!) for these interfaces to avoid using dynamic_cast the memory requirements of the class blew up.
I’m trying to figure out what the compiler is doing.
Initially I thought that the notion of virtual base class causes the increase in memory requirements.
Then I avoided this feature and did not find any improvement.
From the -fdump-class-hierarchy I’m only getting the size and alignment but not which member consumes the memory.
Please no asking for source!
I’m already trying to deduce which C++ feature causes which size increase — but until now unsuccessfully.
Some very unhelpful AI suggested the tool pahole — which only gave me a bunch of error message about “tag not supported”.
2