I\'m trying to write a tool that will take as input some C code containing structs. It will compile the code, then find and output the size and offset of any padding the com
If you have access to Visual C++, you can add the following pragma to have the compiler spit out where and how much padding was added:
#pragma warning(enable : 4820)
At that point you can probably just consume the output of cl.exe and go party.