bugPSPP - Bugs: bug #23263, Shouldn't need GSL for isinf,...

 
 

bug #23263: Shouldn't need GSL for isinf, isnan, and finite

Submitted by:  Ben Pfaff <blp>
Submitted on:  Fri 16 May 2008 05:41:30 AM UTC  
 
Category: Compilation/PortabilitySeverity: 5 - Average
Status: FixedAssigned to: None
Open/Closed: ClosedRelease: Post-0.6.0
Effort: 0.00

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Tue 29 Jul 2008 05:28:30 AM UTC, comment #6:

Thanks. I pushed this to the repo.

Ben Pfaff <blp>
Project Administrator
Mon 28 Jul 2008 05:37:45 AM UTC, comment #5:

Looks fine to me.

John Darrington <jmd>
Project Administrator
Sun 27 Jul 2008 06:12:14 PM UTC, comment #4:

Here is a patch that integrates the new gnulib modules into PSPP, changing it back to use the standard C99 functions.

Summary:

Use standard C99 isfinite, isnan, isinf in place of GSL substitutes.

In change a9afcdd22, "Use gsl_isnan instead of isnan, ...," isfinite,
isnan, and isinf were changed to use the GSL substitutes because of
lack of portability of the C99 versions. Now, gnulib has portable
versions of all of these, so change them back.

This commit changes calls to gsl_finite() to call isfinite() instead
of the equivalent finite(). isfinite() is correct here: both gsl_finite()
and finite() return true for NaNs, which is a surprising result given
that a NaN is definitely not finite, but isfinite() returns false and,
more importantly, behaves as actually wanted in each place it is used
in PSPP code.

This commit requires upgrading gnulib to at least change 5183a0e3c,
"Add missing dependencies on new m4/exponent[fdl].m4 files," or later,
and re-running "make -f Smake".

(file #16190)

Ben Pfaff <blp>
Project Administrator
Sat 26 Jul 2008 05:52:42 AM UTC, comment #3:

Status update: A module for portable "isinf" support has been checked into gnulib. This completes the needed gnulib support.

The remaining work, therefore, is simply to start using the modules in PSPP.

Ben Pfaff <blp>
Project Administrator
Sun 13 Jul 2008 06:24:00 PM UTC, comment #2:

Status update: A module for portable "isnan" support has been checked into gnulib.

Ben Pfaff <blp>
Project Administrator
Tue 08 Jul 2008 05:07:49 AM UTC, comment #1:

Status update:

The "finite" function shouldn't be used at all: its semantics are bizarre. It looks like all uses of finite(x) in PSPP can be replaced by isfinite(x), which is implemented portably by Gnulib.

The "isnan" function has a gnulib replacement in the works: http://permalink.gmane.org/gmane.comp.lib.gnulib.bugs/14028

The "isinf" function still needs a replacement.

Ben Pfaff <blp>
Project Administrator
Fri 16 May 2008 05:41:30 AM UTC, original submission:

Patch #6512 changed PSPP's uses of the isinf, isnan, and finite functions to use the equivalent functions from GSL instead. It would be better to add gnulib modules for these instead. As pointed out at http://article.gmane.org/gmane.comp.statistics.pspp.devel/1879, using GSL also creates an unnecessary dependency for the Perl module.

Ben Pfaff <blp>
Project Administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #16190:  foo.patch added by blp (8KiB - text/x-diff - proposed bug fix)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jmd (Updated the item)
  • -unavailable- added by blp (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 29 Jul 2008 05:28:30 AM UTCblpStatusReady for Test/Review=>Fixed
      Open/ClosedOpen=>Closed
    Sun 27 Jul 2008 06:12:14 PM UTCblpAttached File-=>Added foo.patch, #16190
      StatusNone=>Ready for Test/Review
    Sat 24 May 2008 11:25:58 PM UTCjmdReleaseNone=>Post-0.6.0

    Back to the top


    Powered by Savane 3.1-cleanup1