php / php/php-src

opcache.jit won't write to opcache.file_cache

Open
#17,770 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Bug Category: JIT Extension: opcache Status: Verified
Dominant language
C
Stars
40.4k
Forks
8.1k
Avg merge
2d 13h
Merged PRs (30d)
96

Description

Description

The following code:

<?php

function foo() {
    echo "hello";
}

foo();
php -d opcache.enable_cli=1 -d opcache.jit=1255 -d opcache.file_cache=/tmp/opcache test.php
php -d opcache.enable_cli=1 -d opcache.jit=disable -d opcache.file_cache=/tmp/opcache test.php

When jit is enabled, nothing is written to /tmp/opcache
When jit is disabled, /tmp/opcache is populated

Why?

PHP Version

8.4

Operating System

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the two PHP CLI commands and compare the contents of /tmp/opcache with JIT enabled and disabled. Trace the opcache.file_cache and opcache.jit handling to determine why the cache is not written with JIT enabled; done when the behavior is explained and the reported discrepancy is resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.