/* * Copyright (c) 1997, 2020, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. *
*/
// // For CompiledIC's: // // In cases where we do not have MT-safe state transformation, // we go to a transition state, using ICStubs. At a safepoint, // the inline caches are transferred from the transitional code: // // instruction_address --> 01 set xxx_oop, Ginline_cache_klass // 23 jump_to Gtemp, yyyy // 4 nop
class ICStub: public Stub { private: int _size; // total size of the stub incl. code
address _ic_site; // points at call instruction of owning ic-buffer /* stub code follows here */ protected: friendclass ICStubInterface; // This will be called only by ICStubInterface void initialize(int size) { _size = size; _ic_site = NULL; } void finalize(); // called when a method is removed
// General info int size() const { return _size; }
// ICStub_from_destination_address looks up Stub* address from code entry address, // which unfortunately means the stub head should be at the same alignment as the code. staticint alignment() { return CodeEntryAlignment; }
#ifdef ASSERT // The ICRefillVerifier class is a stack allocated RAII object used to // detect if a failed IC transition that required IC stub refilling has // been accidentally missed. It is up to the caller to in that case // refill IC stubs. class ICRefillVerifier: StackObj { bool _refill_requested; bool _refill_remembered;
// The ICRefillVerifierMark is used to set the thread's current // ICRefillVerifier to a provided one. This is useful in particular // when transitioning IC stubs in parallel and refilling from the // master thread invoking the IC stub transitioning code. class ICRefillVerifierMark: StackObj { public:
ICRefillVerifierMark(ICRefillVerifier* verifier);
~ICRefillVerifierMark();
}; #else class ICRefillVerifier: StackObj { public:
ICRefillVerifier() {}
}; class ICRefillVerifierMark: StackObj { public:
ICRefillVerifierMark(ICRefillVerifier* verifier) {}
}; #endif
class InlineCacheBuffer: public AllStatic { private: // friends friendclass ICStub;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.