< prev index next >

src/hotspot/share/ci/ciInstanceKlass.cpp

Print this page




 648           if (value == NULL) {
 649             _out->print_cr("null");
 650           } else {
 651             typeArrayOop ta = (typeArrayOop)value;
 652             _out->print("%d", ta->length());
 653             if (value->is_objArray()) {
 654               objArrayOop oa = (objArrayOop)value;
 655               const char* klass_name  = value->klass()->name()->as_quoted_ascii();
 656               _out->print(" %s", klass_name);
 657             }
 658             _out->cr();
 659           }
 660           break;
 661         }
 662         case T_OBJECT: {
 663           oop value =  mirror->obj_field_acquire(fd->offset());
 664           if (value == NULL) {
 665             _out->print_cr("null");
 666           } else if (value->is_instance()) {
 667             if (value->is_a(SystemDictionary::String_klass())) {
 668               _out->print("\"");
 669               _out->print_raw(java_lang_String::as_quoted_ascii(value));
 670               _out->print_cr("\"");
 671             } else {
 672               const char* klass_name  = value->klass()->name()->as_quoted_ascii();
 673               _out->print_cr("%s", klass_name);
 674             }
 675           } else {
 676             ShouldNotReachHere();
 677           }
 678           break;
 679         }
 680         default:
 681           ShouldNotReachHere();
 682         }
 683     }
 684   }
 685 };
 686 
 687 
 688 void ciInstanceKlass::dump_replay_data(outputStream* out) {
 689   ResourceMark rm;
 690 




 648           if (value == NULL) {
 649             _out->print_cr("null");
 650           } else {
 651             typeArrayOop ta = (typeArrayOop)value;
 652             _out->print("%d", ta->length());
 653             if (value->is_objArray()) {
 654               objArrayOop oa = (objArrayOop)value;
 655               const char* klass_name  = value->klass()->name()->as_quoted_ascii();
 656               _out->print(" %s", klass_name);
 657             }
 658             _out->cr();
 659           }
 660           break;
 661         }
 662         case T_OBJECT: {
 663           oop value =  mirror->obj_field_acquire(fd->offset());
 664           if (value == NULL) {
 665             _out->print_cr("null");
 666           } else if (value->is_instance()) {
 667             if (value->is_a(SystemDictionary::String_klass())) {
 668               const char* ascii_value = java_lang_String::as_quoted_ascii(value);
 669               _out->print("\"%s\"", (ascii_value != NULL) ? ascii_value : "");

 670             } else {
 671               const char* klass_name  = value->klass()->name()->as_quoted_ascii();
 672               _out->print_cr("%s", klass_name);
 673             }
 674           } else {
 675             ShouldNotReachHere();
 676           }
 677           break;
 678         }
 679         default:
 680           ShouldNotReachHere();
 681         }
 682     }
 683   }
 684 };
 685 
 686 
 687 void ciInstanceKlass::dump_replay_data(outputStream* out) {
 688   ResourceMark rm;
 689 


< prev index next >