comparison src/share/vm/ci/ciCallProfile.hpp @ 4137:04b9a2566eec

Merge with hsx23/hotspot.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Sat, 17 Dec 2011 21:40:27 +0100
parents be4ca325525a c26de9aef2ed
children b8f261ba79c6
comparison
equal deleted inserted replaced
3737:9dc19b7d89a3 4137:04b9a2566eec
78 } 78 }
79 ciKlass* receiver(int i) { 79 ciKlass* receiver(int i) {
80 assert(i < _limit, "out of Call Profile MorphismLimit"); 80 assert(i < _limit, "out of Call Profile MorphismLimit");
81 return _receiver[i]; 81 return _receiver[i];
82 } 82 }
83
84 // Rescale the current profile based on the incoming scale
85 ciCallProfile rescale(double scale) {
86 assert(scale >= 0 && scale <= 1.0, "out of range");
87 ciCallProfile call = *this;
88 call._count = (int)(call._count * scale);
89 for (int i = 0; i < _morphism; i++) {
90 call._receiver_count[i] = (int)(call._receiver_count[i] * scale);
91 }
92 return call;
93 }
83 }; 94 };
84 95
85 #endif // SHARE_VM_CI_CICALLPROFILE_HPP 96 #endif // SHARE_VM_CI_CICALLPROFILE_HPP