3v4l.org

run code in 300+ PHP versions simultaneously
<?php date_default_timezone_set('America/Los_Angeles'); $now = new Datetime("2013-04-09 23:45:15","UTC"); $lv = new Datetime("2013-04-09 23:44:21"); $interval = $now->diff($lv,true); print_r($lv); print_r($interval);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/WKKPL
function name:  (null)
number of ops:  24
compiled vars:  !0 = $now, !1 = $lv, !2 = $interval
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'date_default_timezone_set'
          1        SEND_VAL                                                 'America%2FLos_Angeles'
          2        DO_ICALL                                                 
    4     3        NEW                                              $4      'Datetime'
          4        SEND_VAL_EX                                              '2013-04-09+23%3A45%3A15'
          5        SEND_VAL_EX                                              'UTC'
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !0, $4
    5     8        NEW                                              $7      'Datetime'
          9        SEND_VAL_EX                                              '2013-04-09+23%3A44%3A21'
         10        DO_FCALL                                      0          
         11        ASSIGN                                                   !1, $7
    7    12        INIT_METHOD_CALL                                         !0, 'diff'
         13        SEND_VAR_EX                                              !1
         14        SEND_VAL_EX                                              <true>
         15        DO_FCALL                                      0  $10     
         16        ASSIGN                                                   !2, $10
    9    17        INIT_FCALL                                               'print_r'
         18        SEND_VAR                                                 !1
         19        DO_ICALL                                                 
   10    20        INIT_FCALL                                               'print_r'
         21        SEND_VAR                                                 !2
         22        DO_ICALL                                                 
         23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.56 ms | 1395 KiB | 17 Q