comparison src/share/vm/ci/ciInstanceKlass.cpp @ 18041:52b4284cb496

Merge with jdk8u20-b26
author Gilles Duboscq <duboscq@ssw.jku.at>
date Wed, 15 Oct 2014 16:02:50 +0200
parents 096c224171c4 78bbf4d43a14
children
comparison
equal deleted inserted replaced
17606:45d7b2c7029d 18041:52b4284cb496
1 /* 1 /*
2 * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
290 // ciInstanceKlass::print_impl 290 // ciInstanceKlass::print_impl
291 // 291 //
292 // Implementation of the print method. 292 // Implementation of the print method.
293 void ciInstanceKlass::print_impl(outputStream* st) { 293 void ciInstanceKlass::print_impl(outputStream* st) {
294 ciKlass::print_impl(st); 294 ciKlass::print_impl(st);
295 GUARDED_VM_ENTRY(st->print(" loader=0x%x", (address)loader());) 295 GUARDED_VM_ENTRY(st->print(" loader=" INTPTR_FORMAT, p2i((address)loader()));)
296 if (is_loaded()) { 296 if (is_loaded()) {
297 st->print(" loaded=true initialized=%s finalized=%s subklass=%s size=%d flags=", 297 st->print(" loaded=true initialized=%s finalized=%s subklass=%s size=%d flags=",
298 bool_to_str(is_initialized()), 298 bool_to_str(is_initialized()),
299 bool_to_str(has_finalizer()), 299 bool_to_str(has_finalizer()),
300 bool_to_str(has_subklass()), 300 bool_to_str(has_subklass()),
616 case T_BYTE: _out->print_cr("%d", mirror->byte_field(fd->offset())); break; 616 case T_BYTE: _out->print_cr("%d", mirror->byte_field(fd->offset())); break;
617 case T_BOOLEAN: _out->print_cr("%d", mirror->bool_field(fd->offset())); break; 617 case T_BOOLEAN: _out->print_cr("%d", mirror->bool_field(fd->offset())); break;
618 case T_SHORT: _out->print_cr("%d", mirror->short_field(fd->offset())); break; 618 case T_SHORT: _out->print_cr("%d", mirror->short_field(fd->offset())); break;
619 case T_CHAR: _out->print_cr("%d", mirror->char_field(fd->offset())); break; 619 case T_CHAR: _out->print_cr("%d", mirror->char_field(fd->offset())); break;
620 case T_INT: _out->print_cr("%d", mirror->int_field(fd->offset())); break; 620 case T_INT: _out->print_cr("%d", mirror->int_field(fd->offset())); break;
621 case T_LONG: _out->print_cr(INT64_FORMAT, mirror->long_field(fd->offset())); break; 621 case T_LONG: _out->print_cr(INT64_FORMAT, (int64_t)(mirror->long_field(fd->offset()))); break;
622 case T_FLOAT: { 622 case T_FLOAT: {
623 float f = mirror->float_field(fd->offset()); 623 float f = mirror->float_field(fd->offset());
624 _out->print_cr("%d", *(int*)&f); 624 _out->print_cr("%d", *(int*)&f);
625 break; 625 break;
626 } 626 }
627 case T_DOUBLE: { 627 case T_DOUBLE: {
628 double d = mirror->double_field(fd->offset()); 628 double d = mirror->double_field(fd->offset());
629 _out->print_cr(INT64_FORMAT, *(jlong*)&d); 629 _out->print_cr(INT64_FORMAT, *(int64_t*)&d);
630 break; 630 break;
631 } 631 }
632 case T_ARRAY: { 632 case T_ARRAY: {
633 oop value = mirror->obj_field_acquire(fd->offset()); 633 oop value = mirror->obj_field_acquire(fd->offset());
634 if (value == NULL) { 634 if (value == NULL) {
654 _out->print("\""); 654 _out->print("\"");
655 _out->print_raw(java_lang_String::as_quoted_ascii(value)); 655 _out->print_raw(java_lang_String::as_quoted_ascii(value));
656 _out->print_cr("\""); 656 _out->print_cr("\"");
657 } else { 657 } else {
658 const char* klass_name = value->klass()->name()->as_quoted_ascii(); 658 const char* klass_name = value->klass()->name()->as_quoted_ascii();
659 _out->print_cr(klass_name); 659 _out->print_cr("%s", klass_name);
660 } 660 }
661 } else { 661 } else {
662 ShouldNotReachHere(); 662 ShouldNotReachHere();
663 } 663 }
664 break; 664 break;