Пример #1
0
 jushort *ushort_base_address() {
   GUARANTEE(ObjectHeap::is_gc_active() || is_short_array(), "type check");
   return (jushort*)base_address();
 }
Пример #2
0
 int offset_from_ushort_index(int index) const { 
   GUARANTEE(ObjectHeap::is_gc_active() || is_short_array(),
             "Array must be short array"); 
   GUARANTEE(is_within_bounds(index), "Array index out of bounds");
   return base_offset() + (index * sizeof(jushort));
 }
Пример #3
0
 void set_start_pc(int index, jushort start_pc) {
   GUARANTEE(((index * 3) + 1) < length(),
             "local var table: start_pc index out of range");
   GUARANTEE(is_short_array(), "Local variable table wrong type");
   ushort_at_put((index * 3) + 1, start_pc);
 }
Пример #4
0
 void set_line_number(int index, jushort line_num) {
   GUARANTEE(((index * 2) + 1) < length(),
             "line number table line_num index out of bounds");
   GUARANTEE(is_short_array(), "Line number table wrong type");
   ushort_at_put((index * 2) + 1, line_num);
 }
Пример #5
0
 void set_pc(int index, jushort start_pc) {
   GUARANTEE((index * 2) < length(),
             "line number table pc index out of bounds");
   GUARANTEE(is_short_array(), "Line number table wrong type");
   short_at_put(index * 2, start_pc);
 }
Пример #6
0
 void set_slot(int index, jushort slot) {
   GUARANTEE((index * 3) < length(),
             "local var table: slot index out of range");
   GUARANTEE(is_short_array(), "Local variable table wrong type");
   ushort_at_put(index * 3, slot);
 }
Пример #7
0
 void set_code_length(int index, jushort code_length) {
   GUARANTEE(((index * 3) + 2) < length(),
             "local var table: code_length index out of range");
   GUARANTEE(is_short_array(), "Local variable table wrong type");
   ushort_at_put((index * 3) + 2, code_length);
 }