< prev index next >

src/hotspot/share/opto/parse1.cpp

Print this page




1181 }
1182 
1183 //-----------------------------create_entry_map-------------------------------
1184 // Initialize our parser map to contain the types at method entry.
1185 // For OSR, the map contains a single RawPtr parameter.
1186 // Initial monitor locking for sync. methods is performed by do_method_entry.
1187 SafePointNode* Parse::create_entry_map() {
1188   // Check for really stupid bail-out cases.
1189   uint len = TypeFunc::Parms + method()->max_locals() + method()->max_stack();
1190   if (len >= 32760) {
1191     C->record_method_not_compilable("too many local variables");
1192     return NULL;
1193   }
1194 
1195   // clear current replaced nodes that are of no use from here on (map was cloned in build_exits).
1196   _caller->map()->delete_replaced_nodes();
1197 
1198   // If this is an inlined method, we may have to do a receiver null check.
1199   if (_caller->has_method() && is_normal_parse() && !method()->is_static()) {
1200     GraphKit kit(_caller);
1201     kit.null_check_receiver_before_call(method());
1202     _caller = kit.transfer_exceptions_into_jvms();
1203     if (kit.stopped()) {
1204       _exits.add_exception_states_from(_caller);
1205       _exits.set_jvms(_caller);
1206       return NULL;
1207     }
1208   }
1209 
1210   assert(method() != NULL, "parser must have a method");
1211 
1212   // Create an initial safepoint to hold JVM state during parsing
1213   JVMState* jvms = new (C) JVMState(method(), _caller->has_method() ? _caller : NULL);
1214   set_map(new SafePointNode(len, jvms));
1215   jvms->set_map(map());
1216   record_for_igvn(map());
1217   assert(jvms->endoff() == len, "correct jvms sizing");
1218 
1219   SafePointNode* inmap = _caller->map();
1220   assert(inmap != NULL, "must have inmap");
1221   // In case of null check on receiver above




1181 }
1182 
1183 //-----------------------------create_entry_map-------------------------------
1184 // Initialize our parser map to contain the types at method entry.
1185 // For OSR, the map contains a single RawPtr parameter.
1186 // Initial monitor locking for sync. methods is performed by do_method_entry.
1187 SafePointNode* Parse::create_entry_map() {
1188   // Check for really stupid bail-out cases.
1189   uint len = TypeFunc::Parms + method()->max_locals() + method()->max_stack();
1190   if (len >= 32760) {
1191     C->record_method_not_compilable("too many local variables");
1192     return NULL;
1193   }
1194 
1195   // clear current replaced nodes that are of no use from here on (map was cloned in build_exits).
1196   _caller->map()->delete_replaced_nodes();
1197 
1198   // If this is an inlined method, we may have to do a receiver null check.
1199   if (_caller->has_method() && is_normal_parse() && !method()->is_static()) {
1200     GraphKit kit(_caller);
1201     kit.null_check_receiver_before_call(method(), false);
1202     _caller = kit.transfer_exceptions_into_jvms();
1203     if (kit.stopped()) {
1204       _exits.add_exception_states_from(_caller);
1205       _exits.set_jvms(_caller);
1206       return NULL;
1207     }
1208   }
1209 
1210   assert(method() != NULL, "parser must have a method");
1211 
1212   // Create an initial safepoint to hold JVM state during parsing
1213   JVMState* jvms = new (C) JVMState(method(), _caller->has_method() ? _caller : NULL);
1214   set_map(new SafePointNode(len, jvms));
1215   jvms->set_map(map());
1216   record_for_igvn(map());
1217   assert(jvms->endoff() == len, "correct jvms sizing");
1218 
1219   SafePointNode* inmap = _caller->map();
1220   assert(inmap != NULL, "must have inmap");
1221   // In case of null check on receiver above


< prev index next >