Mercurial > hg > graal-jvmci-8
comparison src/share/vm/oops/methodCounters.hpp @ 20457:631667807de7
8058184: Move _highest_comp_level and _highest_osr_comp_level from MethodData to MethodCounters
Summary: Tiered policy requires highest compilation levels always available
Reviewed-by: kvn, vlivanov
author | iveresov |
---|---|
date | Thu, 11 Sep 2014 12:18:26 -0700 |
parents | aeaca88565e6 |
children | 7848fc12602b |
comparison
equal
deleted
inserted
replaced
20455:07f629123254 | 20457:631667807de7 |
---|---|
37 InvocationCounter _invocation_counter; // Incremented before each activation of the method - used to trigger frequency-based optimizations | 37 InvocationCounter _invocation_counter; // Incremented before each activation of the method - used to trigger frequency-based optimizations |
38 InvocationCounter _backedge_counter; // Incremented before each backedge taken - used to trigger frequencey-based optimizations | 38 InvocationCounter _backedge_counter; // Incremented before each backedge taken - used to trigger frequencey-based optimizations |
39 | 39 |
40 #ifdef TIERED | 40 #ifdef TIERED |
41 float _rate; // Events (invocation and backedge counter increments) per millisecond | 41 float _rate; // Events (invocation and backedge counter increments) per millisecond |
42 u1 _highest_comp_level; // Highest compile level this method has ever seen. | |
43 u1 _highest_osr_comp_level; // Same for OSR level | |
42 jlong _prev_time; // Previous time the rate was acquired | 44 jlong _prev_time; // Previous time the rate was acquired |
43 #endif | 45 #endif |
44 | 46 |
45 MethodCounters() : _interpreter_invocation_count(0), | 47 MethodCounters() : _interpreter_invocation_count(0), |
46 _interpreter_throwout_count(0), | 48 _interpreter_throwout_count(0), |
47 _number_of_breakpoints(0) | 49 _number_of_breakpoints(0) |
48 #ifdef TIERED | 50 #ifdef TIERED |
49 , _rate(0), | 51 , _rate(0), |
52 _highest_comp_level(0), | |
53 _highest_osr_comp_level(0), | |
50 _prev_time(0) | 54 _prev_time(0) |
51 #endif | 55 #endif |
52 { | 56 { |
53 invocation_counter()->init(); | 57 invocation_counter()->init(); |
54 backedge_counter()->init(); | 58 backedge_counter()->init(); |
98 void set_prev_time(jlong time) { _prev_time = time; } | 102 void set_prev_time(jlong time) { _prev_time = time; } |
99 float rate() const { return _rate; } | 103 float rate() const { return _rate; } |
100 void set_rate(float rate) { _rate = rate; } | 104 void set_rate(float rate) { _rate = rate; } |
101 #endif | 105 #endif |
102 | 106 |
107 int highest_comp_level() const; | |
108 void set_highest_comp_level(int level); | |
109 int highest_osr_comp_level() const; | |
110 void set_highest_osr_comp_level(int level); | |
111 | |
103 // invocation counter | 112 // invocation counter |
104 InvocationCounter* invocation_counter() { return &_invocation_counter; } | 113 InvocationCounter* invocation_counter() { return &_invocation_counter; } |
105 InvocationCounter* backedge_counter() { return &_backedge_counter; } | 114 InvocationCounter* backedge_counter() { return &_backedge_counter; } |
106 | 115 |
107 static ByteSize interpreter_invocation_counter_offset() { | 116 static ByteSize interpreter_invocation_counter_offset() { |