Skip to content

AOT: date('T'/'e'/'O'/'P'/'r') SIGSEGV — timezone tokens crash free date() (ext/date/php_date.c) #33943

Description

@PurHur

Category

bug · AOT crash · free date() timezone tokens

Problem

On master @ 1433ae9, thin AOT segfaults (rc=139) for free-function date() when the format includes timezone tokens. Zend and civil-only formats are fine. Distinct from DateTime::format named-zone crash (#33939).

Repro Zend 8.2+ AOT
echo date('T', strtotime('2024-01-15 12:00:00')); UTC SIGSEGV (139)
date('e'/'O'/'P'/'r', …) zone / offset / RFC2822 SIGSEGV (139)
date('c', …) / date('Y-m-d H:i:s', …) match match

./script/aot-smoke.sh is 8/8 on this tree — measuring the feature, not the linker.

php-src reference

PHP implementation target

  • ext/standard/JitDate.php (and peers used by free date()) — civil/timezone token bake or safe NestedJIT path; no new runtime/*.c

Repro

./script/docker-exec.sh -- bash -lc 'cat >/tmp/date_t.php <<\"PHP\"
<?php
echo date(\"T\", strtotime(\"2024-01-15 12:00:00\")), \"\n\";
PHP
php /tmp/date_t.php
php bin/compile.php -o /tmp/date_t.bin /tmp/date_t.php && /tmp/date_t.bin; echo rc=$?'

Done when

  • AOT date('T'/'e'/'O'/'P'/'r', $ts) matches Zend (no SIGSEGV)
  • ./script/aot-smoke.sh stays 8/8
  • Targeted phpunit / AotTest guard

Activity

  1. added
    bugSomething isn't working
    phase-3:aotPhase 3 – AOT deployment
    implementation-readySpec complete: repro, php-src ref, done-when — safe for workers to claim
    on Aug 22, 2026
  2. PurHur commented on Aug 22, 2026

    @PurHur
    OwnerAuthor

    claim: worker-lane-c — starting this run (lane overflow: #32122/#31968 children closed; #33939/#33936/#33937 claimed <48h). AOT date('T'/'e'/'O'/'P'/'r') SIGSEGV — free date() timezone tokens. aot-smoke 8/8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:compilerCompiler / CFG / JITbugSomething isn't workingimplementation-readySpec complete: repro, php-src ref, done-when — safe for workers to claimphase-3:aotPhase 3 – AOT deployment

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions