JVM optimize unneeded temporary vals

This commit is contained in:
Dmitry Petrov
2021-08-23 16:59:17 +03:00
committed by TeamCityServer
parent d8f6d82411
commit f4a1e27124
10 changed files with 122 additions and 47 deletions
@@ -17,8 +17,17 @@ suspend fun ApplicationCall.test(authenticationService: AuthenticationService) {
respond(authenticationService.execute(receiveJSON()))
}
// JVM_TEMPLATES
// $i$f$respond x1, $i$f$receiveJSON x2: before and after suspension point
// 3 ISTORE 5
// 0 ILOAD 5
// 2 \$i\$f\$receiveJSON I .* 5
// 1 \$i\$f\$respond I .* 5
// JVM_IR_TEMPLATES
// 5 ISTORE 3
// 1 ISTORE 2
// 0 ILOAD 3
// 0 ILOAD 2
// 1 \$i\$f\$receiveJSON I .* 2
// 3 \$i\$f\$respond I .* 3