[Python-bugs-list] [ python-Bugs-738066 ] Interpreter crash: sigfpe on Alpha

SourceForge.net noreply@sourceforge.net
Mon, 26 May 2003 00:15:31 -0700


Bugs item #738066, was opened at 2003-05-15 07:52
Message generated for change (Comment added) made by jensj
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=738066&group_id=5470

Category: Python Interpreter Core
Group: Platform-specific
Status: Open
Resolution: None
Priority: 5
Submitted By: Jens Jørgen Mortensen (jensj)
Assigned to: Nobody/Anonymous (nobody)
Summary: Interpreter crash: sigfpe on Alpha

Initial Comment:
Multiplying two numbers makes the interpreter crash. 
The architecture is an Alpha running:

Digital UNIX V4.0F  (Rev. 1229); Sat Oct 26 16:44:55
MET DST 2002
Compaq Tru64 UNIX V4.0F  (Rev. 1229); Thu Mar 23
08:45:31 MET 2000

Python 2.2.1 (#1, Jun  4 2002, 15:33:18) [C] on osf1V4
Type "help", "copyright", "credits" or "license" for
more information.
>>> import os
>>> os.uname()
('OSF1', 'asrv', 'V4.0', '1229', 'alpha')
>>> 1e300 * 1e300
Floating exception (core dumped)


----------------------------------------------------------------------

>Comment By: Jens Jørgen Mortensen (jensj)
Date: 2003-05-26 09:15

Message:
Logged In: YES 
user_id=716463

I have tested the patch (http://python.org/sf/719359) and it
fixes my bug. Thanks.


----------------------------------------------------------------------

Comment By: Neal Norwitz (nnorwitz)
Date: 2003-05-25 18:45

Message:
Logged In: YES 
user_id=33168

This problem has a tentative solution.  Please test the
patch in http://python.org/sf/719359
Scroll to the bottom and click Download on the
osf-opts.patch line.  Thanks.


----------------------------------------------------------------------

Comment By: Tim Peters (tim_one)
Date: 2003-05-19 19:42

Message:
Logged In: YES 
user_id=31435

If someone knows how to make a config patch to pass -ieee 
automatically to this compiler, that would be helpful -- IIRC, 
this comes up a couple times per year.

----------------------------------------------------------------------

Comment By: Jens Jørgen Mortensen (jensj)
Date: 2003-05-19 17:52

Message:
Logged In: YES 
user_id=716463

I tried with Python-2.3b1: Same problem.

I then tried building with -ieee added to CFLAGS in Makefile
- That solved the problem!

Thanks



----------------------------------------------------------------------

Comment By: Tim Peters (tim_one)
Date: 2003-05-15 20:31

Message:
Logged In: YES 
user_id=31435

Python inherits its floating-point behavior from whatever your 
C compiler and libraries happen to do.  So, presumably a 
plain C program would do the same thing with this example.

If that's not what you want, your C compiler probably supports 
some option to compile code that acts more the way you 
want it to work, and then you should compile Python with that 
option too.

IIRC (I've never run on an Alpha), by default Alphas don't have 
compliant IEEE-754 fp arithmetic, and by default C compilers 
on Alphas don't try to repair that.  If the compiler you're using 
as an option named "-ieee", try it.

----------------------------------------------------------------------

Comment By: Neal Norwitz (nnorwitz)
Date: 2003-05-15 16:11

Message:
Logged In: YES 
user_id=33168

Is this still a problem with 2.2.2 or 2.3?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=738066&group_id=5470