* src/vm/jit/arm/codegen.c: removed unused ICMD_GETSTATIC branch
[cacao.git] / tests / regression / jasmin / test_verify_fail_jsr_handler_in_sub.j
1 .class public test_verify_fail_jsr_handler_in_sub
2 .super java/lang/Object
3
4 ; ======================================================================
5
6 .method public <init>()V
7    aload_0
8    invokenonvirtual java/lang/Object/<init>()V
9    return
10 .end method
11
12 ; ======================================================================
13
14 .method public static checkI(I)V
15         .limit locals 1
16         .limit stack 10
17         getstatic java/lang/System/out Ljava/io/PrintStream;
18         iload_0
19         invokevirtual java/io/PrintStream/println(I)V
20         return
21 .end method
22
23 ; ======================================================================
24
25 .method public static main([Ljava/lang/String;)V
26         .limit stack 2
27         .limit locals 3
28
29         .catch java/lang/Exception from test_start to test_end using handler
30
31         ldc 35
32         istore 1
33
34         aload 0
35         ifnull force_basic_block_boundary
36
37         ; --------------------------------------------------
38
39         jsr sbr_1
40         iload 1
41         invokestatic test_verify_fail_jsr_handler_in_sub/checkI(I)V
42
43         ; --------------------------------------------------
44
45 force_basic_block_boundary:
46
47         return
48         
49 ; ERROR: VerifyError
50 ; This fails, because the "astore 2" is _after_ the exception range boundary
51
52 sbr_1:
53 test_start:
54         astore 2
55         ldc 2
56         ldc 0
57         idiv
58         pop
59         ldc 666
60         invokestatic test_verify_fail_jsr_handler_in_sub/checkI(I)V
61         return
62 test_end:
63
64 handler:
65         pop
66         ldc 48
67         invokestatic test_verify_fail_jsr_handler_in_sub/checkI(I)V
68         ret 2
69
70 .end method