I'm a bit confused now, because after adding the JIT setting to the PHP config, when I disable the opcache_get_status()['jit']
function, I get the following output:
But after checking ini_get("opcache.jit")
I have the following result:
Which in turn, based on this answer, means that JIT is active:
which is an integer (returned as string) where the last digit states the status of the JIT: ... 5 - optimized JIT based on static type inference and inner procedure analyses
I still think that my JIT is not active, although maybe there is an expert who will explain that this is not the case)) since the function itself is called, maybe XDebug is involved here because it is active for me, but these are more guesswork.
Dockerfile:
FROM php:8.1-fpm-alpine
ENV XDEBUG_VERSION 3.1.5
RUN apk add --update --no-cache icu-dev icu-libs icu-data-full git bash autoconf g++ make zlib-dev libzip-dev libpng-dev libwebp-dev freetype-dev libjpeg-turbo-dev \
&& git clone --branch $XDEBUG_VERSION --depth 1 https://github.com/xdebug/xdebug.git /usr/src/php/ext/xdebug \
&& docker-php-ext-configure xdebug --enable-xdebug-dev \
&& docker-php-ext-configure gd --enable-gd --with-freetype --with-jpeg --with-webp \
&& docker-php-ext-install intl pdo_mysql gd zip xdebug \
&& apk del git
RUN mv $PHP_INI_DIR/php.ini-development $PHP_INI_DIR/php.ini
# fix work iconv library with alphine
RUN apk add --no-cache --repository http://dl-cdn.alpinelinux.org/alpine/edge/community/ --allow-untrusted gnu-libiconv
ENV LD_PRELOAD /usr/lib/preloadable_libiconv.so php
COPY ./common/php/conf.d /usr/local/etc/php/conf.d
COPY ./development/php/conf.d /usr/local/etc/php/conf.d
COPY ./development/php-fpm/conf.d /usr/local/etc/php/conf.d
COPY ./development/php-fpm/entrypoint.sh /usr/local/bin/docker-php-entrypoint
RUN chmod +x /usr/local/bin/docker-php-entrypoint
WORKDIR /app
opcache.ini
zend_extension=opcache.so
opcache.enable=1
opcache.enable_cli=1
opcache.jit_buffer_size=128M
opcache.jit=1255