src/share/vm/oops/cpCache.hpp

changeset 8997
f8a45a60bc6b
parent 8739
0b85ccd62409
child 9041
95a08233f46c
equal deleted inserted replaced
8996:2667e5c45e24 8997:f8a45a60bc6b
1 /* 1 /*
2 * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
246 int vtable_index // the vtable index 246 int vtable_index // the vtable index
247 ); 247 );
248 248
249 void set_itable_call( 249 void set_itable_call(
250 Bytecodes::Code invoke_code, // the bytecode used; must be invokeinterface 250 Bytecodes::Code invoke_code, // the bytecode used; must be invokeinterface
251 KlassHandle referenced_klass, // the referenced klass in the InterfaceMethodref
251 methodHandle method, // the resolved interface method 252 methodHandle method, // the resolved interface method
252 int itable_index // index into itable for the method 253 int itable_index // index into itable for the method
253 ); 254 );
254 255
255 void set_method_handle( 256 void set_method_handle(
342 // of _f1 must be ordered with the loads performed by 343 // of _f1 must be ordered with the loads performed by
343 // cache->main_entry_index(). 344 // cache->main_entry_index().
344 bool is_f1_null() const { Metadata* f1 = f1_ord(); return f1 == NULL; } // classifies a CPC entry as unbound 345 bool is_f1_null() const { Metadata* f1 = f1_ord(); return f1 == NULL; } // classifies a CPC entry as unbound
345 int f2_as_index() const { assert(!is_vfinal(), ""); return (int) _f2; } 346 int f2_as_index() const { assert(!is_vfinal(), ""); return (int) _f2; }
346 Method* f2_as_vfinal_method() const { assert(is_vfinal(), ""); return (Method*)_f2; } 347 Method* f2_as_vfinal_method() const { assert(is_vfinal(), ""); return (Method*)_f2; }
348 Method* f2_as_interface_method() const { assert(bytecode_1() == Bytecodes::_invokeinterface, ""); return (Method*)_f2; }
347 int field_index() const { assert(is_field_entry(), ""); return (_flags & field_index_mask); } 349 int field_index() const { assert(is_field_entry(), ""); return (_flags & field_index_mask); }
348 int parameter_size() const { assert(is_method_entry(), ""); return (_flags & parameter_size_mask); } 350 int parameter_size() const { assert(is_method_entry(), ""); return (_flags & parameter_size_mask); }
349 bool is_volatile() const { return (_flags & (1 << is_volatile_shift)) != 0; } 351 bool is_volatile() const { return (_flags & (1 << is_volatile_shift)) != 0; }
350 bool is_final() const { return (_flags & (1 << is_final_shift)) != 0; } 352 bool is_final() const { return (_flags & (1 << is_final_shift)) != 0; }
351 bool is_forced_virtual() const { return (_flags & (1 << is_forced_virtual_shift)) != 0; } 353 bool is_forced_virtual() const { return (_flags & (1 << is_forced_virtual_shift)) != 0; }
372 // If this ConstantPoolCacheEntry refers to old_method then update it 374 // If this ConstantPoolCacheEntry refers to old_method then update it
373 // to refer to new_method. 375 // to refer to new_method.
374 // trace_name_printed is set to true if the current call has 376 // trace_name_printed is set to true if the current call has
375 // printed the klass name so that other routines in the adjust_* 377 // printed the klass name so that other routines in the adjust_*
376 // group don't print the klass name. 378 // group don't print the klass name.
377 bool adjust_method_entry(Method* old_method, Method* new_method, 379 void adjust_method_entry(Method* old_method, Method* new_method,
378 bool* trace_name_printed); 380 bool* trace_name_printed);
379 bool check_no_old_or_obsolete_entries(); 381 bool check_no_old_or_obsolete_entries();
380 Method* get_interesting_method_entry(Klass* k); 382 Method* get_interesting_method_entry(Klass* k);
381 #endif // INCLUDE_JVMTI 383 #endif // INCLUDE_JVMTI
382 384

mercurial