GMP Error Reporting

Paul Zimmermann Paul.Zimmermann at inria.fr
Mon Aug 21 10:29:44 CEST 2023


       Hi,

it appears the value of c3 before the call mpf_sqrt() is negative,
and mpf_sqrt() does not allow negative inputs.

Best regards,
Paul Zimmermann

> From: "posihydr" <posihydr at qq.com>
> Date: Sat, 19 Aug 2023 21:50:37 +0800
> 
> 
> [1:text/plain Hide]
> 
> A description of the problem:
> The problem occurs when the formula in GMP and < Picture 1> is used to calculate PI, calculate the constant C to the 3/2 power, output "Floating point exception" after running the program, and use GDB debugging to find that the program receives signal SIGFPE when calling mpf_sqrt function.
> The following is written according to the https://gmplib.org/manual/Reporting-Bugs report:
> 1. GMP Version number: 6.3.0 (not prepackaged and not patched)
> 2. The test program is <bug.c>, which can be run directly after compilation
> 3. The program crashes directly
> 4. < Picture 2>
> 5. None
> 6../configure --prefix=/opt/gmp-6.3.0
> 7. I can't provide the information as it was built
> 8. < Picture 3>
> 9. < Picture 3>
> 10. aarch64-unknown-linux-gnu
> 11. None
> 12. None
> 
> 
> It was translated from Chinese by Youdao.
> 
> [2:application/octet-stream Show Save:bug.c (975B)]
> 
> 
> [3:application/octet-stream Show Save:Picture 1.jpg (140kB)]
> 
> 
> [4:application/octet-stream Show Save:Picture 2.jpg (426kB)]
> 
> 
> [5:application/octet-stream Show Save:Picture 3.jpg (466kB)]
> 
> 
> [6:text/plain Hide]
> 
> _______________________________________________
> gmp-bugs mailing list
> gmp-bugs at gmplib.org
> https://gmplib.org/mailman/listinfo/gmp-bugs


More information about the gmp-bugs mailing list