Opened 7 years ago

Last modified 7 years ago

#4450 new defect

gosmore fails to start on debian and ubuntu, C standard violations

Reported by: jtaylor.debian@… Owned by: nroets@…
Priority: major Milestone:
Component: gosmore Version:
Keywords: Cc:

Description

gosmore only uses all of the cpu and does not start on debian wheezy and ubuntu precise. The version in debian is 20100711 but the code in svn head looks unchanged in regard to this bug.

From what I can tell this is due to the the compiler (gcc-4.6, gcc-4.7) assuming it can optimize based on the undefinedness of signed overflows.

disabling this with -fno-strict-overflow seems to fix the startup problem

the problematic code is probably libgosm.cpp:212 naively changing mask to unsigned fixes the startup but may break other stuff.

also that file probably contains casts violating the strict aliasing rule (which can be disabled with -fno-strict-aliasing)

please compile with -Wstrict-overflow and -Wstrict-aliasing=1 and try to fix the issues or disable these optimizations

Change History (1)

Note: See TracTickets for help on using tickets.