This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: fpectl module needs updating
Type: Stage:
Components: Library (Lib) Versions: Python 2.3
process
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: Nosy List: akuchling, loewis, stevech, tim.peters
Priority: normal Keywords:

Created on 2004-01-07 10:32 by stevech, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (4)
msg19568 - (view) Author: Steve Chaplin (stevech) Date: 2004-01-07 10:32
The fpectl module docs (Python Library Reference 3.4.2)
says
"Setting up a given processor to trap IEEE-754 floating
point errors currently requires custom code on a
per-architecture basis."

I think that is no longer accurate, we now have fenv.h,
which: 
- avoids the need for custom code, by using the
standard C99 header file
- should work on non-Unix and Unix systems

I think that the fpectl module could be rewritten and
greatly simplified using fenv.h
The Python module Numarray has done this and could be
used as an example.
msg19569 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2004-01-18 00:03
Logged In: YES 
user_id=21627

Can you provide a patch? The tricky part is to ensure
backwards compatibility if you are fundamentally changing
the implementation strategy.

Also, what compilers on what architectures support fenv.h?
That it is part of C99 does not make it automatically
available on all systems.
msg19570 - (view) Author: Tim Peters (tim.peters) * (Python committer) Date: 2004-01-18 00:19
Logged In: YES 
user_id=31435

Note the NEWS file for 2.3 said

"""
- The fpectl module is not built by default; it's dangerous or 
useless except in the hands of experts.
"""

The fpectl module should die.  It certainly still requires custom 
code on a per-*platform* basis regardless, since most C 
compilers used to build Python predate C99.  If we could 
assume C99 (we can't, just thinking out loud), then a new 
module offering full access to 754's features should supplant 
fpectl (fpectl now has a very narrow view of the world).
msg19571 - (view) Author: A.M. Kuchling (akuchling) * (Python committer) Date: 2006-08-03 14:37
Logged In: YES 
user_id=11375

May as well close this bug; fpectl was a candidate for
deletion in 2.5 and may finally go away in 2.6, so no one is
going to update it.
History
Date User Action Args
2022-04-11 14:56:02adminsetgithub: 39777
2004-01-07 10:32:37stevechcreate