equal
deleted
inserted
replaced
54 #include "runtime/sharedRuntime.hpp" |
54 #include "runtime/sharedRuntime.hpp" |
55 #include "runtime/signature.hpp" |
55 #include "runtime/signature.hpp" |
56 #include "utilities/quickSort.hpp" |
56 #include "utilities/quickSort.hpp" |
57 #include "utilities/xmlstream.hpp" |
57 #include "utilities/xmlstream.hpp" |
58 |
58 |
|
59 PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC |
59 |
60 |
60 // Implementation of Method |
61 // Implementation of Method |
61 |
62 |
62 Method* Method::allocate(ClassLoaderData* loader_data, |
63 Method* Method::allocate(ClassLoaderData* loader_data, |
63 int byte_code_size, |
64 int byte_code_size, |
1423 outputStream* _st; |
1424 outputStream* _st; |
1424 bool _use_separator; |
1425 bool _use_separator; |
1425 |
1426 |
1426 void type_name(const char* name) { |
1427 void type_name(const char* name) { |
1427 if (_use_separator) _st->print(", "); |
1428 if (_use_separator) _st->print(", "); |
1428 _st->print(name); |
1429 _st->print("%s", name); |
1429 _use_separator = true; |
1430 _use_separator = true; |
1430 } |
1431 } |
1431 |
1432 |
1432 public: |
1433 public: |
1433 SignatureTypePrinter(Symbol* signature, outputStream* st) : SignatureTypeNames(signature) { |
1434 SignatureTypePrinter(Symbol* signature, outputStream* st) : SignatureTypeNames(signature) { |
1896 #ifndef PRODUCT |
1897 #ifndef PRODUCT |
1897 |
1898 |
1898 void Method::print_on(outputStream* st) const { |
1899 void Method::print_on(outputStream* st) const { |
1899 ResourceMark rm; |
1900 ResourceMark rm; |
1900 assert(is_method(), "must be method"); |
1901 assert(is_method(), "must be method"); |
1901 st->print_cr(internal_name()); |
1902 st->print_cr("%s", internal_name()); |
1902 // get the effect of PrintOopAddress, always, for methods: |
1903 // get the effect of PrintOopAddress, always, for methods: |
1903 st->print_cr(" - this oop: "INTPTR_FORMAT, (intptr_t)this); |
1904 st->print_cr(" - this oop: "INTPTR_FORMAT, (intptr_t)this); |
1904 st->print (" - method holder: "); method_holder()->print_value_on(st); st->cr(); |
1905 st->print (" - method holder: "); method_holder()->print_value_on(st); st->cr(); |
1905 st->print (" - constants: "INTPTR_FORMAT" ", (address)constants()); |
1906 st->print (" - constants: "INTPTR_FORMAT" ", (address)constants()); |
1906 constants()->print_value_on(st); st->cr(); |
1907 constants()->print_value_on(st); st->cr(); |
1979 |
1980 |
1980 #endif //PRODUCT |
1981 #endif //PRODUCT |
1981 |
1982 |
1982 void Method::print_value_on(outputStream* st) const { |
1983 void Method::print_value_on(outputStream* st) const { |
1983 assert(is_method(), "must be method"); |
1984 assert(is_method(), "must be method"); |
1984 st->print(internal_name()); |
1985 st->print("%s", internal_name()); |
1985 print_address_on(st); |
1986 print_address_on(st); |
1986 st->print(" "); |
1987 st->print(" "); |
1987 name()->print_value_on(st); |
1988 name()->print_value_on(st); |
1988 st->print(" "); |
1989 st->print(" "); |
1989 signature()->print_value_on(st); |
1990 signature()->print_value_on(st); |