mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8076319: jstat verified class fix
Move verify perf data so that it only counts classes that actually get verified. Reviewed-by: acorn, coleenp, gtriantafill
This commit is contained in:
parent
dc86a0aff2
commit
6a5fa52c18
2 changed files with 12 additions and 8 deletions
|
@ -45,6 +45,8 @@
|
||||||
#include "runtime/javaCalls.hpp"
|
#include "runtime/javaCalls.hpp"
|
||||||
#include "runtime/orderAccess.inline.hpp"
|
#include "runtime/orderAccess.inline.hpp"
|
||||||
#include "runtime/os.hpp"
|
#include "runtime/os.hpp"
|
||||||
|
#include "runtime/thread.hpp"
|
||||||
|
#include "services/threadService.hpp"
|
||||||
#include "utilities/bytes.hpp"
|
#include "utilities/bytes.hpp"
|
||||||
|
|
||||||
#define NOFAILOVER_MAJOR_VERSION 51
|
#define NOFAILOVER_MAJOR_VERSION 51
|
||||||
|
@ -130,6 +132,16 @@ bool Verifier::verify(instanceKlassHandle klass, Verifier::Mode mode, bool shoul
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Timer includes any side effects of class verification (resolution,
|
||||||
|
// etc), but not recursive calls to Verifier::verify().
|
||||||
|
JavaThread* jt = (JavaThread*)THREAD;
|
||||||
|
PerfClassTraceTime timer(ClassLoader::perf_class_verify_time(),
|
||||||
|
ClassLoader::perf_class_verify_selftime(),
|
||||||
|
ClassLoader::perf_classes_verified(),
|
||||||
|
jt->get_thread_stat()->perf_recursion_counts_addr(),
|
||||||
|
jt->get_thread_stat()->perf_timers_addr(),
|
||||||
|
PerfClassTraceTime::CLASS_VERIFY);
|
||||||
|
|
||||||
// If the class should be verified, first see if we can use the split
|
// If the class should be verified, first see if we can use the split
|
||||||
// verifier. If not, or if verification fails and FailOverToOldVerifier
|
// verifier. If not, or if verification fails and FailOverToOldVerifier
|
||||||
// is set, then call the inference verifier.
|
// is set, then call the inference verifier.
|
||||||
|
|
|
@ -622,14 +622,6 @@ bool InstanceKlass::link_class_impl(
|
||||||
if (!this_k->is_linked()) {
|
if (!this_k->is_linked()) {
|
||||||
if (!this_k->is_rewritten()) {
|
if (!this_k->is_rewritten()) {
|
||||||
{
|
{
|
||||||
// Timer includes any side effects of class verification (resolution,
|
|
||||||
// etc), but not recursive entry into verify_code().
|
|
||||||
PerfClassTraceTime timer(ClassLoader::perf_class_verify_time(),
|
|
||||||
ClassLoader::perf_class_verify_selftime(),
|
|
||||||
ClassLoader::perf_classes_verified(),
|
|
||||||
jt->get_thread_stat()->perf_recursion_counts_addr(),
|
|
||||||
jt->get_thread_stat()->perf_timers_addr(),
|
|
||||||
PerfClassTraceTime::CLASS_VERIFY);
|
|
||||||
bool verify_ok = verify_code(this_k, throw_verifyerror, THREAD);
|
bool verify_ok = verify_code(this_k, throw_verifyerror, THREAD);
|
||||||
if (!verify_ok) {
|
if (!verify_ok) {
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue