Hi,

> @internals: Anyway, since nobody of the core devs seems to be interested
> in this topic, is there any objection to me committing this patch to HEAD?

Since I received no answer, I assumed that nobody would object and tried
to commit my patch to HEAD. Problem is that I don't have ZE2 karma and
since my patch touches zend_strtod.[ch] too, my commit failed.

I isolated the ZE2 parts of the patch so they can be applied separately
so that somebody with ZE2 karma can commit it:

http://www.christian-seiler.de/temp/php/2008-08-23-rounding/ze2.patch

For an explanation for everyone that hasn't read my rounding RFC, the
ZE2 part of the patch does the following:

- Define some macros in zend_strtod.h that set the FPU control registers
  to always use double precision (and not double extended precision)
  when performing calculations.
- Add necessary configure checks for Unix based systems to see if the
  required mechanism is present.
- Define the correct constant in the Windows build system (MSVC always
  defines _controlfp_s)
- Modify zend_strtod() that it uses these macros.

The macros are defined in zend_strtod.h because I also need them in
ext/standard/math.c.

The reason for the need to fix zend_strtod() is that it currently
behaves like strtod() on most systems but like (double)strtold() on x86
UNIX with GCC (see my RFC for details why that's not the same).

For the record, the complete patch I tried to commit (I'll commit the
rest myself):
http://www.christian-seiler.de/temp/php/2008-08-23-rounding/rounding-head.patch

I'd really appreciate it if someone could commit the ZE2 parts. Thanks!

Regards,
Christian

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to