Skip to content

Web: JIT/AOT mode for bin/serve.php (compile per script on first request) #207

@PurHur

Description

@PurHur

Problem

bin/serve.php always uses VM (Runtimelib/VM.php). Dev servers for Zend PHP often use OPcache; we have JIT (#153 cache) but no serve integration.

Goal

phpc serve --jit 127.0.0.1:8080 examples/001-SimpleWeb

Compiles .php scripts with bin/jit.php on first hit, caches (#153), falls back to VM on compile error.

Tasks

Acceptance criteria

Second request to same script is faster than first; output matches VM.

Dependencies

Files

  • bin/serve.php, bin/phpc.php, lib/Runtime.php

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions