3v4l.org

run code in 300+ PHP versions simultaneously
<?php function is_wp_version_compatible( $required ) { $wp_version = '6.4.1'; // Strip off any -alpha, -RC, -beta, -src suffixes. list( $version ) = explode( '-', $wp_version ); if ( is_string( $required ) && substr_count( $required, '.' ) > 1 && str_ends_with( $required, '.0' ) ) { error_log(__FUNCTION__ . '(): ' . /* translators: s: version string sent to function */ sprintf( '`%s` Not a valid WordPress version string.', $required ) ); $required = rtrim( $required, '.0' ); } return empty( $required ) || version_compare( $version, $required, '>=' ); } echo is_wp_version_compatible('6.4'); echo is_wp_version_compatible('3.0'); echo is_wp_version_compatible('3.0.0'); echo is_wp_version_compatible('6.4.1');

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.4.20.0130.00620.86
8.4.10.0000.00919.85
8.3.150.0070.00316.78
8.3.140.0040.00416.84
8.3.130.0040.00418.38
8.3.120.0030.00619.12
8.3.110.0130.00620.94
8.3.100.0070.00316.90
8.3.90.0080.00026.77
8.3.80.0040.00419.36
8.3.70.0070.01116.75
8.3.60.0150.00618.28
8.3.50.0150.00616.71
8.3.40.0100.01020.27
8.3.30.0040.01118.50
8.3.20.0040.00424.18
8.3.10.0000.00824.66
8.3.00.0050.00426.25
8.2.260.0110.00817.31
8.2.250.0050.00218.59
8.2.240.0060.00319.12
8.2.230.0040.00422.58
8.2.220.0080.00024.06
8.2.210.0140.00326.77
8.2.200.0030.00618.88
8.2.190.0110.00716.58
8.2.180.0070.01416.50
8.2.170.0090.00918.81
8.2.160.0140.00322.96
8.2.150.0070.00025.66
8.2.140.0050.00324.66
8.2.130.0060.00326.25
8.2.120.0080.00223.65
8.2.110.0080.00724.24
8.2.100.0100.00723.64
8.2.90.0180.00422.56
8.2.80.0100.00822.47
8.2.70.0130.00522.56
8.2.60.0080.00522.62
8.2.50.0120.00522.97
8.2.40.0120.00622.61
8.2.30.0120.00522.53
8.2.20.0090.00622.69
8.2.10.0150.00622.69
8.2.00.0160.00522.64
8.1.310.0070.00716.83
8.1.300.0120.00616.56
8.1.290.0090.00030.84
8.1.280.0120.00925.92
8.1.270.0040.00422.19
8.1.260.0050.00426.35
8.1.250.0110.00026.35
8.1.240.0120.00722.52
8.1.230.0140.01022.55
8.1.220.0170.00122.52
8.1.210.0080.00423.14
8.1.200.0100.00722.39
8.1.190.0070.00522.40
8.1.180.0090.00422.41
8.1.170.0040.00822.46
8.1.160.0090.00722.52
8.1.150.0080.00823.48
8.1.140.0080.00922.41
8.1.130.0090.00922.36
8.1.120.0110.00322.46
8.1.110.0050.00723.05
8.1.100.0120.00322.39
8.1.90.0100.00222.44
8.1.80.0090.00822.31
8.1.70.0080.00322.50
8.1.60.0070.00622.41
8.1.50.0160.00422.32
8.1.40.0080.00322.48
8.1.30.0090.00222.66
8.1.20.0110.00222.58
8.1.10.0070.00422.61
8.1.00.0060.00522.57
8.0.300.0090.00322.17
8.0.290.0100.00222.06
8.0.280.0110.00022.16
8.0.270.0030.00922.09
8.0.260.0070.00222.38
8.0.250.0060.00622.21
8.0.240.0080.00322.10
8.0.230.0070.00422.39
8.0.220.0050.00822.15
8.0.210.0110.00222.14
8.0.200.0110.00222.04
8.0.190.0090.00522.32
8.0.180.0080.00422.11
8.0.170.0080.00522.16
8.0.160.0120.00222.15
8.0.150.0130.00822.11
8.0.140.0160.00522.13
8.0.130.0120.00522.27
8.0.120.0100.00522.18
8.0.110.0050.00722.17
8.0.100.0160.00522.10
8.0.90.0070.00622.15
8.0.80.0110.00222.13
8.0.70.0130.00222.11
8.0.60.0050.00722.34
8.0.50.0200.00322.08
8.0.30.0130.00222.40
8.0.20.0030.01022.19
8.0.10.0110.00622.16

preferences:
37.89 ms | 403 KiB | 5 Q