> The nice Python folks who were at SCALE in Los Angeles last year gave me a
> Python t-shirt for showing Python working on m68k and for suggesting that
> I'd get it working on VAX. With libffi support for VAX from Miod Vallat,
> this is now possible.
>
> However, when compiling Python, it seems that attempts to evaluate NaN are
> made in test_complex.py, test_complex_args.py, test_float.py and
> test_math.py (at least in 2.7.5 - I'm working on compiling 3.3.2 now).
>
> The short answer is to skip those tests on VAXen. The better answer is to
> patch any isnan functions to always return false on VAXen and patch any code
> which tries to parse, for instance, float("NaN") to use something uncommon,
> such as the largest representable number (const union __double_u __infinity
> = { { 0xff, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff } };) or something else
> equally rare.

I think you are asking for trouble here.  As VAX floating point does
not appear to have hardware support for NaN, attempts to "emulate"
such could be potentially dangerous.  If such software were running
life-support systems, for example, your decision to emulate it would
put you at fault for criminal negligence, whereas a failure simply due
to lack of implementation would be more benign incompetence.  Probably
better for an exception to be thrown or other hard error.

Mark
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to