summaryrefslogtreecommitdiff
path: root/Zend/zend_operators.h
Commit message (Collapse)AuthorAgeFilesLines
* year++Xinchen Hui2018-01-021-1/+1
|
* Update copyright headers to 2017Sammy Kaye Powers2017-01-041-1/+1
|
* when needle is short, Sunday algorithm is slower than glibc memchr()TAKEKOSHI Akishige2016-09-181-1/+1
|
* Merge branch 'PHP-7.0' into PHP-7.1Nikita Popov2016-09-161-2/+8
|\
| * Disable add/sub asm for gcc 4.9 pic/pie buildsMichael Orlitzky2016-09-161-2/+8
| |
* | Use "fast" assembler functions in "slow" ones.Dmitry Stogov2016-06-011-8/+8
| | | | | | | | Mark assembler functions that changes memory.
* | Remove IS_VAR_RET_REF flagNikita Popov2016-04-151-0/+12
| | | | | | | | | | | | | | Instead decide whether a function returned by reference or by value by checking whether the return value has REFERENCE type. This means that functions returning by reference must always return a reference and functions returning by value must not return a reference.
* | Warn about invalid strings in arithmeticAndrea Faulds2016-03-301-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Squashed commit of the following: commit e05d3b67325d4521418483ed924ac9211a188919 Author: Andrea Faulds <ajf@ajf.me> Date: Wed Mar 30 01:43:35 2016 +0100 UPGRADING and NEWS commit 6caf1d4585207d1b02fb06a216cd7da1a1f5e12d Author: Andrea Faulds <ajf@ajf.me> Date: Sun Mar 20 21:18:33 2016 +0000 Fixes commit 6dadb1b0efe5e2ed071e95a55c806519e61377ac Author: Andrea Faulds <ajf@ajf.me> Date: Sun Feb 14 02:15:01 2016 +0000 Add test for numeric string errors in assignment commit bd5f04e8dd576f92a48d25546f4f9a0f57f374de Author: Andrea Faulds <ajf@ajf.me> Date: Sat Feb 13 23:53:05 2016 +0000 Add test for numeric string errors commit c72e92f16d512bcae30cc9639c89bcb08d971742 Author: Andrea Faulds <ajf@ajf.me> Date: Tue Jan 26 23:28:33 2016 +0000 Add test for scientific notation in integer operations commit d94c08852d405b3a7ef6c84d24bf7915c890ce78 Author: Andrea Faulds <ajf@ajf.me> Date: Sun Feb 14 01:25:57 2016 +0000 Disable optimiser evaluation for numeric string errors commit 30ee954ed13d933e766c68605d683c8ebae3d8ee Author: Andrea Faulds <ajf@ajf.me> Date: Sun Feb 14 01:46:25 2016 +0000 fixup commit a6403b79e054c95e2b7345d787f3092b261eed27 Author: Andrea Faulds <ajf@ajf.me> Date: Sat Feb 13 22:00:27 2016 +0000 Do not convert error-causing numeric strings ahead-of-time commit f9dc35401471ef3035954cb6f171826769297548 Author: Andrea Faulds <ajf@ajf.me> Date: Sat Feb 13 19:15:38 2016 +0000 Disable compile-time evaluation for numeric string errors commit e05b0cc8496ea082c6db27efd8b8277ef1f785b5 Author: Andrea Faulds <ajf@ajf.me> Date: Fri Feb 5 11:42:26 2016 +0000 Make _zval_get_long_func_noisy function for inlining commit 84d66321a57e579759109650c8bb7e3d5002854a Author: Andrea Faulds <ajf@ajf.me> Date: Tue Jan 26 23:10:00 2016 +0000 Update tests commit 5ac4a0cc4bff282e3a15eaa8ab44b67391881a6d Author: Andrea Faulds <ajf@ajf.me> Date: Tue Jan 26 22:08:19 2016 +0000 Use is_numeric_string_ex for zval_get_long etc. commit c21f08848533723331012a62a153de3577731d6a Author: Andrea Faulds <ajf@ajf.me> Date: Thu Jan 7 21:13:04 2016 +0000 Update tests commit 63e214cf8160420bfc51c6a2b4ae32f09ad8e8af Author: Andrea Faulds <ajf@ajf.me> Date: Wed Jan 6 00:28:01 2016 +0000 Warn on non-/bad numeric strings in arithmetic
* | Remove use of register keyword in headersNikita Popov2016-02-041-1/+1
|/ | | | | | | Headers must be C++ compatible -- this throws warnings. The register keyword is not used for optimization, at least not in optimized builds.
* bump year which is missed in rev 49493a2Xinchen Hui2016-01-021-1/+1
|
* additional catch to bug #70863Anatol Belski2015-11-101-1/+1
|
* Revert "Merge branch 'array_keys_strict_refs' of ↵Dmitry Stogov2015-10-061-68/+6
| | | | | | https://github.com/tony2001/php-src" This reverts commit a6be0f3fd6cdd59ac00ecd76630c6c04fee03417.
* Merge branch 'array_keys_strict_refs' of https://github.com/tony2001/php-srcBob Weinand2015-10-051-6/+68
|
* Simplfy zend_is_trueXinchen Hui2015-09-101-17/+16
|
* Change array sorting implementation to avoid two level callbacks system.Dmitry Stogov2015-09-101-9/+9
| | | | Simplify zval comparion API.
* Add myself into list of authors of the most refactored files.Dmitry Stogov2015-08-311-0/+1
|
* Fixed bug #69896 'asm' operand has impossible constraintsAnatol Belski2015-08-021-2/+2
| | | | | Given it's an issue with 32-bit gcc-4.8, asm is disabled for the breaking parts.
* Improve performance of PowerPC64 fast_long_add_functionAnton Blanchard2015-07-291-60/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Detecting overflow with the XER is slow, partially because we have to clear it before use. PHP already has a fast way of detecting overflow in its fallback c implementation. Overflow only occurs if the signs of the two operands are the same and the sign of the result is different. Furthermore, leaving it in c allows gcc to schedule the instructions better. This is 9% faster on a POWER8 running a simple testcase: <?php function testcase($count = 100000000) { $x = 1; for ($i = 0; $i < $count; $i++) { $x = $x + 1; $x = $x + 1; $x = $x + 1; $x = $x + 1; $x = $x + 1; } } testcase(); ?>
* Improve performance of PowerPC64 fast_long_increment_functionAnton Blanchard2015-07-281-54/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Detecting overflow with the XER is slow, partially because we have to clear it before use. gcc does a better job of detecting overflow of an increment or decrement than we can with inline assembly. It knows that an increment will only overflow if it is one less than the overflow value. This means we end up with a simple compare/branch. Furthermore, leaving it in c allows gcc to schedule the instructions better. This is 6% faster on a POWER8 running a simple testcase: <?php function testcase($count = 100000000) { $x = 1; for ($i = 0; $i < $count; $i++) { $x++; $x++; $x++; $x++; $x++; } } testcase(); ?>
* Fixed signed/unsigned warnings in wddxNikita Popov2015-07-171-3/+3
| | | | Also added extra const annotation to zend_memnstr.
* Cleanup (avoid reallocatios and side effects in php_strip_tags)Dmitry Stogov2015-07-011-0/+1
|
* Fixed crash in Zend/tests/bug69891.phpt on x86 (32-bit).Dmitry Stogov2015-06-221-1/+2
| | | | | compare_function() now has to be compatible with binary_op_type (use fastcall convention). Introduced new zval_compare_function() to be used as zval comparison callback instead of compare_function().
* Make convert_to_* safe with rc>1Nikita Popov2015-06-111-3/+0
| | | | | | | | | | | | | This only involves switching zval_dtor to zval_ptr_dtor for arrays and making the convert_to_object for arrays a bit more generic. All the other changes outside zend_operators.c just make use of this new ability (use COPY instead of DUP). What's still missing: Proper references handling. I've seen many convert_to* calls that will break when a reference is used. Also fixes bug #69788.
* Optimized === and !== with NULL, FALSE, TRUE.Dmitry Stogov2015-05-151-0/+4
|
* Improve fast_is_[not_]identical() functions to teturn value instead of ↵Dmitry Stogov2015-04-291-9/+8
| | | | | | takeing additional arguments. Pair INSTANCEOF with the following JMPZ/JMPNZ.
* Fixed weird operators behavior. Division by zero now emits warning and ↵Dmitry Stogov2015-04-061-46/+0
| | | | returns +/-INF, modulo by zero and intdid() throws an exception, shifts by negative offset throw exceptions. Compile-time evaluation of division by zero is disabled.
* Drop old VC support in Zend Engine, this also kills the remaining MessageBox ↵Kalle Sommer Nielsen2015-03-291-4/+2
| | | | fix for Windows 9x that Anatol changed a while back
* Removed unused functionsDmitry Stogov2015-03-241-2/+0
|
* Embed "fast" operator functions (add, sub, increment, etc) into executor ↵Dmitry Stogov2015-03-171-475/+282
| | | | with additional optimizations
* Use fastcall calling convention for most critical ZE subsystems.Dmitry Stogov2015-03-131-72/+72
|
* Fixed C++ supportDmitry Stogov2015-02-271-3/+0
|
* Don't inline slow pathDmitry Stogov2015-02-261-29/+3
|
* bump yearXinchen Hui2015-01-151-1/+1
|
* Faster strrpos implementationXinchen Hui2015-01-121-4/+41
|
* Faster zend_memnstr for long textXinchen Hui2015-01-121-11/+17
|
* trailing whitespace removalStanislav Malyshev2015-01-101-8/+8
|
* Introduce specialized functions to compare with integer and string, to ↵Dmitry Stogov2014-12-271-0/+30
| | | | eliminate repeatable checks on each loop iteration in in_array() function.
* Added new API function 'zend_string* zend_string_tolower(zend_string*)'.Dmitry Stogov2014-12-241-0/+1
| | | | It simplifies code and avoids unnecessary allocation and copying if string is already in lower case.
* Micro optimaztion (yeah, I know compiler supposed to do that)Xinchen Hui2014-12-221-3/+3
|
* Micro optimizationXinchen Hui2014-12-211-3/+3
|
* Micro optimizationsXinchen Hui2014-12-211-10/+8
|
* first shot remove TSRMLS_* thingsAnatol Belski2014-12-131-83/+83
|
* Merge branch 'zppFailOnOverflow'Andrea Faulds2014-12-131-3/+9
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * zppFailOnOverflow: Fix MySQLi tests Fixed gd test Refactor ZEND_LONG_MAX/MIN checks into ZEND_DOUBLE_FITS_LONG() Fixed copy-and-paste error Fix more 32-bit tests Skip buncha tests on 32-bit skip simplexml skip posix 32-bit skip tests on 32-bit Fixes simplexml test Fixes posix tests Fixes iconv tests Marked tests as 32-bit Fixed more 32-bit tests Fixed some 32-bit tests Mark said ext/date tests as 32-bit only Fixed ext/date tests broken by zpp error on overflow Fixed broken tests Make zpp fail if NaN passed for int, or out-of-range float for non-capping int Conflicts: ext/date/tests/getdate_variation7.phpt ext/date/tests/localtime_variation3.phpt
| * Refactor ZEND_LONG_MAX/MIN checks into ZEND_DOUBLE_FITS_LONG()Andrea Faulds2014-11-291-3/+9
| |
* | PowerPC64 support for add and sub with overflow checkGustavo Frederico Temple Pedrosa2014-12-121-0/+60
| | | | | | | | | | | | | | | | This adds fast architecture-specific implementations of the following functions for the ppc64: * fast_add_function * fast_sub_function
* | PowerPC64 support for operators with overflow checkGustavo Frederico Temple Pedrosa2014-12-121-0/+54
| | | | | | | | | | | | | | | | This adds fast architecture-specific implementations of the following functions for the ppc64: * fast_increment_function * fast_decrement_function
* | Moved zend_is_true() from zend_execute.h/zend_execute_API.c into ↵Dmitry Stogov2014-12-111-1/+55
|/ | | | | | | zend_operators.h/zend_operators.c. Splited the most expensive part of inline i_zend_is_true() into a separate zend_object_is_true(). Replaced zendi_convert_to_long() with cals to zend_is_true().
* Moved proxy object support in ASSIGN_ADD (and family) from VM to slow paths ↵Dmitry Stogov2014-10-211-14/+35
| | | | of corresponding operators
* And this one...Xinchen Hui2014-10-031-17/+18
|
* Fixed C++ incompatibilityDmitry Stogov2014-09-241-1/+2
|