annotate src/cpu/sparc/vm/graalCodeInstaller_sparc.hpp @ 14107:800057208a2c

enable C1 + Graal tiered
author Tom Rodriguez <tom.rodriguez@oracle.com>
date Thu, 06 Mar 2014 17:11:39 -0800
parents 4e679d50ba9a
children e14198669e5c
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
1 /*
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
2 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
4 *
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
7 * published by the Free Software Foundation.
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
8 *
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
13 * accompanied this code).
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
14 *
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
18 *
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
20 * or visit www.oracle.com if you need additional information or have any
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
21 * questions.
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
22 */
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
23
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
24 #ifndef CPU_SPARC_VM_CODEINSTALLER_SPARC_HPP
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
25 #define CPU_SPARC_VM_CODEINSTALLER_SPARC_HPP
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
26
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
27 #include "graal/graalCompiler.hpp"
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
28 #include "graal/graalCompilerToVM.hpp"
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
29 #include "graal/graalJavaAccess.hpp"
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
30
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
31 inline jint CodeInstaller::pd_next_offset(NativeInstruction* inst, jint pc_offset, oop method) {
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
32 if (inst->is_call() || inst->is_jump()) {
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
33 return pc_offset + NativeCall::instruction_size;
11233
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
34 } else if (inst->is_call_reg()) {
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
35 return pc_offset + NativeCallReg::instruction_size;
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
36 } else if (inst->is_sethi()) {
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
37 return pc_offset + NativeFarCall::instruction_size;
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
38 } else {
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
39 fatal("unsupported type of instruction for call site");
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
40 return 0;
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
41 }
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
42 }
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
43
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
44 inline void CodeInstaller::pd_site_DataPatch(int pc_offset, oop site) {
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
45 oop inlineData = CompilationResult_DataPatch::inlineData(site);
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
46 address pc = _instructions->start() + pc_offset;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
47
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
48 if (inlineData != NULL) {
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
49 oop kind = Constant::kind(inlineData);
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
50 char typeChar = Kind::typeChar(kind);
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
51
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
52 switch (typeChar) {
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
53 case 'z':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
54 case 'b':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
55 case 's':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
56 case 'c':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
57 case 'i':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
58 fatal("int-sized values not expected in DataPatch");
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
59 break;
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
60 case 'f':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
61 case 'j':
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
62 case 'd': {
10792
7a8d6ba83a04 SPARC: fixes and more stuff works
twisti
parents: 10684
diff changeset
63 NativeMovConstReg* move = nativeMovConstReg_at(pc);
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
64 uint64_t value = Constant::primitive(inlineData);
10792
7a8d6ba83a04 SPARC: fixes and more stuff works
twisti
parents: 10684
diff changeset
65 move->set_data(value);
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
66 break;
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
67 }
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
68 case 'a': {
11233
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
69 NativeMovConstReg* move = nativeMovConstReg_at(pc);
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
70 Handle obj = Constant::object(inlineData);
11233
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
71 jobject value = JNIHandles::make_local(obj());
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
72 move->set_data((intptr_t) value);
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
73
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
74 // We need two relocations: one on the sethi and one on the add.
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
75 int oop_index = _oop_recorder->find_index(value);
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
76 RelocationHolder rspec = oop_Relocation::spec(oop_index);
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
77 _instructions->relocate(pc + NativeMovConstReg::sethi_offset, rspec);
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
78 _instructions->relocate(pc + NativeMovConstReg::add_offset, rspec);
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
79 break;
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
80 }
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
81 default:
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
82 fatal(err_msg("unexpected Kind (%d) in DataPatch", typeChar));
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
83 break;
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
84 }
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
85 } else {
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
86 oop dataRef = CompilationResult_DataPatch::externalData(site);
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
87 jint offset = HotSpotCompiledCode_HotSpotData::offset(dataRef);
11233
5a9d68c3a7d7 SPARC: a lot of fixes and more
twisti
parents: 10871
diff changeset
88
13576
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
89 NativeMovRegMem* load = nativeMovRegMem_at(pc);
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
90 int disp = _constants_size + pc_offset - offset - BytesPerInstWord;
4e679d50ba9a Move data section building code to Java.
Roland Schatz <roland.schatz@oracle.com>
parents: 13553
diff changeset
91 load->set_offset(-disp);
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
92 }
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
93 }
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
94
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
95 inline void CodeInstaller::pd_relocate_CodeBlob(CodeBlob* cb, NativeInstruction* inst) {
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
96 fatal("CodeInstaller::pd_relocate_CodeBlob - sparc unimp");
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
97 }
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
98
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
99 inline void CodeInstaller::pd_relocate_ForeignCall(NativeInstruction* inst, jlong foreign_call_destination) {
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
100 address pc = (address) inst;
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
101 if (inst->is_call()) {
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
102 NativeCall* call = nativeCall_at(pc);
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
103 call->set_destination((address) foreign_call_destination);
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
104 _instructions->relocate(call->instruction_address(), runtime_call_Relocation::spec());
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
105 } else if (inst->is_sethi()) {
10871
c3b09d69dfde SPARC: fixes and more implementation; can now allocate objects
twisti
parents: 10854
diff changeset
106 NativeJump* jump = nativeJump_at(pc);
c3b09d69dfde SPARC: fixes and more implementation; can now allocate objects
twisti
parents: 10854
diff changeset
107 jump->set_jump_destination((address) foreign_call_destination);
c3b09d69dfde SPARC: fixes and more implementation; can now allocate objects
twisti
parents: 10854
diff changeset
108 _instructions->relocate(jump->instruction_address(), runtime_call_Relocation::spec());
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
109 } else {
10871
c3b09d69dfde SPARC: fixes and more implementation; can now allocate objects
twisti
parents: 10854
diff changeset
110 fatal(err_msg("unknown call or jump instruction at %p", pc));
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
111 }
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
112 TRACE_graal_3("relocating (foreign call) at %p", inst);
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
113 }
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
114
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
115 inline void CodeInstaller::pd_relocate_JavaMethod(oop hotspot_method, jint pc_offset) {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
116 #ifdef ASSERT
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
117 Method* method = NULL;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
118 // we need to check, this might also be an unresolved method
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
119 if (hotspot_method->is_a(HotSpotResolvedJavaMethod::klass())) {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
120 method = getMethodFromHotSpotMethod(hotspot_method);
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
121 }
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
122 #endif
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
123 switch (_next_call_type) {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
124 case MARK_INLINE_INVOKE:
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
125 break;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
126 case MARK_INVOKEVIRTUAL:
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
127 case MARK_INVOKEINTERFACE: {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
128 assert(method == NULL || !method->is_static(), "cannot call static method with invokeinterface");
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
129 NativeCall* call = nativeCall_at(_instructions->start() + pc_offset);
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
130 call->set_destination(SharedRuntime::get_resolve_virtual_call_stub());
10792
7a8d6ba83a04 SPARC: fixes and more stuff works
twisti
parents: 10684
diff changeset
131 _instructions->relocate(call->instruction_address(), virtual_call_Relocation::spec(_invoke_mark_pc));
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
132 break;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
133 }
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
134 case MARK_INVOKESTATIC: {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
135 assert(method == NULL || method->is_static(), "cannot call non-static method with invokestatic");
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
136 NativeCall* call = nativeCall_at(_instructions->start() + pc_offset);
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
137 call->set_destination(SharedRuntime::get_resolve_static_call_stub());
10792
7a8d6ba83a04 SPARC: fixes and more stuff works
twisti
parents: 10684
diff changeset
138 _instructions->relocate(call->instruction_address(), relocInfo::static_call_type);
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
139 break;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
140 }
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
141 case MARK_INVOKESPECIAL: {
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
142 assert(method == NULL || !method->is_static(), "cannot call static method with invokespecial");
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
143 NativeCall* call = nativeCall_at(_instructions->start() + pc_offset);
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
144 call->set_destination(SharedRuntime::get_resolve_opt_virtual_call_stub());
10854
e1fcdda22831 SPARC: can compile some stubs now but they don't work yet
twisti
parents: 10792
diff changeset
145 _instructions->relocate(call->instruction_address(), relocInfo::opt_virtual_call_type);
10684
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
146 break;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
147 }
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
148 default:
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
149 fatal("invalid _next_call_type value");
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
150 break;
6ff467cdb105 Code installer changes for SPARC.
twisti
parents: 10411
diff changeset
151 }
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
152 }
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
153
11799
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
154 inline void CodeInstaller::pd_relocate_poll(address pc, jint mark) {
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
155 switch (mark) {
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
156 case MARK_POLL_NEAR: {
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
157 fatal("unimplemented");
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
158 }
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
159 case MARK_POLL_FAR:
13553
d49f00604347 removed poll_Relocation::pollingForm type and associated data field and rely solely on format field of safepoint relocation entries when deciding whether or not to relocate the operand of a safepoint poll instruction
Doug Simon <doug.simon@oracle.com>
parents: 13515
diff changeset
160 _instructions->relocate(pc, relocInfo::poll_type);
11799
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
161 break;
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
162 case MARK_POLL_RETURN_NEAR: {
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
163 fatal("unimplemented");
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
164 }
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
165 case MARK_POLL_RETURN_FAR:
13553
d49f00604347 removed poll_Relocation::pollingForm type and associated data field and rely solely on format field of safepoint relocation entries when deciding whether or not to relocate the operand of a safepoint poll instruction
Doug Simon <doug.simon@oracle.com>
parents: 13515
diff changeset
166 _instructions->relocate(pc, relocInfo::poll_return_type);
11799
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
167 break;
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
168 default:
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
169 fatal("invalid mark value");
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
170 break;
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
171 }
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
172 }
4c96ccce3772 SPARC: added CodeInstaller::pd_relocate_poll
twisti
parents: 11760
diff changeset
173
9934
0f7ca53be929 CR-806: Changes to build Graal for SPARC
Morris Meyer <morris.meyer@oracle.com>
parents:
diff changeset
174 #endif // CPU_SPARC_VM_CODEINSTALLER_SPARC_HPP