aboutsummaryrefslogtreecommitdiff
path: root/tools/test-js-optimizer-t3.js
blob: 0e02f72bc36ede5aad5afe6830036669e4f9ac5d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
function _png_create_write_struct_2($user_png_ver, $error_ptr, $error_fn, $warn_fn, $mem_ptr, $malloc_fn, $free_fn) {
 var $png_ptr$s2;
 var label;
 label = 2;
 var setjmpTable = {
  "2": (function(value) {
   label = 5;
   $call1 = value;
  }),
  dummy: 0
 };
 while (1) try {
  switch (label) {
   case 2:
   var $png_ptr;
   var $call = _png_create_struct(1);
   $png_ptr = $call;
   var $call1 = (HEAP32[$png_ptr >> 2] = label, 0);
   label = 5;
   break;
   case 5:
   var $2 = $png_ptr;
   if (($call1 | 0) == 0) {
    label = 4;
    break;
   } else {
    label = 3;
    break;
   }
   case 3:
   var $4 = HEAP32[($png_ptr >> 2) + (148 >> 2)];
   _png_free($2, $4);
   HEAP32[($png_ptr >> 2) + (148 >> 2)] = 0;
   _png_destroy_struct($png_ptr);
   var $retval_0 = 0;
   label = 4;
   break;
   case 4:
   var $retval_0;
   return $retval_0;
   default:
   assert(0, "bad label: " + label);
  }
 } catch (e) {
  if (!e.longjmp) throw e;
  setjmpTable[e.label](e.value);
 }
}
// EMSCRIPTEN_GENERATED_FUNCTIONS: ["_png_create_write_struct_2"]