741 int bcp_offset, size_t index_size) { |
741 int bcp_offset, size_t index_size) { |
742 assert(bcp_offset > 0, "bcp is still pointing to start of bytecode"); |
742 assert(bcp_offset > 0, "bcp is still pointing to start of bytecode"); |
743 if (index_size == sizeof(u2)) { |
743 if (index_size == sizeof(u2)) { |
744 get_2_byte_integer_at_bcp(bcp_offset, cache, tmp, Unsigned); |
744 get_2_byte_integer_at_bcp(bcp_offset, cache, tmp, Unsigned); |
745 } else if (index_size == sizeof(u4)) { |
745 } else if (index_size == sizeof(u4)) { |
746 assert(EnableInvokeDynamic, "giant index used only for EnableInvokeDynamic"); |
746 assert(EnableInvokeDynamic, "giant index used only for JSR 292"); |
747 get_4_byte_integer_at_bcp(bcp_offset, cache, tmp); |
747 get_4_byte_integer_at_bcp(bcp_offset, cache, tmp); |
748 assert(constantPoolCacheOopDesc::decode_secondary_index(~123) == 123, "else change next line"); |
748 assert(constantPoolCacheOopDesc::decode_secondary_index(~123) == 123, "else change next line"); |
749 xor3(tmp, -1, tmp); // convert to plain index |
749 xor3(tmp, -1, tmp); // convert to plain index |
750 } else if (index_size == sizeof(u1)) { |
750 } else if (index_size == sizeof(u1)) { |
751 assert(EnableMethodHandles, "tiny index used only for EnableMethodHandles"); |
751 assert(EnableInvokeDynamic, "tiny index used only for JSR 292"); |
752 ldub(Lbcp, bcp_offset, tmp); |
752 ldub(Lbcp, bcp_offset, tmp); |
753 } else { |
753 } else { |
754 ShouldNotReachHere(); |
754 ShouldNotReachHere(); |
755 } |
755 } |
756 } |
756 } |