OpenJDK / valhalla / valhalla10-old / hotspot
comparison src/share/vm/opto/doCall.cpp @ 9462:231763c1883e
8140424: don't prefix developer and notproduct flag variables with CONST_ in product builds
Reviewed-by: goetz, stefank
author | twisti |
---|---|
date | Wed, 11 Nov 2015 16:32:17 -1000 |
parents | dc9930a04ab0 |
children | 9988b390777b |
comparison
equal
deleted
inserted
replaced
70:00f84037b88a | 71:1bee119aa05f |
---|---|
43 | 43 |
44 void trace_type_profile(Compile* C, ciMethod *method, int depth, int bci, ciMethod *prof_method, ciKlass *prof_klass, int site_count, int receiver_count) { | 44 void trace_type_profile(Compile* C, ciMethod *method, int depth, int bci, ciMethod *prof_method, ciKlass *prof_klass, int site_count, int receiver_count) { |
45 if (TraceTypeProfile || C->print_inlining()) { | 45 if (TraceTypeProfile || C->print_inlining()) { |
46 outputStream* out = tty; | 46 outputStream* out = tty; |
47 if (!C->print_inlining()) { | 47 if (!C->print_inlining()) { |
48 if (NOT_PRODUCT(!PrintOpto &&) !PrintCompilation) { | 48 if (!PrintOpto && !PrintCompilation) { |
49 method->print_short_name(); | 49 method->print_short_name(); |
50 tty->cr(); | 50 tty->cr(); |
51 } | 51 } |
52 CompileTask::print_inlining_tty(prof_method, depth, bci); | 52 CompileTask::print_inlining_tty(prof_method, depth, bci); |
53 } else { | 53 } else { |
424 } | 424 } |
425 | 425 |
426 // uncommon-trap when callee is unloaded, uninitialized or will not link | 426 // uncommon-trap when callee is unloaded, uninitialized or will not link |
427 // bailout when too many arguments for register representation | 427 // bailout when too many arguments for register representation |
428 if (!will_link || can_not_compile_call_site(orig_callee, klass)) { | 428 if (!will_link || can_not_compile_call_site(orig_callee, klass)) { |
429 #ifndef PRODUCT | |
430 if (PrintOpto && (Verbose || WizardMode)) { | 429 if (PrintOpto && (Verbose || WizardMode)) { |
431 method()->print_name(); tty->print_cr(" can not compile call at bci %d to:", bci()); | 430 method()->print_name(); tty->print_cr(" can not compile call at bci %d to:", bci()); |
432 orig_callee->print_name(); tty->cr(); | 431 orig_callee->print_name(); tty->cr(); |
433 } | 432 } |
434 #endif | |
435 return; | 433 return; |
436 } | 434 } |
437 assert(holder_klass->is_loaded(), ""); | 435 assert(holder_klass->is_loaded(), ""); |
438 //assert((bc_callee->is_static() || is_invokedynamic) == !has_receiver , "must match bc"); // XXX invokehandle (cur_bc_raw) | 436 //assert((bc_callee->is_static() || is_invokedynamic) == !has_receiver , "must match bc"); // XXX invokehandle (cur_bc_raw) |
439 // Note: this takes into account invokeinterface of methods declared in java/lang/Object, | 437 // Note: this takes into account invokeinterface of methods declared in java/lang/Object, |
632 } | 630 } |
633 | 631 |
634 // If the return type of the method is not loaded, assert that the | 632 // If the return type of the method is not loaded, assert that the |
635 // value we got is a null. Otherwise, we need to recompile. | 633 // value we got is a null. Otherwise, we need to recompile. |
636 if (!rtype->is_loaded()) { | 634 if (!rtype->is_loaded()) { |
637 #ifndef PRODUCT | |
638 if (PrintOpto && (Verbose || WizardMode)) { | 635 if (PrintOpto && (Verbose || WizardMode)) { |
639 method()->print_name(); tty->print_cr(" asserting nullness of result at bci: %d", bci()); | 636 method()->print_name(); tty->print_cr(" asserting nullness of result at bci: %d", bci()); |
640 cg->method()->print_name(); tty->cr(); | 637 cg->method()->print_name(); tty->cr(); |
641 } | 638 } |
642 #endif | |
643 if (C->log() != NULL) { | 639 if (C->log() != NULL) { |
644 C->log()->elem("assert_null reason='return' klass='%d'", | 640 C->log()->elem("assert_null reason='return' klass='%d'", |
645 C->log()->identify(rtype)); | 641 C->log()->identify(rtype)); |
646 } | 642 } |
647 // If there is going to be a trap, put it at the next bytecode: | 643 // If there is going to be a trap, put it at the next bytecode: |
849 // exception handler bci range covers throw_bci => investigate further | 845 // exception handler bci range covers throw_bci => investigate further |
850 int handler_bci = handler->handler_bci(); | 846 int handler_bci = handler->handler_bci(); |
851 | 847 |
852 if (remaining == 1) { | 848 if (remaining == 1) { |
853 push_ex_oop(ex_node); // Push exception oop for handler | 849 push_ex_oop(ex_node); // Push exception oop for handler |
854 #ifndef PRODUCT | |
855 if (PrintOpto && WizardMode) { | 850 if (PrintOpto && WizardMode) { |
856 tty->print_cr(" Catching every inline exception bci:%d -> handler_bci:%d", bci(), handler_bci); | 851 tty->print_cr(" Catching every inline exception bci:%d -> handler_bci:%d", bci(), handler_bci); |
857 } | 852 } |
858 #endif | |
859 merge_exception(handler_bci); // jump to handler | 853 merge_exception(handler_bci); // jump to handler |
860 return; // No more handling to be done here! | 854 return; // No more handling to be done here! |
861 } | 855 } |
862 | 856 |
863 // Get the handler's klass | 857 // Get the handler's klass |
880 PreserveJVMState pjvms(this); | 874 PreserveJVMState pjvms(this); |
881 const TypeInstPtr* tinst = TypeOopPtr::make_from_klass_unique(klass)->cast_to_ptr_type(TypePtr::NotNull)->is_instptr(); | 875 const TypeInstPtr* tinst = TypeOopPtr::make_from_klass_unique(klass)->cast_to_ptr_type(TypePtr::NotNull)->is_instptr(); |
882 assert(klass->has_subklass() || tinst->klass_is_exact(), "lost exactness"); | 876 assert(klass->has_subklass() || tinst->klass_is_exact(), "lost exactness"); |
883 Node* ex_oop = _gvn.transform(new CheckCastPPNode(control(), ex_node, tinst)); | 877 Node* ex_oop = _gvn.transform(new CheckCastPPNode(control(), ex_node, tinst)); |
884 push_ex_oop(ex_oop); // Push exception oop for handler | 878 push_ex_oop(ex_oop); // Push exception oop for handler |
885 #ifndef PRODUCT | |
886 if (PrintOpto && WizardMode) { | 879 if (PrintOpto && WizardMode) { |
887 tty->print(" Catching inline exception bci:%d -> handler_bci:%d -- ", bci(), handler_bci); | 880 tty->print(" Catching inline exception bci:%d -> handler_bci:%d -- ", bci(), handler_bci); |
888 klass->print_name(); | 881 klass->print_name(); |
889 tty->cr(); | 882 tty->cr(); |
890 } | 883 } |
891 #endif | |
892 merge_exception(handler_bci); | 884 merge_exception(handler_bci); |
893 } | 885 } |
894 set_control(not_subtype_ctrl); | 886 set_control(not_subtype_ctrl); |
895 | 887 |
896 // Come here if exception does not match handler. | 888 // Come here if exception does not match handler. |
1065 if (actual_receiver_is_exact) { | 1057 if (actual_receiver_is_exact) { |
1066 // In case of evolution, there is a dependence on every inlined method, since each | 1058 // In case of evolution, there is a dependence on every inlined method, since each |
1067 // such method can be changed when its class is redefined. | 1059 // such method can be changed when its class is redefined. |
1068 ciMethod* exact_method = callee->resolve_invoke(calling_klass, actual_receiver); | 1060 ciMethod* exact_method = callee->resolve_invoke(calling_klass, actual_receiver); |
1069 if (exact_method != NULL) { | 1061 if (exact_method != NULL) { |
1070 #ifndef PRODUCT | |
1071 if (PrintOpto) { | 1062 if (PrintOpto) { |
1072 tty->print(" Calling method via exact type @%d --- ", bci); | 1063 tty->print(" Calling method via exact type @%d --- ", bci); |
1073 exact_method->print_name(); | 1064 exact_method->print_name(); |
1074 tty->cr(); | 1065 tty->cr(); |
1075 } | 1066 } |
1076 #endif | |
1077 return exact_method; | 1067 return exact_method; |
1078 } | 1068 } |
1079 } | 1069 } |
1080 | 1070 |
1081 return NULL; | 1071 return NULL; |