[cfe-dev] Detection of poor data layout / packing.

Ólafur Waage olafurw at gmail.com
Sat Sep 7 12:27:45 PDT 2013


Hey,

I asked about this a while back but got no answers. And after seeing the GN
talks and specially also after watching Andrei talking about data layout
I'm tempted to ask again.

Are there any tools within clang/llvm that detect poor data packing in
classes?

I saw that there exist some flags that can print out the current data
structure and the memory offset of each member variable. But it seemed not
to work that well given anything else outside of some testing code and
trying to parse it seemed to be hard (but not impossible)

Would it make sense to try to have a tool or in some way emit the structure
and point out places where packing could be improved? If it would, and no
tool exists, I would be interested in helping out or doing something on my
own.

Cheers,
Olafur Waage
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130907/be0e916c/attachment.html>


More information about the cfe-dev mailing list