3v4l.org

run code in 300+ PHP versions simultaneously
<?php function escape_string($s) { $r = ''; for($i=0;@$s[$i];$i++) { if($s[$i]!='\'') if($s[$i]!='"') if($s[$i]!='\\') if($s[$i]!="\n") if($s[$i]!="\r") if($s[$i]!="\x1a") { $r .= $s[$i]; continue; } $r .= '?'; } return $r; } $password = 'password0x27'; $password = escape_string($password); $query = "select 1 from auth where password='$password'"; echo($query); ?>

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.3.70.0100.01016.50
8.3.60.0070.01116.48
8.3.50.0120.00521.97
8.3.40.0070.00718.64
8.3.30.0070.00718.85
8.3.20.0040.00419.22
8.3.10.0000.00921.68
8.3.00.0080.00019.79
8.2.180.0030.01416.38
8.2.170.0070.00722.96
8.2.160.0100.00320.39
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0000.00718.16
8.2.120.0000.00826.35
8.2.110.0070.00320.81
8.2.100.0040.00819.66
8.2.90.0040.00419.18
8.2.80.0000.00917.97
8.2.70.0050.00317.50
8.2.60.0050.00318.16
8.2.50.0000.00818.10
8.2.40.0040.00422.36
8.2.30.0040.00419.29
8.2.20.0070.00017.63
8.2.10.0080.00018.04
8.2.00.0040.00417.99
8.1.280.0070.00725.92
8.1.270.0120.00323.88
8.1.260.0040.00428.09
8.1.250.0050.00328.09
8.1.240.0000.00920.90
8.1.230.0060.00917.73
8.1.220.0040.00417.76
8.1.210.0120.00018.77
8.1.200.0000.00917.35
8.1.190.0000.00917.35
8.1.180.0030.00618.10
8.1.170.0060.00318.66
8.1.160.0000.00818.91
8.1.150.0080.00018.93
8.1.140.0040.00419.48
8.1.130.0030.00317.61
8.1.120.0060.00317.52
8.1.110.0080.00017.41
8.1.100.0050.00317.45
8.1.90.0040.00417.48
8.1.80.0070.00017.39
8.1.70.0070.00017.39
8.1.60.0030.00517.59
8.1.50.0040.00417.39
8.1.40.0000.00817.56
8.1.30.0040.00417.54
8.1.20.0040.00417.48
8.1.10.0000.00817.45
8.1.00.0080.00417.36
8.0.300.0000.00718.77
8.0.290.0000.00716.63
8.0.280.0000.00718.44
8.0.270.0030.00317.14
8.0.260.0030.00317.16
8.0.250.0000.00716.95
8.0.240.0040.00416.87
8.0.230.0050.00316.96
8.0.220.0070.00016.92
8.0.210.0030.00616.85
8.0.200.0000.00616.91
8.0.190.0040.00716.82
8.0.180.0030.00516.95
8.0.170.0030.00516.87
8.0.160.0070.00016.93
8.0.150.0000.00716.79
8.0.140.0040.00416.85
8.0.130.0000.00513.35
8.0.120.0040.00416.73
8.0.110.0040.00416.68
8.0.100.0050.00316.71
8.0.90.0000.00816.88
8.0.80.0110.00416.91
8.0.70.0000.00816.76
8.0.60.0070.00016.89
8.0.50.0070.00016.88
8.0.30.0090.00917.06
8.0.20.0100.01117.40
8.0.10.0000.00717.06
8.0.00.0070.01416.81
7.4.330.0030.00315.08
7.4.320.0060.00016.63
7.4.300.0030.00316.62
7.4.290.0040.00416.64
7.4.280.0080.00016.39
7.4.270.0030.00416.59
7.4.260.0030.00716.47
7.4.250.0070.00016.57
7.4.240.0030.00316.41
7.4.230.0030.00316.60
7.4.220.0090.00616.53
7.4.210.0090.00816.63
7.4.200.0000.00716.38
7.4.160.0110.01116.60
7.4.150.0110.00617.40
7.4.140.0080.00817.86
7.4.130.0090.00816.46
7.4.120.0080.00816.46
7.4.110.0100.00716.29
7.4.100.0140.00316.61
7.4.90.0080.00816.61
7.4.80.0120.00619.39
7.4.70.0030.01316.62
7.4.60.0090.00616.50
7.4.50.0070.01016.18
7.4.40.0070.01016.50
7.4.30.0170.00016.39
7.4.00.0060.00914.93
7.3.330.0040.00413.29
7.3.320.0060.00013.35
7.3.310.0000.00716.25
7.3.300.0000.00716.24
7.3.290.0040.00416.18
7.3.280.0140.00616.35
7.3.270.0090.01217.40
7.3.260.0130.01216.42
7.3.250.0140.00716.49
7.3.240.0050.01416.64
7.3.230.0100.00716.42
7.3.210.0150.00316.65
7.3.200.0040.01216.35
7.3.190.0130.00916.45
7.3.180.0040.01216.50
7.3.170.0090.00916.48
7.3.160.0140.00716.34
7.2.330.0130.00316.61
7.2.320.0060.01316.45
7.2.310.0070.01316.49
7.2.300.0040.01416.83
7.2.290.0130.00316.82
7.2.60.0040.01116.99
7.2.00.0000.01319.27
7.1.200.0000.01115.94
7.1.100.0000.01218.18
7.1.90.0030.01018.04
7.1.80.0070.00718.36
7.1.70.0060.00517.16
7.1.60.0160.00927.30
7.1.50.0230.00335.01
7.1.40.0160.00934.37
7.1.30.0170.01034.67
7.1.20.0110.01534.45
7.1.10.0060.00916.67
7.1.00.0050.04219.51
7.0.230.0040.00918.04
7.0.220.0070.00718.06
7.0.210.0060.00616.49
7.0.200.0170.01015.72
7.0.190.0060.00616.63
7.0.180.0060.00616.18
7.0.170.0070.00716.34
7.0.160.0100.00316.47
7.0.150.0030.01016.19
7.0.140.0030.01016.22
7.0.130.0030.01016.57
7.0.120.0090.00616.49
7.0.110.0100.00316.18
7.0.100.0060.01116.21
7.0.90.0100.00716.46
7.0.80.0000.01216.27
7.0.70.0060.00616.24
7.0.60.0460.00018.09
7.0.50.0370.00418.36
7.0.40.0380.00718.37
7.0.30.0420.00518.48
7.0.20.0380.00618.38
7.0.10.0410.00418.40
7.0.00.0400.00618.40
5.6.300.0070.05620.81
5.6.290.0100.07520.58
5.6.280.0070.06420.89
5.6.270.0060.05920.99
5.6.260.0100.05420.80
5.6.250.0070.07420.75
5.6.240.0110.05720.96
5.6.230.0130.05020.91
5.6.220.0030.05920.92
5.6.210.0480.02920.77
5.6.200.0420.03221.01
5.6.190.0400.02920.92
5.6.180.0430.02520.88
5.6.170.0400.03121.03
5.6.160.0530.02520.95
5.6.150.0430.03020.99
5.6.140.0380.03320.87
5.6.130.0460.02221.01
5.6.120.0450.03220.98
5.6.110.0400.03520.88
5.6.100.0520.02620.99
5.6.90.0500.02620.98
5.6.80.0400.02820.29
5.6.70.0400.03420.25
5.6.60.0520.03320.36
5.6.50.0430.02520.34
5.6.40.0420.03020.26
5.6.30.0460.02920.35
5.6.20.0400.02720.42
5.6.10.0420.02820.33
5.6.00.0400.02620.23
5.5.380.0000.06017.57
5.5.370.0100.05217.41
5.5.360.0070.05617.45
5.5.350.0400.02718.99
5.5.340.0380.02519.45
5.5.330.0410.02619.49
5.5.320.0380.02919.53
5.5.310.0500.02819.37
5.5.300.0420.03019.35
5.5.290.0430.02919.40
5.5.280.0450.03919.45
5.5.270.0480.03219.44
5.5.260.0510.02419.32
5.5.250.0420.03119.26
5.5.240.0470.02618.65
5.5.230.0450.03318.84
5.5.220.0480.03818.71
5.5.210.0550.02418.70
5.5.200.0430.02518.82
5.5.190.0380.02918.89
5.5.180.0420.02818.72
5.5.160.0380.02618.87
5.5.150.0390.02618.86
5.5.140.0380.03018.82
5.5.130.0430.02118.55
5.5.120.0400.02418.63
5.5.110.0460.02418.86
5.5.100.0370.03118.54
5.5.90.0450.02418.74
5.5.80.0400.03318.77
5.5.70.0420.03518.73
5.5.60.0400.02818.48
5.5.50.0400.02718.60
5.5.40.0500.02818.73
5.5.30.0430.02518.74
5.5.20.0500.02818.59
5.5.10.0420.03418.54
5.5.00.0380.03418.68

preferences:
53.3 ms | 401 KiB | 5 Q