You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm getting simulation compile errors on Ubuntu 22 LTS and Oracle Linux 9.2 and I think it is related to gcc 11.
I'm using the latest Trick from the repo on a fresh install of both Ubuntu 22 LTS and OL 9.2 using the Trick installation instructions. Also I am using the latest TrickHLA code from master.
The simulation does compile and link even with these errors. I think this is during ICG.
I show the simulation errors for both Ubuntu and OL below:
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:566:5: error: 'malloc' attribute takes no arguments
__attr_dealloc_free;
^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:691:30: note: expanded from macro '__attr_dealloc_free'
/usr/include/x86_64-linux-gnu/sys/cdefs.h:690:21: note: expanded from macro '__attr_dealloc' attribute ((malloc (dealloc, argno)))
^
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:570:14: error: 'malloc' attribute takes no arguments
__THROW __attr_dealloc (reallocarray, 1);
^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:690:21: note: expanded from macro '__attr_dealloc' attribute ((malloc (dealloc, argno)))
^
(not showing all the errors)
=======================================================
Red Hat Enterprise Linux release 9.2 (Plow)
gcc (GCC) 11.3.1 20221121 (Red Hat 11.3.1-4.3.0.1)
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:38:
In file included from /usr/include/c++/11/iosfwd:40:
In file included from /usr/include/c++/11/bits/postypes.h:40:
In file included from /usr/include/c++/11/cwchar:44:
/usr/include/wchar.h:155:24: error: 'malloc' attribute takes no arguments attribute_malloc __attr_dealloc_free;
^
/usr/include/sys/cdefs.h:683:30: note: expanded from macro '__attr_dealloc_free'
/usr/include/sys/cdefs.h:682:21: note: expanded from macro '__attr_dealloc' attribute ((malloc (dealloc, argno)))
^
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:565:5: error: 'malloc' attribute takes no arguments
__attr_dealloc_free;
^
/usr/include/sys/cdefs.h:683:30: note: expanded from macro '__attr_dealloc_free'
Yeah I agree that you probably shouldn't trust this in production even though it links, the io_src attributes are likely mangled. I'll investigate this and see if we can come up with a solution.
After much reading (and talking with ChatGPT!) I think the fix for the malloc error is in LLVM/clang's court. I think we'll just have to wait for a fix and live with the non-fatal error until LLVM/clang accomodate gcc 11's malloc attribute with arguments.
I see no workaround. The last comment I gave didn't work for S_source.hh.
I'm getting simulation compile errors on Ubuntu 22 LTS and Oracle Linux 9.2 and I think it is related to gcc 11.
I'm using the latest Trick from the repo on a fresh install of both Ubuntu 22 LTS and OL 9.2 using the Trick installation instructions. Also I am using the latest TrickHLA code from master.
The simulation does compile and link even with these errors. I think this is during ICG.
I show the simulation errors for both Ubuntu and OL below:
====================================
Ubuntu 22.04.3 LTS
gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:566:5: error: 'malloc' attribute takes no arguments
__attr_dealloc_free;
^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:691:30: note: expanded from macro '__attr_dealloc_free'
define __attr_dealloc_free __attr_dealloc (__builtin_free, 1)
/usr/include/x86_64-linux-gnu/sys/cdefs.h:690:21: note: expanded from macro '__attr_dealloc'
attribute ((malloc (dealloc, argno)))
^
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:570:14: error: 'malloc' attribute takes no arguments
__THROW __attr_dealloc (reallocarray, 1);
^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:690:21: note: expanded from macro '__attr_dealloc'
attribute ((malloc (dealloc, argno)))
^
(not showing all the errors)
=======================================================
Red Hat Enterprise Linux release 9.2 (Plow)
gcc (GCC) 11.3.1 20221121 (Red Hat 11.3.1-4.3.0.1)
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:38:
In file included from /usr/include/c++/11/iosfwd:40:
In file included from /usr/include/c++/11/bits/postypes.h:40:
In file included from /usr/include/c++/11/cwchar:44:
/usr/include/wchar.h:155:24: error: 'malloc' attribute takes no arguments
attribute_malloc __attr_dealloc_free;
^
/usr/include/sys/cdefs.h:683:30: note: expanded from macro '__attr_dealloc_free'
define __attr_dealloc_free __attr_dealloc (__builtin_free, 1)
/usr/include/sys/cdefs.h:682:21: note: expanded from macro '__attr_dealloc'
attribute ((malloc (dealloc, argno)))
^
In file included from /home/ddexter/projects/TrickHLA/sims/SpaceFOM/SIM_Roles_Test/S_source.hh:11:
In file included from /usr/include/c++/11/iostream:39:
In file included from /usr/include/c++/11/ostream:38:
In file included from /usr/include/c++/11/ios:42:
In file included from /usr/include/c++/11/bits/ios_base.h:41:
In file included from /usr/include/c++/11/bits/locale_classes.h:40:
In file included from /usr/include/c++/11/string:55:
In file included from /usr/include/c++/11/bits/basic_string.h:6608:
In file included from /usr/include/c++/11/ext/string_conversions.h:41:
In file included from /usr/include/c++/11/cstdlib:75:
/usr/include/stdlib.h:565:5: error: 'malloc' attribute takes no arguments
__attr_dealloc_free;
^
/usr/include/sys/cdefs.h:683:30: note: expanded from macro '__attr_dealloc_free'
define __attr_dealloc_free __attr_dealloc (__builtin_free, 1)
/usr/include/sys/cdefs.h:682:21: note: expanded from macro '__attr_dealloc'
attribute ((malloc (dealloc, argno)))
^
(not showing all the errors)
The text was updated successfully, but these errors were encountered: