STINNER Victor added the comment: > If you really want to use packing, keep it. > > But please remove this: > """ > + /* ensure that the frame_t structure is packed */ > + assert(sizeof(frame_t) == (sizeof(PyObject*) + sizeof(int))); > """
I added this assertion to ensure that I used correct GCC __attribute__((packed)) and Visual Studio #pragma pack(4). It can now be removed, I checked at least one per compiler that the structure is packed :-) I will add a comment explaining that packing the structure is an optimization to reduce the memory footprint, it can be disabled if tracemalloc does crash because of it. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue18874> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com