Created
June 8, 2016 02:11
-
-
Save rednaxelafx/2d30bbbf3e97327f26de9cdde7b68cc6 to your computer and use it in GitHub Desktop.
HotSpot C1 doesn't compile this "monitorenter with Phi input", fails with "invalid parsing"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.class public Demo | |
.super java/lang/Object | |
.field public static dummy I | |
.method public static foo(Ljava/lang/Object;Ljava/lang/Object;Z)V | |
.limit stack 2 | |
.limit locals 3 | |
iload_2 | |
ifeq Label_lock_other | |
aload_0 | |
goto Label_do_lock | |
Label_lock_other: | |
aload_1 | |
Label_do_lock: | |
monitorenter | |
getstatic Demo/dummy I | |
iconst_1 | |
iadd | |
putstatic Demo/dummy I | |
iload_2 | |
ifeq Label_unlock_other | |
aload_0 | |
goto Label_do_unlock | |
Label_unlock_other: | |
aload_1 | |
Label_do_unlock: | |
monitorexit | |
return | |
.end method |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To compile, download Jasmin and run
java -jar jasmin.jar Demo.j
.