src/main/java/org/plumelib/bcelutil/StackMapUtils.java
protected final StackMapEntry find_stack_map_equal(int offset) {

    running_offset = -1; // no +1 on first entry
    for (int i = 0; i < stack_map_table.length; i++) {
      running_offset = stack_map_table[i].getByteCodeOffset() + running_offset + 1;

      if (running_offset > offset) {
        throw new RuntimeException("Invalid StackMap offset 1");
      }

      if (running_offset == offset) {
        return stack_map_table[i];
      }
      // try next map entry
    }

    // no offset matched
    throw new RuntimeException("Invalid StackMap offset 2");
  }
protected final StackMapEntry find_stack_map_equal(int offset) {

    running_offset = -1; // no +1 on first entry
    for (int i = 0; i < stack_map_table.length; i++) {
      running_offset = stack_map_table[i].getByteCodeOffset() + running_offset + 1;

      if (running_offset > offset) {
        throw new RuntimeException("Invalid StackMap offset 1");
      }

      if (running_offset == offset) {
        return stack_map_table[i];
      }
      // try next map entry
    }

    // no offset matched
    throw new RuntimeException("Invalid StackMap offset 2");
  }
protected final StackMapEntry find_stack_map_equal ( int offset ) { running_offset = - 1 ; // no +1 on first entry for ( int i = 0 ; i < stack_map_table . length ; i ++ ) { running_offset = stack_map_table [ i ] . getByteCodeOffset ( ) + running_offset + 1 ; if ( running_offset > offset ) { throw new RuntimeException ( "Invalid StackMap offset 1" ) ; } if ( running_offset == offset ) { return stack_map_table [ i ] ; } // try next map entry } // no offset matched throw new RuntimeException ( "Invalid StackMap offset 2" ) ; }
Find the StackMap entry whose offset matches the input argument. Also sets running_offset.

@param offset byte code offset
@return the corresponding StackMapEntry
Find the StackMap entry whose offset matches the input argument . Also sets running_offset .