Mercurial > hg > graal-jvmci-8
comparison src/share/vm/runtime/fprofiler.cpp @ 2177:3582bf76420e
6990754: Use native memory and reference counting to implement SymbolTable
Summary: move symbols from permgen into C heap and reference count them
Reviewed-by: never, acorn, jmasa, stefank
author | coleenp |
---|---|
date | Thu, 27 Jan 2011 16:11:27 -0800 |
parents | f95d63e2154a |
children | 1d1603768966 |
comparison
equal
deleted
inserted
replaced
2176:27e4ea99855d | 2177:3582bf76420e |
---|---|
29 #include "interpreter/interpreter.hpp" | 29 #include "interpreter/interpreter.hpp" |
30 #include "memory/allocation.inline.hpp" | 30 #include "memory/allocation.inline.hpp" |
31 #include "memory/universe.inline.hpp" | 31 #include "memory/universe.inline.hpp" |
32 #include "oops/oop.inline.hpp" | 32 #include "oops/oop.inline.hpp" |
33 #include "oops/oop.inline2.hpp" | 33 #include "oops/oop.inline2.hpp" |
34 #include "oops/symbolOop.hpp" | 34 #include "oops/symbol.hpp" |
35 #include "runtime/deoptimization.hpp" | 35 #include "runtime/deoptimization.hpp" |
36 #include "runtime/fprofiler.hpp" | 36 #include "runtime/fprofiler.hpp" |
37 #include "runtime/mutexLocker.hpp" | 37 #include "runtime/mutexLocker.hpp" |
38 #include "runtime/stubCodeGenerator.hpp" | 38 #include "runtime/stubCodeGenerator.hpp" |
39 #include "runtime/stubRoutines.hpp" | 39 #include "runtime/stubRoutines.hpp" |
316 | 316 |
317 virtual void print_method_on(outputStream* st) { | 317 virtual void print_method_on(outputStream* st) { |
318 int limit; | 318 int limit; |
319 int i; | 319 int i; |
320 methodOop m = method(); | 320 methodOop m = method(); |
321 symbolOop k = m->klass_name(); | 321 Symbol* k = m->klass_name(); |
322 // Print the class name with dots instead of slashes | 322 // Print the class name with dots instead of slashes |
323 limit = k->utf8_length(); | 323 limit = k->utf8_length(); |
324 for (i = 0 ; i < limit ; i += 1) { | 324 for (i = 0 ; i < limit ; i += 1) { |
325 char c = (char) k->byte_at(i); | 325 char c = (char) k->byte_at(i); |
326 if (c == '/') { | 326 if (c == '/') { |
329 st->print("%c", c); | 329 st->print("%c", c); |
330 } | 330 } |
331 if (limit > 0) { | 331 if (limit > 0) { |
332 st->print("."); | 332 st->print("."); |
333 } | 333 } |
334 symbolOop n = m->name(); | 334 Symbol* n = m->name(); |
335 limit = n->utf8_length(); | 335 limit = n->utf8_length(); |
336 for (i = 0 ; i < limit ; i += 1) { | 336 for (i = 0 ; i < limit ; i += 1) { |
337 char c = (char) n->byte_at(i); | 337 char c = (char) n->byte_at(i); |
338 st->print("%c", c); | 338 st->print("%c", c); |
339 } | 339 } |
340 if( Verbose ) { | 340 if( Verbose ) { |
341 // Disambiguate overloaded methods | 341 // Disambiguate overloaded methods |
342 symbolOop sig = m->signature(); | 342 Symbol* sig = m->signature(); |
343 sig->print_symbol_on(st); | 343 sig->print_symbol_on(st); |
344 } | 344 } |
345 } | 345 } |
346 | 346 |
347 virtual void print(outputStream* st, int total_ticks) { | 347 virtual void print(outputStream* st, int total_ticks) { |