summaryrefslogtreecommitdiff
path: root/Zend/zend_cpuinfo.c
Commit message (Collapse)AuthorAgeFilesLines
* Replace zend_bool uses with boolNikita Popov2021-01-151-2/+2
| | | | | | | We're starting to see a mix between uses of zend_bool and bool. Replace all usages with the standard bool type everywhere. Of course, zend_bool is retained as an alias.
* Merge branch 'PHP-7.4' into PHP-8.0Nikita Popov2020-11-271-4/+10
|\ | | | | | | | | * PHP-7.4: Fix build for non-x86
| * Fix build for non-x86Nikita Popov2020-11-271-4/+10
| |
* | Merge branch 'PHP-7.4' into PHP-8.0Nikita Popov2020-11-271-0/+37
|\ \ | |/ | | | | | | * PHP-7.4: Fix AVX detection
| * Fix AVX detectionNikita Popov2020-11-271-0/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Our CPU detection code currently only checks whether hardware support for AVX exists. However, we also need to check for operating system support for XSAVE, as well as whether XCR0 has the SSE and AVX bits set. If this is not the case, unset the AVX and AVX2 bits in the cpuinfo structure. Hopefully this resolves our issues with CPU support detection. Closes GH-6460.
* | Assert that cpuinfo is initialized before useNikita Popov2020-11-271-0/+1
|/ | | | And fix some incorrect indentation.
* Update and fix remaining year ranges (2019)Peter Kokot2019-02-081-1/+1
| | | | | | This patch follows previous license year ranges updates. With new approach source code files now have simplified headers with license information without year ranges.
* Remove local variablesPeter Kokot2019-02-031-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch removes the so called local variables defined per file basis for certain editors to properly show tab width, and similar settings. These are mainly used by Vim and Emacs editors yet with recent changes the once working definitions don't work anymore in Vim without custom plugins or additional configuration. Neither are these settings synced across the PHP code base. A simpler and better approach is EditorConfig and fixing code using some code style fixing tools in the future instead. This patch also removes the so called modelines for Vim. Modelines allow Vim editor specifically to set some editor configuration such as syntax highlighting, indentation style and tab width to be set in the first line or the last 5 lines per file basis. Since the php test files have syntax highlighting already set in most editors properly and EditorConfig takes care of the indentation settings, this patch removes these as well for the Vim 6.0 and newer versions. With the removal of local variables for certain editors such as Emacs and Vim, the footer is also probably not needed anymore when creating extensions using ext_skel.php script. Additionally, Vim modelines for setting php syntax and some editor settings has been removed from some *.phpt files. All these are mostly not relevant for phpt files neither work properly in the middle of the file.
* Possible fix for bug #77357Nikita Popov2019-01-031-3/+11
| | | | | | Don't invoke CPUID with feature levels above the supported maximum. In this case CPUID will return the highest supported basic information leaf, which will have unrelated bits in the relevant positions.
* Fix __zend_cpuid on i386 PIC without __cpuid_countRyan Schmidt2018-12-081-0/+12
| | | | Closes https://bugs.php.net/bug.php?id=76654
* Fix #76825: Undefined symbols ___cpuid_countChristoph M. Becker2018-11-051-1/+1
| | | | | | Apparently, the presence of `cpuid.h` is not necessarily sufficient to guarantee the availability of `__cpuid_count()`. We therefore test for the latter explicitly.
* Fixed bug #76825 (Undefined symbols ___cpuid_count)Xinchen Hui2018-09-041-1/+11
|
* Fix clang compilationAnatol Belski2018-08-011-1/+1
| | | | | | | By usage of -fmodules, all the intrinsic items are loaded automatically. The headers included come however from Visual Studio, thus bringing some conflicting declarations. On the other hand, -fmodules is needed to mitigate linking issues with clang in VS compatibility mode.
* Use __cpuid_count() from cpuid.h instead of custom assemblyOndřej Surý2018-07-171-5/+2
|
* Fixed cpuinfo in LLVM GCC & Added AVX2 detectionXinchen Hui2018-02-101-11/+18
| | | | | Seems it only defines __builtin_cpu_supports but no __builtin_cpu_init (Apple LLVM version 9.0.0 (clang-900.0.38))
* Fixed cpu feature check in reslover functionsXinchen Hui2018-02-101-5/+0
|
* The cpu setup is still needed when ifunc is supportedAnatol Belski2018-01-161-0/+4
|
* Separate the cpuinfo initialization part and call it at startupAnatol Belski2018-01-161-3/+7
|
* Fix __cpuidex usageAnatol Belski2018-01-161-1/+8
|
* Added ZEND_API zend_cpu_supportsXinchen Hui2018-01-161-0/+73