Req #78743 [NEW]: Provide a configure flag to disable SIMD optimizations

From: Date: Wed, 23 Oct 2019 15:44:38 +0000
Subject: Req #78743 [NEW]: Provide a configure flag to disable SIMD optimizations
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-223417@lists.php.net to get a copy of this message
From: php-bugs-2019 at ryandesign dot com Operating system: PHP version: 7.3.10 Package: *Compile Issues Bug Type: Feature/Change Request Bug description:Provide a configure flag to disable SIMD optimizations Description: ------------ Hi, I'm the maintainer of php in MacPorts. When I configure php73 on my Mac, the output includes these lines: checking for ssse3 instructions supports... yes checking for sse4.2 instructions supports... yes checking for avx instructions supports... yes checking for avx2 instructions supports... yes checking whether __SSE4_2__ is defined... no If I understand correctly, it's checking which SIMD instruction sets are available on the current CPU, and builds a binary that uses those instructions. If that's correct, then moving that binary to a computer with a different CPU with lesser SIMD capabilities would not work, and would probably crash. This is a problem for anyone who wants to distribute binaries of php for others to use, such as MacPorts and other package management systems. I think this may be why some of our users have reported crashes with php73. Therefore I would like to disable SIMD optimizations, but I couldn't find a configure flag to do that. If there isn't one, could one be added? Or is there another way for me to indicate this at build time? It would be useful to be able to override the detection of each instruction set individually. (For example, for MacPorts, I know that every Intel Mac Apple ever shipped supported SSE3, so I would enable that and disable the rest. Or I might vary it based on deployment macOS version, since newer macOS versions often require newer computers anyway.) -- Edit bug report at https://bugs.php.net/bug.php?id=78743&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=78743&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=78743&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=78743&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=78743&r=needscript Try newer version: https://bugs.php.net/fix.php?id=78743&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=78743&r=support Expected behavior: https://bugs.php.net/fix.php?id=78743&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=78743&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=78743&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=78743&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=78743&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=78743&r=dst IIS Stability: https://bugs.php.net/fix.php?id=78743&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=78743&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=78743&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=78743&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=78743&r=mysqlcfg

« previous php.bugs (#223417) next »