never@1445: /* mikael@6198: * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. twisti@2729: * Copyright 2007, 2008, 2009, 2010, 2011 Red Hat, Inc. never@1445: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. never@1445: * never@1445: * This code is free software; you can redistribute it and/or modify it never@1445: * under the terms of the GNU General Public License version 2 only, as never@1445: * published by the Free Software Foundation. never@1445: * never@1445: * This code is distributed in the hope that it will be useful, but WITHOUT never@1445: * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or never@1445: * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License never@1445: * version 2 for more details (a copy is included in the LICENSE file that never@1445: * accompanied this code). never@1445: * never@1445: * You should have received a copy of the GNU General Public License version never@1445: * 2 along with this work; if not, write to the Free Software Foundation, never@1445: * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. never@1445: * trims@1907: * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA trims@1907: * or visit www.oracle.com if you need additional information or have any trims@1907: * questions. never@1445: * never@1445: */ never@1445: stefank@2314: #include "precompiled.hpp" stefank@2314: #include "asm/assembler.hpp" stefank@2314: #include "assembler_zero.inline.hpp" stefank@2314: #include "code/debugInfoRec.hpp" stefank@2314: #include "code/icBuffer.hpp" stefank@2314: #include "code/vtableStubs.hpp" stefank@2314: #include "interpreter/interpreter.hpp" coleenp@4037: #include "oops/compiledICHolder.hpp" stefank@2314: #include "prims/jvmtiRedefineClassesTrace.hpp" stefank@2314: #include "runtime/sharedRuntime.hpp" stefank@2314: #include "runtime/vframeArray.hpp" stefank@2314: #include "vmreg_zero.inline.hpp" twisti@4237: stefank@2314: #ifdef COMPILER1 stefank@2314: #include "c1/c1_Runtime1.hpp" stefank@2314: #endif stefank@2314: #ifdef COMPILER2 stefank@2314: #include "opto/runtime.hpp" stefank@2314: #endif stefank@2314: #ifdef SHARK stefank@2314: #include "compiler/compileBroker.hpp" stefank@2314: #include "shark/sharkCompiler.hpp" stefank@2314: #endif never@1445: never@1445: twisti@4237: twisti@4237: static address zero_null_code_stub() { twisti@4237: address start = ShouldNotCallThisStub(); twisti@4237: return start; twisti@4237: } twisti@4237: never@1445: int SharedRuntime::java_calling_convention(const BasicType *sig_bt, never@1445: VMRegPair *regs, never@1445: int total_args_passed, never@1445: int is_outgoing) { never@1445: return 0; never@1445: } never@1445: never@1445: AdapterHandlerEntry* SharedRuntime::generate_i2c2i_adapters( never@1445: MacroAssembler *masm, never@1445: int total_args_passed, never@1445: int comp_args_on_stack, never@1445: const BasicType *sig_bt, twisti@1632: const VMRegPair *regs, twisti@1632: AdapterFingerPrint *fingerprint) { twisti@1632: return AdapterHandlerLibrary::new_entry( twisti@1632: fingerprint, twisti@4237: CAST_FROM_FN_PTR(address,zero_null_code_stub), twisti@4237: CAST_FROM_FN_PTR(address,zero_null_code_stub), twisti@4237: CAST_FROM_FN_PTR(address,zero_null_code_stub)); never@1445: } never@1445: never@1445: nmethod *SharedRuntime::generate_native_wrapper(MacroAssembler *masm, never@1445: methodHandle method, twisti@2729: int compile_id, twisti@2729: BasicType *sig_bt, twisti@2729: VMRegPair *regs, never@1445: BasicType ret_type) { twisti@1513: #ifdef SHARK twisti@1513: return SharkCompiler::compiler()->generate_native_wrapper(masm, twisti@1513: method, twisti@2729: compile_id, twisti@2729: sig_bt, twisti@1513: ret_type); twisti@1513: #else never@1445: ShouldNotCallThis(); twisti@5545: return NULL; twisti@1513: #endif // SHARK never@1445: } never@1445: never@1445: int Deoptimization::last_frame_adjust(int callee_parameters, never@1445: int callee_locals) { never@1445: return 0; never@1445: } never@1445: never@1445: uint SharedRuntime::out_preserve_stack_slots() { never@1445: ShouldNotCallThis(); twisti@5545: return 0; never@1445: } never@1445: twisti@4237: JRT_LEAF(void, zero_stub()) twisti@4237: ShouldNotCallThis(); twisti@4237: JRT_END twisti@4237: never@1445: static RuntimeStub* generate_empty_runtime_stub(const char* name) { twisti@4237: return CAST_FROM_FN_PTR(RuntimeStub*,zero_stub); never@1445: } never@1445: never@1445: static SafepointBlob* generate_empty_safepoint_blob() { twisti@4237: return CAST_FROM_FN_PTR(SafepointBlob*,zero_stub); never@1445: } never@1445: twisti@3045: static DeoptimizationBlob* generate_empty_deopt_blob() { twisti@4237: return CAST_FROM_FN_PTR(DeoptimizationBlob*,zero_stub); twisti@3045: } never@1445: twisti@3045: twisti@3045: void SharedRuntime::generate_deopt_blob() { twisti@3045: _deopt_blob = generate_empty_deopt_blob(); twisti@3045: } twisti@3045: twisti@4237: SafepointBlob* SharedRuntime::generate_handler_blob(address call_ptr, int poll_type) { twisti@3045: return generate_empty_safepoint_blob(); twisti@3045: } twisti@3045: twisti@3045: RuntimeStub* SharedRuntime::generate_resolve_blob(address destination, const char* name) { twisti@3045: return generate_empty_runtime_stub("resolve_blob"); never@1445: } never@1445: twisti@4237: never@1445: int SharedRuntime::c_calling_convention(const BasicType *sig_bt, never@1445: VMRegPair *regs, goetz@6466: VMRegPair *regs2, never@1445: int total_args_passed) { never@1445: ShouldNotCallThis(); twisti@5545: return 0; never@1445: }