annotate src/cpu/sparc/vm/jniFastGetField_sparc.cpp @ 196:d1605aabd0a1 jdk7-b30

6719955: Update copyright year Summary: Update copyright year for files that have been modified in 2008 Reviewed-by: ohair, tbell
author xdono
date Wed, 02 Jul 2008 12:55:16 -0700
parents a61af66fc99e
children 6b2273dd6fa9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
a61af66fc99e Initial load
duke
parents:
diff changeset
1 /*
a61af66fc99e Initial load
duke
parents:
diff changeset
2 * Copyright 2004-2006 Sun Microsystems, Inc. All Rights Reserved.
a61af66fc99e Initial load
duke
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
a61af66fc99e Initial load
duke
parents:
diff changeset
4 *
a61af66fc99e Initial load
duke
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
a61af66fc99e Initial load
duke
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
a61af66fc99e Initial load
duke
parents:
diff changeset
7 * published by the Free Software Foundation.
a61af66fc99e Initial load
duke
parents:
diff changeset
8 *
a61af66fc99e Initial load
duke
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
a61af66fc99e Initial load
duke
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
a61af66fc99e Initial load
duke
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
a61af66fc99e Initial load
duke
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
a61af66fc99e Initial load
duke
parents:
diff changeset
13 * accompanied this code).
a61af66fc99e Initial load
duke
parents:
diff changeset
14 *
a61af66fc99e Initial load
duke
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
a61af66fc99e Initial load
duke
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
a61af66fc99e Initial load
duke
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
a61af66fc99e Initial load
duke
parents:
diff changeset
18 *
a61af66fc99e Initial load
duke
parents:
diff changeset
19 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
a61af66fc99e Initial load
duke
parents:
diff changeset
20 * CA 95054 USA or visit www.sun.com if you need additional information or
a61af66fc99e Initial load
duke
parents:
diff changeset
21 * have any questions.
a61af66fc99e Initial load
duke
parents:
diff changeset
22 *
a61af66fc99e Initial load
duke
parents:
diff changeset
23 */
a61af66fc99e Initial load
duke
parents:
diff changeset
24
a61af66fc99e Initial load
duke
parents:
diff changeset
25 # include "incls/_precompiled.incl"
a61af66fc99e Initial load
duke
parents:
diff changeset
26 # include "incls/_jniFastGetField_sparc.cpp.incl"
a61af66fc99e Initial load
duke
parents:
diff changeset
27
a61af66fc99e Initial load
duke
parents:
diff changeset
28 // TSO ensures that loads are blocking and ordered with respect to
a61af66fc99e Initial load
duke
parents:
diff changeset
29 // to earlier loads, so we don't need LoadLoad membars.
a61af66fc99e Initial load
duke
parents:
diff changeset
30
a61af66fc99e Initial load
duke
parents:
diff changeset
31 #define __ masm->
a61af66fc99e Initial load
duke
parents:
diff changeset
32
a61af66fc99e Initial load
duke
parents:
diff changeset
33 #define BUFFER_SIZE 30*sizeof(jint)
a61af66fc99e Initial load
duke
parents:
diff changeset
34
a61af66fc99e Initial load
duke
parents:
diff changeset
35 // Common register usage:
a61af66fc99e Initial load
duke
parents:
diff changeset
36 // O0: env
a61af66fc99e Initial load
duke
parents:
diff changeset
37 // O1: obj
a61af66fc99e Initial load
duke
parents:
diff changeset
38 // O2: jfieldID
a61af66fc99e Initial load
duke
parents:
diff changeset
39 // O4: offset (O2 >> 2)
a61af66fc99e Initial load
duke
parents:
diff changeset
40 // G4: old safepoint counter
a61af66fc99e Initial load
duke
parents:
diff changeset
41
a61af66fc99e Initial load
duke
parents:
diff changeset
42 address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
43 const char *name;
a61af66fc99e Initial load
duke
parents:
diff changeset
44 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
45 case T_BOOLEAN: name = "jni_fast_GetBooleanField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
46 case T_BYTE: name = "jni_fast_GetByteField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
47 case T_CHAR: name = "jni_fast_GetCharField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
48 case T_SHORT: name = "jni_fast_GetShortField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
49 case T_INT: name = "jni_fast_GetIntField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
50 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
51 }
a61af66fc99e Initial load
duke
parents:
diff changeset
52 ResourceMark rm;
a61af66fc99e Initial load
duke
parents:
diff changeset
53 BufferBlob* b = BufferBlob::create(name, BUFFER_SIZE*wordSize);
a61af66fc99e Initial load
duke
parents:
diff changeset
54 address fast_entry = b->instructions_begin();
a61af66fc99e Initial load
duke
parents:
diff changeset
55 CodeBuffer cbuf(fast_entry, b->instructions_size());
a61af66fc99e Initial load
duke
parents:
diff changeset
56 MacroAssembler* masm = new MacroAssembler(&cbuf);
a61af66fc99e Initial load
duke
parents:
diff changeset
57
a61af66fc99e Initial load
duke
parents:
diff changeset
58 Label label1, label2;
a61af66fc99e Initial load
duke
parents:
diff changeset
59
a61af66fc99e Initial load
duke
parents:
diff changeset
60 address cnt_addr = SafepointSynchronize::safepoint_counter_addr();
a61af66fc99e Initial load
duke
parents:
diff changeset
61 Address ca(O3, cnt_addr);
a61af66fc99e Initial load
duke
parents:
diff changeset
62 __ sethi (ca);
a61af66fc99e Initial load
duke
parents:
diff changeset
63 __ ld (ca, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
64 __ andcc (G4, 1, G0);
a61af66fc99e Initial load
duke
parents:
diff changeset
65 __ br (Assembler::notZero, false, Assembler::pn, label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
66 __ delayed()->srl (O2, 2, O4);
a61af66fc99e Initial load
duke
parents:
diff changeset
67 __ ld_ptr (O1, 0, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
68
a61af66fc99e Initial load
duke
parents:
diff changeset
69 assert(count < LIST_CAPACITY, "LIST_CAPACITY too small");
a61af66fc99e Initial load
duke
parents:
diff changeset
70 speculative_load_pclist[count] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
71 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
72 case T_BOOLEAN: __ ldub (O5, O4, G3); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
73 case T_BYTE: __ ldsb (O5, O4, G3); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
74 case T_CHAR: __ lduh (O5, O4, G3); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
75 case T_SHORT: __ ldsh (O5, O4, G3); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
76 case T_INT: __ ld (O5, O4, G3); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
77 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
78 }
a61af66fc99e Initial load
duke
parents:
diff changeset
79
a61af66fc99e Initial load
duke
parents:
diff changeset
80 __ ld (ca, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
81 __ cmp (O5, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
82 __ br (Assembler::notEqual, false, Assembler::pn, label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
83 __ delayed()->mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
84 __ retl ();
a61af66fc99e Initial load
duke
parents:
diff changeset
85 __ delayed()->mov (G3, O0);
a61af66fc99e Initial load
duke
parents:
diff changeset
86
a61af66fc99e Initial load
duke
parents:
diff changeset
87 slowcase_entry_pclist[count++] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
88 __ bind (label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
89 __ mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
90
a61af66fc99e Initial load
duke
parents:
diff changeset
91 address slow_case_addr;
a61af66fc99e Initial load
duke
parents:
diff changeset
92 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
93 case T_BOOLEAN: slow_case_addr = jni_GetBooleanField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
94 case T_BYTE: slow_case_addr = jni_GetByteField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
95 case T_CHAR: slow_case_addr = jni_GetCharField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
96 case T_SHORT: slow_case_addr = jni_GetShortField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
97 case T_INT: slow_case_addr = jni_GetIntField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
98 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
99 }
a61af66fc99e Initial load
duke
parents:
diff changeset
100 __ bind (label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
101 __ call (slow_case_addr, relocInfo::none);
a61af66fc99e Initial load
duke
parents:
diff changeset
102 __ delayed()->mov (G1, O7);
a61af66fc99e Initial load
duke
parents:
diff changeset
103
a61af66fc99e Initial load
duke
parents:
diff changeset
104 __ flush ();
a61af66fc99e Initial load
duke
parents:
diff changeset
105
a61af66fc99e Initial load
duke
parents:
diff changeset
106 return fast_entry;
a61af66fc99e Initial load
duke
parents:
diff changeset
107 }
a61af66fc99e Initial load
duke
parents:
diff changeset
108
a61af66fc99e Initial load
duke
parents:
diff changeset
109 address JNI_FastGetField::generate_fast_get_boolean_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
110 return generate_fast_get_int_field0(T_BOOLEAN);
a61af66fc99e Initial load
duke
parents:
diff changeset
111 }
a61af66fc99e Initial load
duke
parents:
diff changeset
112
a61af66fc99e Initial load
duke
parents:
diff changeset
113 address JNI_FastGetField::generate_fast_get_byte_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
114 return generate_fast_get_int_field0(T_BYTE);
a61af66fc99e Initial load
duke
parents:
diff changeset
115 }
a61af66fc99e Initial load
duke
parents:
diff changeset
116
a61af66fc99e Initial load
duke
parents:
diff changeset
117 address JNI_FastGetField::generate_fast_get_char_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
118 return generate_fast_get_int_field0(T_CHAR);
a61af66fc99e Initial load
duke
parents:
diff changeset
119 }
a61af66fc99e Initial load
duke
parents:
diff changeset
120
a61af66fc99e Initial load
duke
parents:
diff changeset
121 address JNI_FastGetField::generate_fast_get_short_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
122 return generate_fast_get_int_field0(T_SHORT);
a61af66fc99e Initial load
duke
parents:
diff changeset
123 }
a61af66fc99e Initial load
duke
parents:
diff changeset
124
a61af66fc99e Initial load
duke
parents:
diff changeset
125 address JNI_FastGetField::generate_fast_get_int_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
126 return generate_fast_get_int_field0(T_INT);
a61af66fc99e Initial load
duke
parents:
diff changeset
127 }
a61af66fc99e Initial load
duke
parents:
diff changeset
128
a61af66fc99e Initial load
duke
parents:
diff changeset
129 address JNI_FastGetField::generate_fast_get_long_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
130 const char *name = "jni_fast_GetLongField";
a61af66fc99e Initial load
duke
parents:
diff changeset
131 ResourceMark rm;
a61af66fc99e Initial load
duke
parents:
diff changeset
132 BufferBlob* b = BufferBlob::create(name, BUFFER_SIZE*wordSize);
a61af66fc99e Initial load
duke
parents:
diff changeset
133 address fast_entry = b->instructions_begin();
a61af66fc99e Initial load
duke
parents:
diff changeset
134 CodeBuffer cbuf(fast_entry, b->instructions_size());
a61af66fc99e Initial load
duke
parents:
diff changeset
135 MacroAssembler* masm = new MacroAssembler(&cbuf);
a61af66fc99e Initial load
duke
parents:
diff changeset
136
a61af66fc99e Initial load
duke
parents:
diff changeset
137 Label label1, label2;
a61af66fc99e Initial load
duke
parents:
diff changeset
138
a61af66fc99e Initial load
duke
parents:
diff changeset
139 address cnt_addr = SafepointSynchronize::safepoint_counter_addr();
a61af66fc99e Initial load
duke
parents:
diff changeset
140 Address ca(G3, cnt_addr);
a61af66fc99e Initial load
duke
parents:
diff changeset
141 __ sethi (ca);
a61af66fc99e Initial load
duke
parents:
diff changeset
142 __ ld (ca, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
143 __ andcc (G4, 1, G0);
a61af66fc99e Initial load
duke
parents:
diff changeset
144 __ br (Assembler::notZero, false, Assembler::pn, label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
145 __ delayed()->srl (O2, 2, O4);
a61af66fc99e Initial load
duke
parents:
diff changeset
146 __ ld_ptr (O1, 0, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
147 __ add (O5, O4, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
148
a61af66fc99e Initial load
duke
parents:
diff changeset
149 #ifndef _LP64
a61af66fc99e Initial load
duke
parents:
diff changeset
150 assert(count < LIST_CAPACITY-1, "LIST_CAPACITY too small");
a61af66fc99e Initial load
duke
parents:
diff changeset
151 speculative_load_pclist[count++] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
152 __ ld (O5, 0, G2);
a61af66fc99e Initial load
duke
parents:
diff changeset
153
a61af66fc99e Initial load
duke
parents:
diff changeset
154 speculative_load_pclist[count] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
155 __ ld (O5, 4, O3);
a61af66fc99e Initial load
duke
parents:
diff changeset
156 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
157 assert(count < LIST_CAPACITY, "LIST_CAPACITY too small");
a61af66fc99e Initial load
duke
parents:
diff changeset
158 speculative_load_pclist[count] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
159 __ ldx (O5, 0, O3);
a61af66fc99e Initial load
duke
parents:
diff changeset
160 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
161
a61af66fc99e Initial load
duke
parents:
diff changeset
162 __ ld (ca, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
163 __ cmp (G1, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
164 __ br (Assembler::notEqual, false, Assembler::pn, label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
165 __ delayed()->mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
166
a61af66fc99e Initial load
duke
parents:
diff changeset
167 #ifndef _LP64
a61af66fc99e Initial load
duke
parents:
diff changeset
168 __ mov (G2, O0);
a61af66fc99e Initial load
duke
parents:
diff changeset
169 __ retl ();
a61af66fc99e Initial load
duke
parents:
diff changeset
170 __ delayed()->mov (O3, O1);
a61af66fc99e Initial load
duke
parents:
diff changeset
171 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
172 __ retl ();
a61af66fc99e Initial load
duke
parents:
diff changeset
173 __ delayed()->mov (O3, O0);
a61af66fc99e Initial load
duke
parents:
diff changeset
174 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
175
a61af66fc99e Initial load
duke
parents:
diff changeset
176 #ifndef _LP64
a61af66fc99e Initial load
duke
parents:
diff changeset
177 slowcase_entry_pclist[count-1] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
178 slowcase_entry_pclist[count++] = __ pc() ;
a61af66fc99e Initial load
duke
parents:
diff changeset
179 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
180 slowcase_entry_pclist[count++] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
181 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
182
a61af66fc99e Initial load
duke
parents:
diff changeset
183 __ bind (label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
184 __ mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
185
a61af66fc99e Initial load
duke
parents:
diff changeset
186 address slow_case_addr = jni_GetLongField_addr();
a61af66fc99e Initial load
duke
parents:
diff changeset
187 __ bind (label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
188 __ call (slow_case_addr, relocInfo::none);
a61af66fc99e Initial load
duke
parents:
diff changeset
189 __ delayed()->mov (G1, O7);
a61af66fc99e Initial load
duke
parents:
diff changeset
190
a61af66fc99e Initial load
duke
parents:
diff changeset
191 __ flush ();
a61af66fc99e Initial load
duke
parents:
diff changeset
192
a61af66fc99e Initial load
duke
parents:
diff changeset
193 return fast_entry;
a61af66fc99e Initial load
duke
parents:
diff changeset
194 }
a61af66fc99e Initial load
duke
parents:
diff changeset
195
a61af66fc99e Initial load
duke
parents:
diff changeset
196 address JNI_FastGetField::generate_fast_get_float_field0(BasicType type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
197 const char *name;
a61af66fc99e Initial load
duke
parents:
diff changeset
198 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
199 case T_FLOAT: name = "jni_fast_GetFloatField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
200 case T_DOUBLE: name = "jni_fast_GetDoubleField"; break;
a61af66fc99e Initial load
duke
parents:
diff changeset
201 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
202 }
a61af66fc99e Initial load
duke
parents:
diff changeset
203 ResourceMark rm;
a61af66fc99e Initial load
duke
parents:
diff changeset
204 BufferBlob* b = BufferBlob::create(name, BUFFER_SIZE*wordSize);
a61af66fc99e Initial load
duke
parents:
diff changeset
205 address fast_entry = b->instructions_begin();
a61af66fc99e Initial load
duke
parents:
diff changeset
206 CodeBuffer cbuf(fast_entry, b->instructions_size());
a61af66fc99e Initial load
duke
parents:
diff changeset
207 MacroAssembler* masm = new MacroAssembler(&cbuf);
a61af66fc99e Initial load
duke
parents:
diff changeset
208
a61af66fc99e Initial load
duke
parents:
diff changeset
209 Label label1, label2;
a61af66fc99e Initial load
duke
parents:
diff changeset
210
a61af66fc99e Initial load
duke
parents:
diff changeset
211 address cnt_addr = SafepointSynchronize::safepoint_counter_addr();
a61af66fc99e Initial load
duke
parents:
diff changeset
212 Address ca(O3, cnt_addr);
a61af66fc99e Initial load
duke
parents:
diff changeset
213 __ sethi (ca);
a61af66fc99e Initial load
duke
parents:
diff changeset
214 __ ld (ca, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
215 __ andcc (G4, 1, G0);
a61af66fc99e Initial load
duke
parents:
diff changeset
216 __ br (Assembler::notZero, false, Assembler::pn, label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
217 __ delayed()->srl (O2, 2, O4);
a61af66fc99e Initial load
duke
parents:
diff changeset
218 __ ld_ptr (O1, 0, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
219
a61af66fc99e Initial load
duke
parents:
diff changeset
220 assert(count < LIST_CAPACITY, "LIST_CAPACITY too small");
a61af66fc99e Initial load
duke
parents:
diff changeset
221 speculative_load_pclist[count] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
222 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
223 case T_FLOAT: __ ldf (FloatRegisterImpl::S, O5, O4, F0); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
224 case T_DOUBLE: __ ldf (FloatRegisterImpl::D, O5, O4, F0); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
225 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
226 }
a61af66fc99e Initial load
duke
parents:
diff changeset
227
a61af66fc99e Initial load
duke
parents:
diff changeset
228 __ ld (ca, O5);
a61af66fc99e Initial load
duke
parents:
diff changeset
229 __ cmp (O5, G4);
a61af66fc99e Initial load
duke
parents:
diff changeset
230 __ br (Assembler::notEqual, false, Assembler::pn, label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
231 __ delayed()->mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
232
a61af66fc99e Initial load
duke
parents:
diff changeset
233 __ retl ();
a61af66fc99e Initial load
duke
parents:
diff changeset
234 __ delayed()-> nop ();
a61af66fc99e Initial load
duke
parents:
diff changeset
235
a61af66fc99e Initial load
duke
parents:
diff changeset
236 slowcase_entry_pclist[count++] = __ pc();
a61af66fc99e Initial load
duke
parents:
diff changeset
237 __ bind (label1);
a61af66fc99e Initial load
duke
parents:
diff changeset
238 __ mov (O7, G1);
a61af66fc99e Initial load
duke
parents:
diff changeset
239
a61af66fc99e Initial load
duke
parents:
diff changeset
240 address slow_case_addr;
a61af66fc99e Initial load
duke
parents:
diff changeset
241 switch (type) {
a61af66fc99e Initial load
duke
parents:
diff changeset
242 case T_FLOAT: slow_case_addr = jni_GetFloatField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
243 case T_DOUBLE: slow_case_addr = jni_GetDoubleField_addr(); break;
a61af66fc99e Initial load
duke
parents:
diff changeset
244 default: ShouldNotReachHere();
a61af66fc99e Initial load
duke
parents:
diff changeset
245 }
a61af66fc99e Initial load
duke
parents:
diff changeset
246 __ bind (label2);
a61af66fc99e Initial load
duke
parents:
diff changeset
247 __ call (slow_case_addr, relocInfo::none);
a61af66fc99e Initial load
duke
parents:
diff changeset
248 __ delayed()->mov (G1, O7);
a61af66fc99e Initial load
duke
parents:
diff changeset
249
a61af66fc99e Initial load
duke
parents:
diff changeset
250 __ flush ();
a61af66fc99e Initial load
duke
parents:
diff changeset
251
a61af66fc99e Initial load
duke
parents:
diff changeset
252 return fast_entry;
a61af66fc99e Initial load
duke
parents:
diff changeset
253 }
a61af66fc99e Initial load
duke
parents:
diff changeset
254
a61af66fc99e Initial load
duke
parents:
diff changeset
255 address JNI_FastGetField::generate_fast_get_float_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
256 return generate_fast_get_float_field0(T_FLOAT);
a61af66fc99e Initial load
duke
parents:
diff changeset
257 }
a61af66fc99e Initial load
duke
parents:
diff changeset
258
a61af66fc99e Initial load
duke
parents:
diff changeset
259 address JNI_FastGetField::generate_fast_get_double_field() {
a61af66fc99e Initial load
duke
parents:
diff changeset
260 return generate_fast_get_float_field0(T_DOUBLE);
a61af66fc99e Initial load
duke
parents:
diff changeset
261 }