File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
graalpython/com.oracle.graal.python.cext/include/internal Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -367,9 +367,12 @@ _PyObject_IS_GC(PyObject *obj)
367367static inline size_t
368368_PyType_PreHeaderSize (PyTypeObject * tp )
369369{
370- // GraalPy change: we put only one pointer for dict, we don't store it inlined [GR-61996]
370+ /* Note: the pre-header size must have a 16-byte alignment. This is
371+ necessary for higher optimization levels which assume the alignment
372+ (inferred from the struct size) and emit instructions that require
373+ this alignment. */
371374 return _PyType_IS_GC (tp ) * sizeof (PyGC_Head ) +
372- _PyType_HasFeature (tp , Py_TPFLAGS_PREHEADER ) * /* 2 * */ sizeof (PyObject * );
375+ _PyType_HasFeature (tp , Py_TPFLAGS_PREHEADER ) * 2 * sizeof (PyObject * );
373376}
374377
375378void _PyObject_GC_Link (PyObject * op );
You can’t perform that action at this time.
0 commit comments