Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation of praat.cpp fails on i386 with g++ 13 #2433

Open
rlaboiss opened this issue Jul 22, 2023 · 5 comments
Open

Compilation of praat.cpp fails on i386 with g++ 13 #2433

rlaboiss opened this issue Jul 22, 2023 · 5 comments

Comments

@rlaboiss
Copy link
Member

The autobuild on an i386 system for the praat Debian package fails for version 6.3.11. The previous version (6.3.10) successfully built.

The sensible difference between these two runs is the fact that the former was built against g++ v12 and the latter against g++ v13.

The error message is the following:

Crashing bug: Praat will crash. Please notify the author (paul.boersma@uva.nl) with all of the following information (and please mention in your email precisely what you were doing when this crash occurred):

Assertion failed in file "praat.cpp" at line 2208:
   x3 [2] == 2.718

This error message percolated all the way to the top.

I wonder if the code in line 2207 of file sys/praat.cpp works properly on a 32-bit system.

@rlaboiss
Copy link
Member Author

rlaboiss commented Jul 23, 2023

I am currently applying a patch to the Debian package, which comments out the lines 2207 to 2010 in sys/praat.cpp.

@AdrianBunk
Copy link

The sensible difference between these two runs is the fact that the former was built against g++ v12 and the latter against g++ v13.

Yes, gcc 13 has new excess precision issues in C++ on i386/m68k/s390x.

There are two possible solutions:

  • build with -std=gnu++17 instead of -std=c++17 (e.g. by appending it to CXXFLAGS in debian/mk-vars-hardening), or
  • add -fexcess-precision=fast to CXXFLAGS

@rlaboiss
Copy link
Member Author

According to the GCC documentation, -fexcess-precision=fast is the default. Wouldn't the second option (add -fexcess-precision=fast to CXXFLAGS) be moot?

@AdrianBunk
Copy link

@rlaboiss The default differs in the "strict conformance" part of the paragraph.

@rlaboiss
Copy link
Member Author

@AdrianBunk: I changed the Debian package according to your suggestion (commit aaf9e43). The FTBFS is apparently fixed on i386 and the change does not seem to have an impact on amd64. Thanks for the tip!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants