• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2015 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 class Main {
main(String[] args)18   public static void main(String[] args) {
19     System.out.println(test(false, 5));
20   }
21 
test(boolean b, int i1)22   public static int test(boolean b, int i1) {
23     int j=4;
24     int s1=26294;
25 
26     for (int i = 25; i > 1; --i) {
27       if (b) continue;
28       // javac/dx will remove the catch information, but
29       // keep the catch code around. The optimizing compiler
30       // used to crash in the presence of dead blocks like the
31       // code in catch.
32       try {
33         i1 = i1 * 26295 + (s1 / 26295);
34       } catch (Throwable exc2) {
35         for (j = 1; j < 39; ++j) {
36           j++;
37         }
38       }
39     }
40     return i1;
41   }
42 }
43