src/cpu/x86/vm/c1_LIRGenerator_x86.cpp

changeset 2344
ac637b7220d1
parent 2314
f95d63e2154a
child 2347
0cb042fd2d4b
equal deleted inserted replaced
2314:f95d63e2154a 2344:ac637b7220d1
1149 stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); 1149 stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception);
1150 } else { 1150 } else {
1151 stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); 1151 stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception);
1152 } 1152 }
1153 LIR_Opr reg = rlock_result(x); 1153 LIR_Opr reg = rlock_result(x);
1154 LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
1155 if (!x->klass()->is_loaded() || UseCompressedOops) {
1156 tmp3 = new_register(objectType);
1157 }
1154 __ checkcast(reg, obj.result(), x->klass(), 1158 __ checkcast(reg, obj.result(), x->klass(),
1155 new_register(objectType), new_register(objectType), 1159 new_register(objectType), new_register(objectType), tmp3,
1156 !x->klass()->is_loaded() ? new_register(objectType) : LIR_OprFact::illegalOpr,
1157 x->direct_compare(), info_for_exception, patching_info, stub, 1160 x->direct_compare(), info_for_exception, patching_info, stub,
1158 x->profiled_method(), x->profiled_bci()); 1161 x->profiled_method(), x->profiled_bci());
1159 } 1162 }
1160 1163
1161 1164
1168 if ((!x->klass()->is_loaded() || PatchALot)) { 1171 if ((!x->klass()->is_loaded() || PatchALot)) {
1169 // must do this before locking the destination register as an oop register 1172 // must do this before locking the destination register as an oop register
1170 patching_info = state_for(x, x->state_before()); 1173 patching_info = state_for(x, x->state_before());
1171 } 1174 }
1172 obj.load_item(); 1175 obj.load_item();
1176 LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
1177 if (!x->klass()->is_loaded() || UseCompressedOops) {
1178 tmp3 = new_register(objectType);
1179 }
1173 __ instanceof(reg, obj.result(), x->klass(), 1180 __ instanceof(reg, obj.result(), x->klass(),
1174 new_register(objectType), new_register(objectType), 1181 new_register(objectType), new_register(objectType), tmp3,
1175 !x->klass()->is_loaded() ? new_register(objectType) : LIR_OprFact::illegalOpr,
1176 x->direct_compare(), patching_info, x->profiled_method(), x->profiled_bci()); 1182 x->direct_compare(), patching_info, x->profiled_method(), x->profiled_bci());
1177 } 1183 }
1178 1184
1179 1185
1180 void LIRGenerator::do_If(If* x) { 1186 void LIRGenerator::do_If(If* x) {

mercurial