There is a compiler error with GCC 12 discussed here: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115824 This Pybind code triggers the bug and was causing our compiler tests to fail. To fix gem5 compilation for gcc 12 these warnings/errors have been suppressed for this code. This is a copy and paste of: https://github.com/pybind/pybind11/pull/5355 Change-Id: I9344951ef00d121ea0b609f4faa13dfe09aabb3b