[Python-Dev] pyc files, constant folding and borderline portability issues (original) (raw)
Mark Dickinson dickinsm at gmail.com
Mon Apr 6 21:30:57 CEST 2009
- Previous message: [Python-Dev] deprecating BaseException.message
- Next message: [Python-Dev] pyc files, constant folding and borderline portability issues
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
[Antoine]
- Issue #5593: code like 1e16+2.9999 is optimized away and its result stored as a constant (again), but the result can vary slightly depending on the internal FPU precision. [Guido] I would just not bother constant folding involving FP, or only if the values involved have an exact representation in IEEE binary FP format.
+1 for removing constant folding for floats (besides conversion of -). There are just too many things to worry about: FPU rounding mode and precision, floating-point signals and flags, effect of compiler flags, and the potential benefit seems small.
Mark
- Previous message: [Python-Dev] deprecating BaseException.message
- Next message: [Python-Dev] pyc files, constant folding and borderline portability issues
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]