Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 455167 - Segmentation violation when using large precisions.
Summary: Segmentation violation when using large precisions.
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: mpfr
Version: 9
Hardware: x86_64
OS: Linux
low
high
Target Milestone: ---
Assignee: Ivana Varekova
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-07-13 11:17 UTC by c.h.
Modified: 2008-09-11 17:13 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-07-23 08:40:21 UTC


Attachments (Terms of Use)
ddd debugger screen capture during one bug (deleted)
2008-07-13 11:17 UTC, c.h.
no flags Details
Test program that causes the crashes depending on the precision value selected by uncommenting the particularly desired value. (deleted)
2008-07-13 11:24 UTC, c.h.
no flags Details

Description c.h. 2008-07-13 11:17:44 UTC
Description of problem:
Segmentation violation when using large precisions.

Version-Release number of selected component (if applicable):


How reproducible:
100%

Steps to Reproduce:
1.
2.
3.
  
Actual results:

I have seen many such crashes as a result of calling mpfr_out_str.
Other times I have seen a crash during mpfr_sqrt_ui.
In general these were seen to repeatedly occur at precisions
above 20*1024*1024, and seemingly get worse above precisions 
around 36*1024*1024 (which is to say that mpfr_out_str crashes at 20M
precision, and the times I saw mpfr_sqrt_ui crash the precision was set
to the higher numbers).


Expected results:


Additional info:

Sample code attached, as well as a screen shot with the debugger info.

Comment 1 c.h. 2008-07-13 11:17:44 UTC
Created attachment 311660 [details]
ddd debugger screen capture during one bug

Comment 2 c.h. 2008-07-13 11:24:17 UTC
Created attachment 311661 [details]
Test program that causes the crashes depending on the precision value selected by uncommenting the particularly desired value.

Makefile used; crashes also seen with -O1, -O2, without -g, and with gcc
instead of g++.

System has 8GB RAM, Q6600 quad-core CPU, unlimited ulimit for the user running
the program, should be plenty of free RAM at the time for the run.

OPT=-O0

mpfr_test:	mpfr_test.cc
	g++ $(OPT) -g -o $@ $< -lm -lmpfr

run_mpfr_test:
	ddd ./mpfr_test

$ uname -a
Linux localhost.localdomain 2.6.25.6-55.fc9.x86_64 #1 SMP Tue Jun 10 16:05:21
EDT 2008 x86_64 x86_64 x86_64 GNU/Linux

[cdh@localhost ~]$ rpm -qa | grep -i mpfr
mpfr-debuginfo-2.3.0-3.fc9.x86_64
mpfr-2.3.0-3.fc9.x86_64
mpfr-devel-2.3.0-3.fc9.x86_64

$rpm -qa | grep -i gmp
gmp-4.2.2-7.fc9.x86_64
gmp-devel-4.2.2-7.fc9.x86_64
gmp-debuginfo-4.2.2-7.fc9.x86_64

$rpm -qa | grep -i gcc
libgcc-4.3.0-8.x86_64
gcc-gfortran-4.3.0-8.x86_64
gcc-c++-4.3.0-8.x86_64
libgcc-4.3.0-8.i386
gcc-4.3.0-8.x86_64

Comment 3 Ivana Varekova 2008-07-23 08:40:21 UTC
Fixed in mpfr-2.3.1-1.fc10.

Comment 4 c.h. 2008-07-24 08:40:06 UTC
Thanks for the response to this.

I've just cleaned yum's caches, though, and it can find no reference to any
mpfr*.fc10 packages in rawhide or any other repository (though many other
unrelated rawhide fc10 packages are found listed as expected, so presumably my
system is working).  

Has this only very recently or not yet been integrated into the rawhide packages?

Is it possible to have this version also distributed under FC9 updates so that
no potentially excessive rawhide related dependency problems will exist for
users trying to employ this version under FC9?

Thank you once again.


Comment 5 Ivana Varekova 2008-07-24 11:01:54 UTC
The build was done yesterday so it will take a while before it will be on
mirrors soon.
I'm just creating the update to fc9, so it should be soon too. 

Comment 6 Fedora Update System 2008-07-24 11:31:16 UTC
mpfr-2.3.1-1.fc9 has been submitted as an update for Fedora 9

Comment 7 Fedora Update System 2008-09-11 17:13:14 UTC
mpfr-2.3.1-1.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.