src/cpu/zero/vm/cppInterpreter_zero.cpp

changeset 8429
8f58998958ca
parent 8402
cc78c97abff8
child 8604
04d83ba48607
child 9669
32bc598624bd
equal deleted inserted replaced
8428:099bdbf208bc 8429:8f58998958ca
218 stack->set_sp(stack->sp() + method->max_locals()); 218 stack->set_sp(stack->sp() + method->max_locals());
219 219
220 // Push our result 220 // Push our result
221 for (int i = 0; i < result_slots; i++) { 221 for (int i = 0; i < result_slots; i++) {
222 // Adjust result to smaller 222 // Adjust result to smaller
223 intptr_t res = result[-i]; 223 union {
224 intptr_t res;
225 jint res_jint;
226 };
227 res = result[-i];
224 if (result_slots == 1) { 228 if (result_slots == 1) {
225 res = narrow(method->result_type(), res); 229 BasicType t = method->result_type();
230 if (is_subword_type(t)) {
231 res_jint = (jint)narrow(t, res_jint);
232 }
226 } 233 }
227 stack->push(res); 234 stack->push(res);
228 } 235 }
229 } 236 }
230 237

mercurial