1010
|
1 /*
|
|
2 * Copyright 2003-2007 Sun Microsystems, Inc. All Rights Reserved.
|
1078
|
3 * Copyright 2007, 2008, 2009 Red Hat, Inc.
|
1010
|
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
5 *
|
|
6 * This code is free software; you can redistribute it and/or modify it
|
|
7 * under the terms of the GNU General Public License version 2 only, as
|
|
8 * published by the Free Software Foundation.
|
|
9 *
|
|
10 * This code is distributed in the hope that it will be useful, but WITHOUT
|
|
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
13 * version 2 for more details (a copy is included in the LICENSE file that
|
|
14 * accompanied this code).
|
|
15 *
|
|
16 * You should have received a copy of the GNU General Public License version
|
|
17 * 2 along with this work; if not, write to the Free Software Foundation,
|
|
18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
19 *
|
|
20 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
|
21 * CA 95054 USA or visit www.sun.com if you need additional information or
|
|
22 * have any questions.
|
|
23 *
|
|
24 */
|
|
25
|
|
26 #include "incls/_precompiled.incl"
|
|
27 #include "incls/_sharedRuntime_zero.cpp.incl"
|
|
28
|
|
29 DeoptimizationBlob *SharedRuntime::_deopt_blob;
|
|
30 SafepointBlob *SharedRuntime::_polling_page_safepoint_handler_blob;
|
|
31 SafepointBlob *SharedRuntime::_polling_page_return_handler_blob;
|
|
32 RuntimeStub *SharedRuntime::_wrong_method_blob;
|
|
33 RuntimeStub *SharedRuntime::_ic_miss_blob;
|
|
34 RuntimeStub *SharedRuntime::_resolve_opt_virtual_call_blob;
|
|
35 RuntimeStub *SharedRuntime::_resolve_virtual_call_blob;
|
|
36 RuntimeStub *SharedRuntime::_resolve_static_call_blob;
|
|
37
|
|
38 int SharedRuntime::java_calling_convention(const BasicType *sig_bt,
|
|
39 VMRegPair *regs,
|
|
40 int total_args_passed,
|
|
41 int is_outgoing) {
|
|
42 return 0;
|
|
43 }
|
|
44
|
|
45 AdapterHandlerEntry* SharedRuntime::generate_i2c2i_adapters(
|
|
46 MacroAssembler *masm,
|
|
47 int total_args_passed,
|
|
48 int comp_args_on_stack,
|
|
49 const BasicType *sig_bt,
|
|
50 const VMRegPair *regs) {
|
|
51 return new AdapterHandlerEntry(
|
|
52 ShouldNotCallThisStub(),
|
|
53 ShouldNotCallThisStub(),
|
|
54 ShouldNotCallThisStub());
|
|
55 }
|
|
56
|
|
57 nmethod *SharedRuntime::generate_native_wrapper(MacroAssembler *masm,
|
|
58 methodHandle method,
|
|
59 int total_in_args,
|
|
60 int comp_args_on_stack,
|
|
61 BasicType *in_sig_bt,
|
|
62 VMRegPair *in_regs,
|
|
63 BasicType ret_type) {
|
1078
|
64 #ifdef SHARK
|
|
65 return SharkCompiler::compiler()->generate_native_wrapper(masm,
|
|
66 method,
|
|
67 in_sig_bt,
|
|
68 ret_type);
|
|
69 #else
|
1010
|
70 ShouldNotCallThis();
|
1078
|
71 #endif // SHARK
|
1010
|
72 }
|
|
73
|
|
74 int Deoptimization::last_frame_adjust(int callee_parameters,
|
|
75 int callee_locals) {
|
|
76 return 0;
|
|
77 }
|
|
78
|
|
79 uint SharedRuntime::out_preserve_stack_slots() {
|
|
80 ShouldNotCallThis();
|
|
81 }
|
|
82
|
|
83 static RuntimeStub* generate_empty_runtime_stub(const char* name) {
|
|
84 CodeBuffer buffer(name, 0, 0);
|
|
85 return RuntimeStub::new_runtime_stub(name, &buffer, 0, 0, NULL, false);
|
|
86 }
|
|
87
|
|
88 static SafepointBlob* generate_empty_safepoint_blob() {
|
|
89 CodeBuffer buffer("handler_blob", 0, 0);
|
|
90 return SafepointBlob::create(&buffer, NULL, 0);
|
|
91 }
|
|
92
|
|
93 void SharedRuntime::generate_stubs() {
|
|
94 _wrong_method_blob =
|
|
95 generate_empty_runtime_stub("wrong_method_stub");
|
|
96 _ic_miss_blob =
|
|
97 generate_empty_runtime_stub("ic_miss_stub");
|
|
98 _resolve_opt_virtual_call_blob =
|
|
99 generate_empty_runtime_stub("resolve_opt_virtual_call");
|
|
100 _resolve_virtual_call_blob =
|
|
101 generate_empty_runtime_stub("resolve_virtual_call");
|
|
102 _resolve_static_call_blob =
|
|
103 generate_empty_runtime_stub("resolve_static_call");
|
|
104
|
|
105 _polling_page_safepoint_handler_blob =
|
|
106 generate_empty_safepoint_blob();
|
|
107 _polling_page_return_handler_blob =
|
|
108 generate_empty_safepoint_blob();
|
|
109 }
|
|
110
|
|
111 int SharedRuntime::c_calling_convention(const BasicType *sig_bt,
|
|
112 VMRegPair *regs,
|
|
113 int total_args_passed) {
|
|
114 ShouldNotCallThis();
|
|
115 }
|