mirror of
https://github.com/openjdk/jdk.git
synced 2026-01-28 12:09:14 +00:00
8315488: Remove outdated and unused ciReplay support from SA
Reviewed-by: kvn, cjplummer, yzheng
This commit is contained in:
parent
4109c73a78
commit
8b0468faf1
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2014, Red Hat Inc. All rights reserved. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,17 +30,17 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
volatile_nonstatic_field(JavaFrameAnchor, _last_Java_fp, intptr_t*) \
|
||||
static_field(VM_Version, _rop_protection, bool) \
|
||||
static_field(VM_Version, _pac_mask, uintptr_t)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
declare_toplevel_type(VM_Version)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define DECLARE_INT_CPU_FEATURE_CONSTANT(id, name, bit) GENERATE_VM_INT_CONSTANT_ENTRY(VM_Version::CPU_##id)
|
||||
#define VM_INT_CPU_FEATURE_CONSTANTS CPU_FEATURE_FLAGS(DECLARE_INT_CPU_FEATURE_CONSTANT)
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2008, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2008, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,7 +29,7 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
\
|
||||
/******************************/ \
|
||||
/* JavaCallWrapper */ \
|
||||
@ -39,10 +39,10 @@
|
||||
/******************************/ \
|
||||
volatile_nonstatic_field(JavaFrameAnchor, _last_Java_fp, intptr_t*)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // CPU_ARM_VMSTRUCTS_ARM_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2013 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // CPU_PPC_VMSTRUCTS_PPC_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2020, 2021, Huawei Technologies Co., Ltd. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,13 +30,13 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
volatile_nonstatic_field(JavaFrameAnchor, _last_Java_fp, intptr_t*)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // CPU_RISCV_VMSTRUCTS_RISCV_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2016, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2016 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // CPU_S390_VMSTRUCTS_S390_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,17 +29,17 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
volatile_nonstatic_field(JavaFrameAnchor, _last_Java_fp, intptr_t*)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant) \
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant) \
|
||||
LP64_ONLY(declare_constant(frame::arg_reg_save_area_bytes)) \
|
||||
declare_constant(frame::interpreter_frame_sender_sp_offset) \
|
||||
declare_constant(frame::interpreter_frame_last_sp_offset)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define DECLARE_LONG_CPU_FEATURE_CONSTANT(id, name, bit) GENERATE_VM_LONG_CONSTANT_ENTRY(VM_Version::CPU_##id)
|
||||
#define VM_LONG_CPU_FEATURE_CONSTANTS CPU_FEATURE_FLAGS(DECLARE_LONG_CPU_FEATURE_CONSTANT)
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright 2007 Red Hat, Inc.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // CPU_ZERO_VMSTRUCTS_ZERO_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,14 +29,14 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
\
|
||||
/******************************/ \
|
||||
/* Threads (NOTE: incomplete) */ \
|
||||
/******************************/ \
|
||||
nonstatic_field(OSThread, _thread_id, pthread_t) \
|
||||
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
\
|
||||
/**********************/ \
|
||||
/* Posix Thread IDs */ \
|
||||
@ -44,9 +44,9 @@
|
||||
\
|
||||
declare_unsigned_integer_type(pthread_t)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_ADDRESSES_OS(declare_address, declare_preprocessor_address, declare_function)
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -31,7 +31,7 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
\
|
||||
/******************************/ \
|
||||
/* Threads (NOTE: incomplete) */ \
|
||||
@ -39,7 +39,7 @@
|
||||
nonstatic_field(OSThread, _thread_id, OSThread::thread_id_t) \
|
||||
nonstatic_field(OSThread, _unique_thread_id, uint64_t)
|
||||
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
\
|
||||
/**********************/ \
|
||||
/* Thread IDs */ \
|
||||
@ -47,9 +47,9 @@
|
||||
\
|
||||
declare_unsigned_integer_type(OSThread::thread_id_t)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_ADDRESSES_OS(declare_address, declare_preprocessor_address, declare_function) \
|
||||
declare_preprocessor_address("RTLD_DEFAULT", RTLD_DEFAULT)
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -31,7 +31,7 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
\
|
||||
/******************************/ \
|
||||
/* Threads (NOTE: incomplete) */ \
|
||||
@ -39,7 +39,7 @@
|
||||
nonstatic_field(OSThread, _thread_id, pid_t) \
|
||||
nonstatic_field(OSThread, _pthread_id, pthread_t)
|
||||
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
\
|
||||
/**********************/ \
|
||||
/* Posix Thread IDs */ \
|
||||
@ -48,9 +48,9 @@
|
||||
declare_integer_type(pid_t) \
|
||||
declare_unsigned_integer_type(pthread_t)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_ADDRESSES_OS(declare_address, declare_preprocessor_address, declare_function) \
|
||||
declare_preprocessor_address("RTLD_DEFAULT", RTLD_DEFAULT)
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2015, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2015, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,7 +29,7 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_OS(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
\
|
||||
/******************************/ \
|
||||
/* Threads (NOTE: incomplete) */ \
|
||||
@ -38,13 +38,13 @@
|
||||
nonstatic_field(OSThread, _thread_id, OSThread::thread_id_t) \
|
||||
unchecked_nonstatic_field(OSThread, _thread_handle, sizeof(HANDLE)) /* NOTE: no type */
|
||||
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type) \
|
||||
#define VM_TYPES_OS(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type) \
|
||||
\
|
||||
declare_unsigned_integer_type(OSThread::thread_id_t)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_ADDRESSES_OS(declare_address, declare_preprocessor_address, declare_function)
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2013 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_AIX_PPC_VMSTRUCTS_AIX_PPC_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2014, Red Hat Inc. All rights reserved.
|
||||
* Copyright (c) 2021, Azul Systems, Inc. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
@ -31,12 +31,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_BSD_AARCH64_VMSTRUCTS_BSD_AARCH64_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,12 +29,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_BSD_X86_VMSTRUCTS_BSD_X86_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright 2007 Red Hat, Inc.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,13 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_BSD_ZERO_VMSTRUCTS_BSD_ZERO_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2014, Red Hat Inc. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_AARCH64_VMSTRUCTS_LINUX_AARCH64_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2008, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2008, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,12 +29,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_ARM_VMSTRUCTS_LINUX_ARM_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2013 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_PPC_VMSTRUCTS_LINUX_PPC_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2020, 2021, Huawei Technologies Co., Ltd. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_RISCV_VM_VMSTRUCTS_LINUX_RISCV_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2016, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2016 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_S390_VMSTRUCTS_LINUX_S390_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,12 +29,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_X86_VMSTRUCTS_LINUX_X86_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright 2007 Red Hat, Inc.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
@ -30,12 +30,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_LINUX_ZERO_VMSTRUCTS_LINUX_ZERO_HPP
|
||||
|
||||
@ -29,12 +29,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_WINDOWS_AARCH64_VMSTRUCTS_WINDOWS_AARCH64_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,12 +29,12 @@
|
||||
// constants required by the Serviceability Agent. This file is
|
||||
// referenced by vmStructs.cpp.
|
||||
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_OS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type, declare_c1_toplevel_type, declare_c2_type, declare_c2_toplevel_type)
|
||||
#define VM_TYPES_OS_CPU(declare_type, declare_toplevel_type, declare_oop_type, declare_integer_type, declare_unsigned_integer_type)
|
||||
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_OS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
|
||||
#endif // OS_CPU_WINDOWS_X86_VMSTRUCTS_WINDOWS_X86_HPP
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1999, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1999, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -53,7 +53,6 @@ enum class C1StubId :int {
|
||||
#undef C1_STUB_ID_ENUM_DECLARE
|
||||
|
||||
class Runtime1: public AllStatic {
|
||||
friend class VMStructs;
|
||||
friend class ArrayCopyStub;
|
||||
|
||||
public:
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1999, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1999, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -75,13 +75,11 @@ class ciTypeArrayKlass;
|
||||
// Everyone gives access to ciObjectFactory
|
||||
#define CI_PACKAGE_ACCESS \
|
||||
friend class ciObjectFactory; \
|
||||
friend class VMStructs;
|
||||
|
||||
// These are the packages that have access to ciEnv
|
||||
// Any more access must be given explicitly.
|
||||
#define CI_PACKAGE_ACCESS_TO \
|
||||
friend class ciObjectFactory; \
|
||||
friend class VMStructs; \
|
||||
friend class ciCallSite; \
|
||||
friend class ciConstantPoolCache; \
|
||||
friend class ciField; \
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1999, 2023, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1999, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -32,7 +32,6 @@
|
||||
//
|
||||
// This class represents a constant value.
|
||||
class ciConstant {
|
||||
friend class VMStructs;
|
||||
private:
|
||||
friend class ciEnv;
|
||||
friend class ciField;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1999, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1999, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -37,7 +37,6 @@
|
||||
// which ensures that for each oop, at most one ciObject is created.
|
||||
// This invariant allows efficient implementation of ciObject.
|
||||
class ciObjectFactory : public ArenaObj {
|
||||
friend class VMStructs;
|
||||
friend class ciEnv;
|
||||
|
||||
private:
|
||||
|
||||
@ -943,7 +943,7 @@
|
||||
|
||||
#ifdef AARCH64
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
static_field(VM_Version, _zva_length, int) \
|
||||
static_field(StubRoutines::aarch64, _count_positives, address) \
|
||||
static_field(StubRoutines::aarch64, _count_positives_long, address) \
|
||||
@ -957,11 +957,11 @@
|
||||
|
||||
#ifdef X86
|
||||
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field) \
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field) \
|
||||
volatile_nonstatic_field(JavaFrameAnchor, _last_Java_fp, intptr_t*) \
|
||||
static_field(VM_Version, _has_intel_jcc_erratum, bool)
|
||||
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant) \
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant) \
|
||||
LP64_ONLY(declare_constant(frame::arg_reg_save_area_bytes)) \
|
||||
declare_constant(frame::interpreter_frame_sender_sp_offset) \
|
||||
declare_constant(frame::interpreter_frame_last_sp_offset)
|
||||
@ -975,15 +975,15 @@
|
||||
* Dummy defines for architectures that don't use these.
|
||||
*/
|
||||
#ifndef VM_STRUCTS_CPU
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field, c2_nonstatic_field, unchecked_c1_static_field, unchecked_c2_static_field)
|
||||
#define VM_STRUCTS_CPU(nonstatic_field, static_field, unchecked_nonstatic_field, volatile_nonstatic_field, nonproduct_nonstatic_field)
|
||||
#endif
|
||||
|
||||
#ifndef VM_INT_CONSTANTS_CPU
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_INT_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
#endif
|
||||
|
||||
#ifndef VM_LONG_CONSTANTS_CPU
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant, declare_c1_constant, declare_c2_constant, declare_c2_preprocessor_constant)
|
||||
#define VM_LONG_CONSTANTS_CPU(declare_constant, declare_preprocessor_constant)
|
||||
#endif
|
||||
|
||||
#ifndef VM_ADDRESSES_OS
|
||||
@ -1010,10 +1010,7 @@ VMStructEntry JVMCIVMStructs::localHotSpotVMStructs[] = {
|
||||
GENERATE_STATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_UNCHECKED_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_NONPRODUCT_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_C2_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_C1_UNCHECKED_STATIC_VM_STRUCT_ENTRY,
|
||||
GENERATE_C2_UNCHECKED_STATIC_VM_STRUCT_ENTRY)
|
||||
GENERATE_NONPRODUCT_NONSTATIC_VM_STRUCT_ENTRY)
|
||||
|
||||
#if INCLUDE_G1GC
|
||||
VM_STRUCTS_JVMCI_G1GC(GENERATE_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
@ -1038,10 +1035,7 @@ VMIntConstantEntry JVMCIVMStructs::localHotSpotVMIntConstants[] = {
|
||||
GENERATE_PREPROCESSOR_VM_INT_CONSTANT_ENTRY)
|
||||
|
||||
VM_INT_CONSTANTS_CPU(GENERATE_VM_INT_CONSTANT_ENTRY,
|
||||
GENERATE_PREPROCESSOR_VM_INT_CONSTANT_ENTRY,
|
||||
GENERATE_C1_VM_INT_CONSTANT_ENTRY,
|
||||
GENERATE_C2_VM_INT_CONSTANT_ENTRY,
|
||||
GENERATE_C2_PREPROCESSOR_VM_INT_CONSTANT_ENTRY)
|
||||
GENERATE_PREPROCESSOR_VM_INT_CONSTANT_ENTRY)
|
||||
|
||||
#if INCLUDE_G1GC
|
||||
VM_INT_CONSTANTS_JVMCI_G1GC(GENERATE_VM_INT_CONSTANT_ENTRY,
|
||||
@ -1064,10 +1058,7 @@ VMLongConstantEntry JVMCIVMStructs::localHotSpotVMLongConstants[] = {
|
||||
GENERATE_PREPROCESSOR_VM_LONG_CONSTANT_ENTRY)
|
||||
|
||||
VM_LONG_CONSTANTS_CPU(GENERATE_VM_LONG_CONSTANT_ENTRY,
|
||||
GENERATE_PREPROCESSOR_VM_LONG_CONSTANT_ENTRY,
|
||||
GENERATE_C1_VM_LONG_CONSTANT_ENTRY,
|
||||
GENERATE_C2_VM_LONG_CONSTANT_ENTRY,
|
||||
GENERATE_C2_PREPROCESSOR_VM_LONG_CONSTANT_ENTRY)
|
||||
GENERATE_PREPROCESSOR_VM_LONG_CONSTANT_ENTRY)
|
||||
#ifdef VM_LONG_CPU_FEATURE_CONSTANTS
|
||||
VM_LONG_CPU_FEATURE_CONSTANTS
|
||||
#endif
|
||||
@ -1123,10 +1114,7 @@ void JVMCIVMStructs::init() {
|
||||
CHECK_STATIC_VM_STRUCT_ENTRY,
|
||||
CHECK_NO_OP,
|
||||
CHECK_VOLATILE_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
CHECK_NONPRODUCT_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
CHECK_C2_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
CHECK_NO_OP,
|
||||
CHECK_NO_OP);
|
||||
CHECK_NONPRODUCT_NONSTATIC_VM_STRUCT_ENTRY)
|
||||
|
||||
#if INCLUDE_G1GC
|
||||
VM_STRUCTS_JVMCI_G1GC(CHECK_NONSTATIC_VM_STRUCT_ENTRY,
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -47,7 +47,6 @@ struct Tarjan;
|
||||
// Note that the constructor just zeros things, and since I use Arena
|
||||
// allocation I do not need a destructor to reclaim storage.
|
||||
class Block_Array : public ArenaObj {
|
||||
friend class VMStructs;
|
||||
uint _size; // allocated size, as opposed to formal limit
|
||||
debug_only(uint _limit;) // limit to formal domain
|
||||
Arena *_arena; // Arena to allocate in
|
||||
@ -75,7 +74,6 @@ public:
|
||||
|
||||
|
||||
class Block_List : public Block_Array {
|
||||
friend class VMStructs;
|
||||
public:
|
||||
uint _cnt;
|
||||
Block_List() : Block_List(Thread::current()->resource_area()) { }
|
||||
@ -93,7 +91,6 @@ public:
|
||||
|
||||
|
||||
class CFGElement : public AnyObj {
|
||||
friend class VMStructs;
|
||||
public:
|
||||
double _freq; // Execution frequency (estimate)
|
||||
|
||||
@ -109,7 +106,6 @@ class CFGElement : public AnyObj {
|
||||
// Basic blocks are used during the output routines, and are not used during
|
||||
// any optimization pass. They are created late in the game.
|
||||
class Block : public CFGElement {
|
||||
friend class VMStructs;
|
||||
|
||||
private:
|
||||
// Nodes in this block, in order
|
||||
@ -372,7 +368,6 @@ public:
|
||||
//------------------------------PhaseCFG---------------------------------------
|
||||
// Build an array of Basic Block pointers, one per Node.
|
||||
class PhaseCFG : public Phase {
|
||||
friend class VMStructs;
|
||||
private:
|
||||
// Root of whole program
|
||||
RootNode* _root;
|
||||
@ -703,7 +698,6 @@ public:
|
||||
|
||||
//------------------------------CFGLoop-------------------------------------------
|
||||
class CFGLoop : public CFGElement {
|
||||
friend class VMStructs;
|
||||
int _id;
|
||||
int _depth;
|
||||
CFGLoop *_parent; // root of loop tree is the method level "pseudo" loop, it's parent is null
|
||||
@ -756,7 +750,6 @@ class CFGLoop : public CFGElement {
|
||||
// A edge between two basic blocks that will be embodied by a branch or a
|
||||
// fall-through.
|
||||
class CFGEdge : public ResourceObj {
|
||||
friend class VMStructs;
|
||||
private:
|
||||
Block * _from; // Source basic block
|
||||
Block * _to; // Destination basic block
|
||||
@ -892,7 +885,6 @@ class Trace : public ResourceObj {
|
||||
//------------------------------PhaseBlockLayout-------------------------------
|
||||
// Rearrange blocks into some canonical order, based on edges and their frequencies
|
||||
class PhaseBlockLayout : public Phase {
|
||||
friend class VMStructs;
|
||||
PhaseCFG &_cfg; // Control flow graph
|
||||
|
||||
GrowableArray<CFGEdge *> *edges;
|
||||
|
||||
@ -198,7 +198,6 @@ public:
|
||||
// This provides a way to map the optimized program back into the interpreter,
|
||||
// or to let the GC mark the stack.
|
||||
class JVMState : public ResourceObj {
|
||||
friend class VMStructs;
|
||||
public:
|
||||
typedef enum {
|
||||
Reexecute_Undefined = -1, // not defined -- will be translated into false later
|
||||
@ -331,7 +330,6 @@ public:
|
||||
class SafePointNode : public MultiNode {
|
||||
friend JVMState;
|
||||
friend class GraphKit;
|
||||
friend class VMStructs;
|
||||
|
||||
virtual bool cmp( const Node &n ) const;
|
||||
virtual uint size_of() const; // Size is bigger
|
||||
@ -672,7 +670,6 @@ class CallGenerator;
|
||||
// Call nodes now subsume the function of debug nodes at callsites, so they
|
||||
// contain the functionality of a full scope chain of debug nodes.
|
||||
class CallNode : public SafePointNode {
|
||||
friend class VMStructs;
|
||||
|
||||
protected:
|
||||
bool may_modify_arraycopy_helper(const TypeOopPtr* dest_t, const TypeOopPtr* t_oop, PhaseValues* phase);
|
||||
@ -760,7 +757,6 @@ public:
|
||||
// convention. (The "Java" calling convention is the compiler's calling
|
||||
// convention, as opposed to the interpreter's or that of native C.)
|
||||
class CallJavaNode : public CallNode {
|
||||
friend class VMStructs;
|
||||
protected:
|
||||
virtual bool cmp( const Node &n ) const;
|
||||
virtual uint size_of() const; // Size is bigger
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -47,7 +47,6 @@ class PhaseChaitin;
|
||||
//------------------------------LRG--------------------------------------------
|
||||
// Live-RanGe structure.
|
||||
class LRG : public ResourceObj {
|
||||
friend class VMStructs;
|
||||
public:
|
||||
static const uint AllStack_size = 0xFFFFF; // This mask size is used to tell that the mask of this LRG supports stack positions
|
||||
enum { SPILL_REG=29999 }; // Register number of a spilled LRG
|
||||
@ -236,7 +235,6 @@ public:
|
||||
// abstract! It needs abstraction so I can fiddle with the implementation to
|
||||
// get even more speed.
|
||||
class PhaseIFG : public Phase {
|
||||
friend class VMStructs;
|
||||
// Current implementation: a triangular adjacency list.
|
||||
|
||||
// Array of adjacency-lists, indexed by live-range number
|
||||
@ -417,7 +415,6 @@ public:
|
||||
//------------------------------Chaitin----------------------------------------
|
||||
// Briggs-Chaitin style allocation, mostly.
|
||||
class PhaseChaitin : public PhaseRegAlloc {
|
||||
friend class VMStructs;
|
||||
|
||||
int _trip_cnt;
|
||||
int _alternate;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -175,7 +175,6 @@ class CloneMap {
|
||||
|
||||
class Options {
|
||||
friend class Compile;
|
||||
friend class VMStructs;
|
||||
private:
|
||||
const bool _subsume_loads; // Load can be matched as part of a larger op.
|
||||
const bool _do_escape_analysis; // Do escape analysis.
|
||||
@ -222,7 +221,6 @@ class Options {
|
||||
// This class defines a top-level Compiler invocation.
|
||||
|
||||
class Compile : public Phase {
|
||||
friend class VMStructs;
|
||||
|
||||
public:
|
||||
// Fixed alias indexes. (See also MergeMemNode.)
|
||||
|
||||
@ -241,7 +241,6 @@ typedef ResizeableResourceHashtable<Node*, Node*, AnyObj::RESOURCE_AREA, mtCompi
|
||||
// whenever I have phase-specific information.
|
||||
|
||||
class Node {
|
||||
friend class VMStructs;
|
||||
|
||||
// Lots of restrictions on cloning Nodes
|
||||
NONCOPYABLE(Node);
|
||||
@ -1619,7 +1618,6 @@ class SimpleDUIterator : public StackObj {
|
||||
// Note that the constructor just zeros things, and since I use Arena
|
||||
// allocation I do not need a destructor to reclaim storage.
|
||||
class Node_Array : public AnyObj {
|
||||
friend class VMStructs;
|
||||
protected:
|
||||
Arena* _a; // Arena to allocate in
|
||||
uint _max;
|
||||
@ -1664,7 +1662,6 @@ public:
|
||||
};
|
||||
|
||||
class Node_List : public Node_Array {
|
||||
friend class VMStructs;
|
||||
uint _cnt;
|
||||
public:
|
||||
Node_List(uint max = OptoNodeListSize) : Node_Array(Thread::current()->resource_area(), max), _cnt(0) {}
|
||||
@ -1731,7 +1728,6 @@ void Node::visit_uses(Callback callback, Check is_boundary) const {
|
||||
|
||||
//------------------------------Unique_Node_List-------------------------------
|
||||
class Unique_Node_List : public Node_List {
|
||||
friend class VMStructs;
|
||||
VectorSet _in_worklist;
|
||||
uint _clock_index; // Index in list where to pop from next
|
||||
public:
|
||||
@ -1871,7 +1867,6 @@ inline void Compile::remove_for_igvn(Node* n) {
|
||||
|
||||
//------------------------------Node_Stack-------------------------------------
|
||||
class Node_Stack {
|
||||
friend class VMStructs;
|
||||
protected:
|
||||
struct INode {
|
||||
Node *node; // Processed node
|
||||
@ -1947,7 +1942,6 @@ public:
|
||||
// Debugging or profiling annotations loosely and sparsely associated
|
||||
// with some nodes. See Compile::node_notes_at for the accessor.
|
||||
class Node_Notes {
|
||||
friend class VMStructs;
|
||||
JVMState* _jvms;
|
||||
|
||||
public:
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2006, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -182,7 +182,6 @@ class OptoReg {
|
||||
// and converting that will return OptoReg::Bad losing the identity of the OptoReg.
|
||||
|
||||
class OptoRegPair {
|
||||
friend class VMStructs;
|
||||
private:
|
||||
short _second;
|
||||
short _first;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -39,7 +39,6 @@ class PhaseCFG;
|
||||
//------------------------------PhaseRegAlloc------------------------------------
|
||||
// Abstract register allocator
|
||||
class PhaseRegAlloc : public Phase {
|
||||
friend class VMStructs;
|
||||
static void (*_alloc_statistics[MAX_REG_ALLOCATORS])();
|
||||
static int _num_allocators;
|
||||
|
||||
|
||||
@ -79,7 +79,6 @@ class VerifyMeet;
|
||||
// different kind of Type exists. Types are never modified after creation, so
|
||||
// all their interesting fields are constant.
|
||||
class Type {
|
||||
friend class VMStructs;
|
||||
|
||||
public:
|
||||
enum TYPES {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,41 +0,0 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>
|
||||
Replay
|
||||
</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Compiler replay</h1>
|
||||
<p>
|
||||
The compiler replay is a function to repeat the compiling process from a crashed java process in compiled method<br>
|
||||
This function only exists in debug version of VM
|
||||
</p>
|
||||
<h2>Usage</h2>
|
||||
<pre>
|
||||
First, use SA to attach to the core file, if succeeded, do
|
||||
hsdb> dumpreplaydata <address> | -a | <thread_id> [> replay.txt]
|
||||
create file replay.txt, address is address of Method, or nmethod(CodeBlob)
|
||||
hsdb> buildreplayjars [all | boot | app]
|
||||
create files:
|
||||
all:
|
||||
app.jar, boot.jar
|
||||
boot:
|
||||
boot.jar
|
||||
app:
|
||||
app.jar
|
||||
exit SA now.
|
||||
Second, use the obtained replay text file, replay.txt and jar files, app.jar and boot.jar, using debug version of java
|
||||
java -Xbootclasspath/p:boot.jar -cp app.jar -XX:ReplayDataFile=<datafile> -XX:+ReplayCompiles ....
|
||||
This will replay the compiling process.
|
||||
|
||||
With ReplayCompiles, the replay will recompile all the methods in app.jar, and in boot.jar to emulate the process in java app.
|
||||
|
||||
notes:
|
||||
1) Most time, we don't need the boot.jar which is the classes loaded from JDK. It will be only modified when an agent(JVMDI) is running and modifies the classes.
|
||||
2) If encounter error as "<flag>" not found, that means the SA is using a VMStructs which is different from the one with corefile. In this case, SA has a utility tool vmstructsdump which is located at agent/src/os/<os>/proc/<os_platform>
|
||||
|
||||
Use this tool to dump VM type library:
|
||||
vmstructsdump libjvm.so > <type_name>.db
|
||||
|
||||
set env SA_TYPEDB=<type_name>.db (refer different shell for set envs)
|
||||
@ -38,9 +38,6 @@ Available commands:
|
||||
dumpclass { address | name } [ directory ] <font color="red">dump .class file for given Klass* or class name</font>
|
||||
dumpcodecache <font color="red">dump codecache contents</font>
|
||||
dumpheap [ file ] <font color="red">dump heap in hprof binary format</font>
|
||||
dumpideal -a | id <font color="red">dump ideal graph like debug flag -XX:+PrintIdeal</font>
|
||||
dumpilt -a | id <font color="red">dump inline tree for C2 compilation</font>
|
||||
dumpreplaydata <address> | -a | <thread_id> [>replay.txt] <font color="red">dump replay data into a file</font>
|
||||
echo [ true | false ] <font color="red">turn on/off command echo mode</font>
|
||||
examine { address[/count] | address,address } <font color="red">show contents of memory range</font>
|
||||
field [ type [ name fieldtype isStatic offset address ] ] <font color="red">print info about a field of HotSpot type</font>
|
||||
@ -84,11 +81,5 @@ Available commands:
|
||||
</code>
|
||||
</pre>
|
||||
|
||||
<h3>Compilation Replay</h3>
|
||||
<p>
|
||||
When a java process crashes in compiled method, usually a core file is saved.
|
||||
The replay function can reproduce the compiling process in the core.
|
||||
<a href="cireplay.html">cireplay.html</a>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@ -40,12 +40,6 @@ More details on the command line interface can be found in the "jhsdb" man page
|
||||
</ul>
|
||||
</p>
|
||||
|
||||
<h3>Compilation Replay</h3>
|
||||
<p>
|
||||
When a java process crashes in a compiled method, usually a core file is saved.
|
||||
The compiler replay function can reproduce the compiling process in the core.
|
||||
See <a href="cireplay.html">cireplay.html</a>
|
||||
|
||||
<h3>Debugging transported core dumps</h3>
|
||||
<p>
|
||||
When a core dump is moved from the machine where it was produced to a
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2005, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -44,7 +44,6 @@ import java.util.Objects;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import sun.jvm.hotspot.ci.ciEnv;
|
||||
import sun.jvm.hotspot.code.CodeBlob;
|
||||
import sun.jvm.hotspot.code.CodeCacheVisitor;
|
||||
import sun.jvm.hotspot.code.NMethod;
|
||||
@ -66,8 +65,6 @@ import sun.jvm.hotspot.oops.Oop;
|
||||
import sun.jvm.hotspot.oops.RawHeapVisitor;
|
||||
import sun.jvm.hotspot.oops.Symbol;
|
||||
import sun.jvm.hotspot.oops.UnknownOopException;
|
||||
import sun.jvm.hotspot.opto.Compile;
|
||||
import sun.jvm.hotspot.opto.InlineTree;
|
||||
import sun.jvm.hotspot.runtime.CompiledVFrame;
|
||||
import sun.jvm.hotspot.runtime.CompilerThread;
|
||||
import sun.jvm.hotspot.runtime.JavaThread;
|
||||
@ -562,57 +559,6 @@ public class CommandProcessor {
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("dumpreplaydata", "dumpreplaydata { <address > | -a | <thread_id> }", false) {
|
||||
// This is used to dump replay data from ciInstanceKlass, ciMethodData etc
|
||||
// default file name is replay.txt, also if java crashes in compiler
|
||||
// thread, this file will be dumped in error processing.
|
||||
public void doit(Tokens t) {
|
||||
if (t.countTokens() != 1) {
|
||||
usage();
|
||||
return;
|
||||
}
|
||||
String name = t.nextToken();
|
||||
Address a = null;
|
||||
try {
|
||||
a = VM.getVM().getDebugger().parseAddress(name);
|
||||
} catch (NumberFormatException e) { }
|
||||
if (a != null) {
|
||||
// only nmethod, Method, MethodData and InstanceKlass needed to
|
||||
// dump replay data
|
||||
|
||||
CodeBlob cb = VM.getVM().getCodeCache().findBlob(a);
|
||||
if (cb instanceof NMethod nMethod) {
|
||||
nMethod.dumpReplayData(out);
|
||||
return;
|
||||
}
|
||||
// assume it is Metadata
|
||||
Metadata meta = Metadata.instantiateWrapperFor(a);
|
||||
if (meta != null) {
|
||||
meta.dumpReplayData(out);
|
||||
} else {
|
||||
usage();
|
||||
return;
|
||||
}
|
||||
}
|
||||
// Not an address
|
||||
boolean all = name.equals("-a");
|
||||
Threads threads = VM.getVM().getThreads();
|
||||
for (int i = 0; i < threads.getNumberOfThreads(); i++) {
|
||||
JavaThread thread = threads.getJavaThreadAt(i);
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
thread.printThreadIDOn(new PrintStream(bos));
|
||||
if (all || bos.toString().equals(name)) {
|
||||
if (thread instanceof CompilerThread) {
|
||||
CompilerThread ct = (CompilerThread)thread;
|
||||
ciEnv env = ct.env();
|
||||
if (env != null) {
|
||||
env.dumpReplayData(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("buildreplayjars", "buildreplayjars [ all | app | boot ] | [ prefix ]", false) {
|
||||
// This is used to dump jar files of all the classes
|
||||
// loaded in the core. Everything with null classloader
|
||||
@ -973,94 +919,6 @@ public class CommandProcessor {
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("dumpideal", "dumpideal { -a | id }", false) {
|
||||
// Do a full dump of the nodes reachable from root in each compiler thread.
|
||||
public void doit(Tokens t) {
|
||||
if (t.countTokens() != 1) {
|
||||
usage();
|
||||
} else {
|
||||
String name = t.nextToken();
|
||||
boolean all = name.equals("-a");
|
||||
Threads threads = VM.getVM().getThreads();
|
||||
for (int i = 0; i < threads.getNumberOfThreads(); i++) {
|
||||
JavaThread thread = threads.getJavaThreadAt(i);
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
thread.printThreadIDOn(new PrintStream(bos));
|
||||
if (all || bos.toString().equals(name)) {
|
||||
if (thread instanceof CompilerThread) {
|
||||
CompilerThread ct = (CompilerThread)thread;
|
||||
out.println(ct);
|
||||
ciEnv env = ct.env();
|
||||
if (env != null) {
|
||||
Compile c = env.compilerData();
|
||||
c.root().dump(9999, out);
|
||||
} else {
|
||||
out.println(" not compiling");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("dumpcfg", "dumpcfg { -a | id }", false) {
|
||||
// Dump the PhaseCFG for every compiler thread that has one live.
|
||||
public void doit(Tokens t) {
|
||||
if (t.countTokens() != 1) {
|
||||
usage();
|
||||
} else {
|
||||
String name = t.nextToken();
|
||||
boolean all = name.equals("-a");
|
||||
Threads threads = VM.getVM().getThreads();
|
||||
for (int i = 0; i < threads.getNumberOfThreads(); i++) {
|
||||
JavaThread thread = threads.getJavaThreadAt(i);
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
thread.printThreadIDOn(new PrintStream(bos));
|
||||
if (all || bos.toString().equals(name)) {
|
||||
if (thread instanceof CompilerThread) {
|
||||
CompilerThread ct = (CompilerThread)thread;
|
||||
out.println(ct);
|
||||
ciEnv env = ct.env();
|
||||
if (env != null) {
|
||||
Compile c = env.compilerData();
|
||||
c.cfg().dump(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("dumpilt", "dumpilt { -a | id }", false) {
|
||||
// dumps the InlineTree of a C2 compile
|
||||
public void doit(Tokens t) {
|
||||
if (t.countTokens() != 1) {
|
||||
usage();
|
||||
} else {
|
||||
String name = t.nextToken();
|
||||
boolean all = name.equals("-a");
|
||||
Threads threads = VM.getVM().getThreads();
|
||||
for (int i = 0; i < threads.getNumberOfThreads(); i++) {
|
||||
JavaThread thread = threads.getJavaThreadAt(i);
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
thread.printThreadIDOn(new PrintStream(bos));
|
||||
if (all || bos.toString().equals(name)) {
|
||||
if (thread instanceof CompilerThread) {
|
||||
CompilerThread ct = (CompilerThread)thread;
|
||||
ciEnv env = ct.env();
|
||||
if (env != null) {
|
||||
Compile c = env.compilerData();
|
||||
InlineTree ilt = c.ilt();
|
||||
if (ilt != null) {
|
||||
ilt.print(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
new Command("vmstructsdump", "vmstructsdump", false) {
|
||||
public void doit(Tokens t) {
|
||||
if (t.countTokens() != 0) {
|
||||
|
||||
@ -1,67 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.c1;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.code.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
/** Currently a minimal port to get C1 frame traversal working */
|
||||
|
||||
public class Runtime1 {
|
||||
private static Field blobsField;
|
||||
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) {
|
||||
Type type = db.lookupType("Runtime1");
|
||||
|
||||
blobsField = type.getField("_blobs");
|
||||
}
|
||||
|
||||
public Runtime1() {
|
||||
}
|
||||
|
||||
/** FIXME: consider making argument "type-safe" in Java port */
|
||||
public Address entryFor(int id) {
|
||||
return blobFor(id).codeBegin();
|
||||
}
|
||||
|
||||
/** FIXME: consider making argument "type-safe" in Java port */
|
||||
public CodeBlob blobFor(int id) {
|
||||
Address blobAddr = blobsField.getStaticFieldAddress().getAddressAt(id * VM.getVM().getAddressSize());
|
||||
return VM.getVM().getCodeCache().createCodeBlobWrapper(blobAddr, blobAddr);
|
||||
}
|
||||
}
|
||||
@ -1,55 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciArrayKlass extends ciKlass {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciArrayKlass");
|
||||
dimensionField = new IntField(type.getJIntField("_dimension"), 0);
|
||||
}
|
||||
|
||||
private static IntField dimensionField;
|
||||
|
||||
public ciArrayKlass(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciBaseObject extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciBaseObject");
|
||||
identField = new CIntField(type.getCIntegerField("_ident"), 0);
|
||||
}
|
||||
|
||||
private static CIntField identField;
|
||||
|
||||
public ciBaseObject(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
out.println("# Unknown ci type " + getAddress().getAddressAt(0));
|
||||
}
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciConstant extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciConstant");
|
||||
valueObjectField = type.getAddressField("_value._object");
|
||||
valueDoubleField = type.getJDoubleField("_value._double");
|
||||
valueFloatField = type.getJFloatField("_value._float");
|
||||
valueLongField = type.getJLongField("_value._long");
|
||||
valueIntField = type.getJIntField("_value._int");
|
||||
typeField = new CIntField(type.getCIntegerField("_type"), 0);
|
||||
}
|
||||
|
||||
private static AddressField valueObjectField;
|
||||
private static JDoubleField valueDoubleField;
|
||||
private static JFloatField valueFloatField;
|
||||
private static JLongField valueLongField;
|
||||
private static JIntField valueIntField;
|
||||
private static CIntField typeField;
|
||||
|
||||
public ciConstant(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
// Nothing to be done
|
||||
}
|
||||
}
|
||||
@ -1,110 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.opto.*;
|
||||
import sun.jvm.hotspot.compiler.CompileTask;
|
||||
import sun.jvm.hotspot.prims.JvmtiExport;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.GrowableArray;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciEnv extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciEnv");
|
||||
dependenciesField = type.getAddressField("_dependencies");
|
||||
factoryField = type.getAddressField("_factory");
|
||||
compilerDataField = type.getAddressField("_compiler_data");
|
||||
taskField = type.getAddressField("_task");
|
||||
}
|
||||
|
||||
private static AddressField dependenciesField;
|
||||
private static AddressField factoryField;
|
||||
private static AddressField compilerDataField;
|
||||
private static AddressField taskField;
|
||||
|
||||
public ciEnv(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public Compile compilerData() {
|
||||
Address addr = compilerDataField.getValue(this.getAddress());
|
||||
if (addr == null) {
|
||||
return null;
|
||||
}
|
||||
return new Compile(addr);
|
||||
}
|
||||
|
||||
public ciObjectFactory factory() {
|
||||
return new ciObjectFactory(factoryField.getValue(this.getAddress()));
|
||||
}
|
||||
|
||||
public CompileTask task() {
|
||||
return new CompileTask(taskField.getValue(this.getAddress()));
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
out.println("JvmtiExport can_access_local_variables " +
|
||||
(JvmtiExport.canAccessLocalVariables() ? '1' : '0'));
|
||||
out.println("JvmtiExport can_hotswap_or_post_breakpoint " +
|
||||
(JvmtiExport.canHotswapOrPostBreakpoint() ? '1' : '0'));
|
||||
out.println("JvmtiExport can_post_on_exceptions " +
|
||||
(JvmtiExport.canPostOnExceptions() ? '1' : '0'));
|
||||
|
||||
GrowableArray<ciMetadata> objects = factory().objects();
|
||||
out.println("# " + objects.length() + " ciObject found");
|
||||
for (int i = 0; i < objects.length(); i++) {
|
||||
ciMetadata o = objects.at(i);
|
||||
out.println("# ciMetadata" + i + " @ " + o);
|
||||
o.dumpReplayData(out);
|
||||
}
|
||||
CompileTask task = task();
|
||||
Method method = task.method();
|
||||
int entryBci = task.osrBci();
|
||||
int compLevel = task.compLevel();
|
||||
out.print("compile " + method.nameAsAscii() + " " +
|
||||
entryBci + " " + compLevel);
|
||||
Compile compiler = compilerData();
|
||||
if (compiler != null) {
|
||||
// Dump inlining data.
|
||||
compiler.dumpInlineData(out);
|
||||
}
|
||||
out.println();
|
||||
}
|
||||
}
|
||||
@ -1,64 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciField extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciField");
|
||||
constantValueField = type.getAddressField("_constant_value");
|
||||
isConstantField = type.getAddressField("_is_constant");
|
||||
offsetField = new CIntField(type.getCIntegerField("_offset"), 0);
|
||||
signatureField = type.getAddressField("_signature");
|
||||
nameField = type.getAddressField("_name");
|
||||
holderField = type.getAddressField("_holder");
|
||||
}
|
||||
|
||||
private static AddressField constantValueField;
|
||||
private static AddressField isConstantField;
|
||||
private static CIntField offsetField;
|
||||
private static AddressField signatureField;
|
||||
private static AddressField nameField;
|
||||
private static AddressField holderField;
|
||||
|
||||
public ciField(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,53 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciInstance extends ciObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciInstance");
|
||||
}
|
||||
|
||||
|
||||
public ciInstance(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,165 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.memory.SystemDictionary;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.Type;
|
||||
import sun.jvm.hotspot.types.TypeDataBase;
|
||||
import sun.jvm.hotspot.types.WrongTypeException;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciInstanceKlass extends ciKlass {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciInstanceKlass");
|
||||
initStateField = new CIntField(type.getCIntegerField("_init_state"), 0);
|
||||
isSharedField = new CIntField(type.getCIntegerField("_is_shared"), 0);
|
||||
CLASS_STATE_LINKED = db.lookupIntConstant("InstanceKlass::linked").intValue();
|
||||
CLASS_STATE_FULLY_INITIALIZED = db.lookupIntConstant("InstanceKlass::fully_initialized").intValue();
|
||||
}
|
||||
|
||||
private static CIntField initStateField;
|
||||
private static CIntField isSharedField;
|
||||
private static int CLASS_STATE_LINKED;
|
||||
private static int CLASS_STATE_FULLY_INITIALIZED;
|
||||
|
||||
public ciInstanceKlass(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int initState() {
|
||||
int initState = (int)initStateField.getValue(getAddress());
|
||||
if (isShared() && initState < CLASS_STATE_LINKED) {
|
||||
InstanceKlass ik = (InstanceKlass)getMetadata();
|
||||
initState = ik.getInitStateAsInt();
|
||||
}
|
||||
return initState;
|
||||
}
|
||||
|
||||
public boolean isShared() {
|
||||
return isSharedField.getValue(getAddress()) != 0;
|
||||
}
|
||||
|
||||
public boolean isLinked() {
|
||||
return initState() >= CLASS_STATE_LINKED;
|
||||
}
|
||||
|
||||
public boolean isInitialized() {
|
||||
return initState() == CLASS_STATE_FULLY_INITIALIZED;
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
InstanceKlass ik = (InstanceKlass)getMetadata();
|
||||
ConstantPool cp = ik.getConstants();
|
||||
|
||||
// Try to record related loaded classes
|
||||
Klass sub = ik.getSubklassKlass();
|
||||
while (sub != null) {
|
||||
if (sub instanceof InstanceKlass) {
|
||||
out.println("instanceKlass " + sub.getName().asString());
|
||||
}
|
||||
sub = sub.getNextSiblingKlass();
|
||||
}
|
||||
|
||||
final int length = cp.getLength();
|
||||
out.print("ciInstanceKlass " + name() + " " + (isLinked() ? 1 : 0) + " " + (isInitialized() ? 1 : 0) + " " + length);
|
||||
for (int index = 1; index < length; index++) {
|
||||
out.print(" " + cp.getTags().at(index));
|
||||
}
|
||||
out.println();
|
||||
if (isInitialized()) {
|
||||
Field[] staticFields = ik.getStaticFields();
|
||||
for (int i = 0; i < staticFields.length; i++) {
|
||||
Field f = staticFields[i];
|
||||
Oop mirror = ik.getJavaMirror();
|
||||
if (f.isFinal() && !f.hasInitialValue()) {
|
||||
out.print("staticfield " + name() + " " +
|
||||
OopUtilities.escapeString(f.getID().getName()) + " " +
|
||||
f.getFieldType().getSignature().asString() + " ");
|
||||
if (f instanceof ByteField) {
|
||||
ByteField bf = (ByteField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof BooleanField) {
|
||||
BooleanField bf = (BooleanField)f;
|
||||
out.println(bf.getValue(mirror) ? 1 : 0);
|
||||
} else if (f instanceof ShortField) {
|
||||
ShortField bf = (ShortField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof CharField) {
|
||||
CharField bf = (CharField)f;
|
||||
out.println(bf.getValue(mirror) & 0xffff);
|
||||
} else if (f instanceof IntField) {
|
||||
IntField bf = (IntField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof LongField) {
|
||||
LongField bf = (LongField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof FloatField) {
|
||||
FloatField bf = (FloatField)f;
|
||||
out.println(Float.floatToRawIntBits(bf.getValue(mirror)));
|
||||
} else if (f instanceof DoubleField) {
|
||||
DoubleField bf = (DoubleField)f;
|
||||
out.println(Double.doubleToRawLongBits(bf.getValue(mirror)));
|
||||
} else if (f instanceof OopField) {
|
||||
OopField bf = (OopField)f;
|
||||
Oop value = bf.getValue(mirror);
|
||||
if (value == null) {
|
||||
out.println("null");
|
||||
} else if (value.isInstance()) {
|
||||
Instance inst = (Instance)value;
|
||||
if (inst.isA(SystemDictionary.getStringKlass())) {
|
||||
out.println("\"" + OopUtilities.stringOopToEscapedString(inst) + "\"");
|
||||
} else {
|
||||
out.println(inst.getKlass().getName().asString());
|
||||
}
|
||||
} else if (value.isObjArray()) {
|
||||
ObjArray oa = (ObjArray)value;
|
||||
Klass ek = (ObjArrayKlass)oa.getKlass();
|
||||
out.println(oa.getLength() + " " + ek.getName().asString());
|
||||
} else if (value.isTypeArray()) {
|
||||
TypeArray ta = (TypeArray)value;
|
||||
out.println(ta.getLength());
|
||||
} else {
|
||||
out.println(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,65 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciKlass extends ciType {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciKlass");
|
||||
nameField = type.getAddressField("_name");
|
||||
}
|
||||
|
||||
private static AddressField nameField;
|
||||
|
||||
public String name() {
|
||||
ciSymbol sym = new ciSymbol(nameField.getValue(getAddress()));
|
||||
return sym.asUtf88();
|
||||
}
|
||||
|
||||
public ciKlass(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void printValueOn(PrintStream tty) {
|
||||
Klass k = (Klass)getMetadata();
|
||||
k.printValueOn(tty);
|
||||
}
|
||||
}
|
||||
@ -1,67 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciMetadata extends ciBaseObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciMetadata");
|
||||
metadataField = new MetadataField(type.getAddressField("_metadata"), 0);
|
||||
}
|
||||
|
||||
private static MetadataField metadataField;
|
||||
|
||||
public Metadata getMetadata() {
|
||||
return metadataField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public ciMetadata(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void printOn(PrintStream out) {
|
||||
getMetadata().printValueOn(out);
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return getMetadata().toString();
|
||||
}
|
||||
}
|
||||
@ -1,114 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.code.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciMethod extends ciMetadata {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciMethod");
|
||||
interpreterThrowoutCountField = new CIntField(type.getCIntegerField("_interpreter_throwout_count"), 0);
|
||||
interpreterInvocationCountField = new CIntField(type.getCIntegerField("_interpreter_invocation_count"), 0);
|
||||
try {
|
||||
// XXX
|
||||
instructionsSizeField = new CIntField(type.getCIntegerField("_instructions_size"), 0);
|
||||
} catch (Exception e) {
|
||||
}
|
||||
}
|
||||
|
||||
private static CIntField interpreterThrowoutCountField;
|
||||
private static CIntField interpreterInvocationCountField;
|
||||
private static CIntField instructionsSizeField;
|
||||
|
||||
public ciMethod(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public Method method() {
|
||||
return (Method)getMetadata();
|
||||
}
|
||||
|
||||
public int interpreterThrowoutCount() {
|
||||
return (int) interpreterThrowoutCountField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public int interpreterInvocationCount() {
|
||||
return (int) interpreterInvocationCountField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public int instructionsSize() {
|
||||
if (instructionsSizeField == null) {
|
||||
// XXX
|
||||
Method method = method();
|
||||
NMethod nm = method.getNativeMethod();
|
||||
if (nm != null) return (int)nm.codeEnd().minus(nm.getVerifiedEntryPoint());
|
||||
return 0;
|
||||
}
|
||||
return (int) instructionsSizeField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public void printShortName(PrintStream st) {
|
||||
Method method = method();
|
||||
st.printf(" %s::%s", method.getMethodHolder().getName().asString().replace('/', '.'),
|
||||
method.getName().asString());
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
Method method = (Method)getMetadata();
|
||||
NMethod nm = method.getNativeMethod();
|
||||
out.println("ciMethod " +
|
||||
nameAsAscii() + " " +
|
||||
method.getInvocationCount() + " " +
|
||||
method.getBackedgeCount() + " " +
|
||||
interpreterInvocationCount() + " " +
|
||||
interpreterThrowoutCount() + " " +
|
||||
instructionsSize());
|
||||
}
|
||||
|
||||
public void printValueOn(PrintStream tty) {
|
||||
tty.print("ciMethod " + method().getName().asString() + method().getSignature().asString() + "@" + getAddress());
|
||||
}
|
||||
|
||||
public String nameAsAscii() {
|
||||
Method method = (Method)getMetadata();
|
||||
return method.nameAsAscii();
|
||||
}
|
||||
}
|
||||
@ -1,361 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.types.Field;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciMethodData extends ciMetadata implements MethodDataInterface<ciKlass,ciMethod> {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciMethodData");
|
||||
origField = type.getField("_orig");
|
||||
argReturnedField = new CIntField(type.getCIntegerField("_arg_returned"), 0);
|
||||
argStackField = new CIntField(type.getCIntegerField("_arg_stack"), 0);
|
||||
argLocalField = new CIntField(type.getCIntegerField("_arg_local"), 0);
|
||||
eflagsField = new CIntField(type.getCIntegerField("_eflags"), 0);
|
||||
hintDiField = new CIntField(type.getCIntegerField("_hint_di"), 0);
|
||||
dataField = type.getAddressField("_data");
|
||||
extraDataSizeField = new CIntField(type.getCIntegerField("_extra_data_size"), 0);
|
||||
dataSizeField = new CIntField(type.getCIntegerField("_data_size"), 0);
|
||||
stateField = new CIntField(type.getCIntegerField("_state"), 0);
|
||||
Type typeMethodData = db.lookupType("MethodData");
|
||||
sizeofMethodDataOopDesc = (int)typeMethodData.getSize();
|
||||
parametersTypeDataDi = new CIntField(typeMethodData.getCIntegerField("_parameters_type_data_di"), 0);
|
||||
}
|
||||
|
||||
private static Field origField;
|
||||
private static CIntField argReturnedField;
|
||||
private static CIntField argStackField;
|
||||
private static CIntField argLocalField;
|
||||
private static CIntField eflagsField;
|
||||
private static CIntField hintDiField;
|
||||
private static AddressField dataField;
|
||||
private static CIntField extraDataSizeField;
|
||||
private static CIntField dataSizeField;
|
||||
private static CIntField stateField;
|
||||
private static int sizeofMethodDataOopDesc;
|
||||
private static CIntField parametersTypeDataDi;
|
||||
|
||||
public ciMethodData(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public ciKlass getKlassAtAddress(Address addr) {
|
||||
return (ciKlass)ciObjectFactory.getMetadata(addr);
|
||||
}
|
||||
|
||||
public ciMethod getMethodAtAddress(Address addr) {
|
||||
return (ciMethod)ciObjectFactory.getMetadata(addr);
|
||||
}
|
||||
|
||||
public void printKlassValueOn(ciKlass klass, PrintStream st) {
|
||||
klass.printValueOn(st);
|
||||
}
|
||||
|
||||
public void printMethodValueOn(ciMethod method, PrintStream st) {
|
||||
method.printValueOn(st);
|
||||
}
|
||||
|
||||
private byte[] fetchDataAt(Address base, long size) {
|
||||
byte[] result = new byte[(int)size];
|
||||
for (int i = 0; i < size; i++) {
|
||||
result[i] = base.getJByteAt(i);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public byte[] orig() {
|
||||
// fetch the orig MethodData data between header and dataSize
|
||||
Address base = getAddress().addOffsetTo(origField.getOffset());
|
||||
byte[] result = new byte[(int)origField.getType().getSize()];
|
||||
for (int i = 0; i < result.length; i++) {
|
||||
result[i] = base.getJByteAt(i);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public long[] data() {
|
||||
// Read the data as an array of intptr_t elements
|
||||
Address base = dataField.getValue(getAddress());
|
||||
int elements = (dataSize() + extraDataSize()) / MethodData.cellSize;
|
||||
long[] result = new long[elements];
|
||||
for (int i = 0; i < elements; i++) {
|
||||
Address value = base.getAddressAt(i * MethodData.cellSize);
|
||||
if (value != null) {
|
||||
result[i] = value.minus(null);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
int dataSize() {
|
||||
return (int)dataSizeField.getValue(getAddress());
|
||||
}
|
||||
|
||||
int extraDataSize() {
|
||||
return (int)extraDataSizeField.getValue(getAddress());
|
||||
}
|
||||
|
||||
int state() {
|
||||
return (int)stateField.getValue(getAddress());
|
||||
}
|
||||
|
||||
int currentMileage() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
boolean outOfBounds(int dataIndex) {
|
||||
return dataIndex >= dataSize();
|
||||
}
|
||||
|
||||
ParametersTypeData<ciKlass,ciMethod> parametersTypeData() {
|
||||
int di = (int)parametersTypeDataDi.getValue(getMetadata().getAddress());
|
||||
if (di == -1 || di == -2) {
|
||||
return null;
|
||||
}
|
||||
DataLayout dataLayout = new DataLayout(dataField.getValue(getAddress()), di);
|
||||
return new ParametersTypeData<ciKlass,ciMethod>(this, dataLayout);
|
||||
}
|
||||
|
||||
ProfileData dataAt(int dataIndex) {
|
||||
if (outOfBounds(dataIndex)) {
|
||||
return null;
|
||||
}
|
||||
DataLayout dataLayout = new DataLayout(dataField.getValue(getAddress()), dataIndex);
|
||||
|
||||
switch (dataLayout.tag()) {
|
||||
case DataLayout.noTag:
|
||||
default:
|
||||
throw new InternalError();
|
||||
case DataLayout.bitDataTag:
|
||||
return new BitData(dataLayout);
|
||||
case DataLayout.counterDataTag:
|
||||
return new CounterData(dataLayout);
|
||||
case DataLayout.jumpDataTag:
|
||||
return new JumpData(dataLayout);
|
||||
case DataLayout.receiverTypeDataTag:
|
||||
return new ReceiverTypeData<ciKlass,ciMethod>(this, dataLayout);
|
||||
case DataLayout.virtualCallDataTag:
|
||||
return new VirtualCallData<ciKlass,ciMethod>(this, dataLayout);
|
||||
case DataLayout.retDataTag:
|
||||
return new RetData(dataLayout);
|
||||
case DataLayout.branchDataTag:
|
||||
return new BranchData(dataLayout);
|
||||
case DataLayout.multiBranchDataTag:
|
||||
return new MultiBranchData(dataLayout);
|
||||
case DataLayout.callTypeDataTag:
|
||||
return new CallTypeData<ciKlass,ciMethod>(this, dataLayout);
|
||||
case DataLayout.virtualCallTypeDataTag:
|
||||
return new VirtualCallTypeData<ciKlass,ciMethod>(this, dataLayout);
|
||||
case DataLayout.parametersTypeDataTag:
|
||||
return new ParametersTypeData<ciKlass,ciMethod>(this, dataLayout);
|
||||
}
|
||||
}
|
||||
|
||||
int dpToDi(int dp) {
|
||||
return dp;
|
||||
}
|
||||
|
||||
int firstDi() { return 0; }
|
||||
ProfileData firstData() { return dataAt(firstDi()); }
|
||||
ProfileData nextData(ProfileData current) {
|
||||
int currentIndex = dpToDi(current.dp());
|
||||
int nextIndex = currentIndex + current.sizeInBytes();
|
||||
return dataAt(nextIndex);
|
||||
}
|
||||
boolean isValid(ProfileData current) { return current != null; }
|
||||
|
||||
DataLayout limitDataPosition() {
|
||||
return new DataLayout(dataField.getValue(getAddress()), dataSize());
|
||||
}
|
||||
DataLayout extraDataBase() {
|
||||
return limitDataPosition();
|
||||
}
|
||||
DataLayout extraDataLimit() {
|
||||
return new DataLayout(dataField.getValue(getAddress()), dataSize() + extraDataSize());
|
||||
}
|
||||
DataLayout nextExtra(DataLayout dataLayout) {
|
||||
return new DataLayout(dataField.getValue(getAddress()), dataLayout.dp() + DataLayout.computeSizeInBytes(MethodData.extraNbCells(dataLayout)));
|
||||
}
|
||||
|
||||
public void printDataOn(PrintStream st) {
|
||||
if (parametersTypeData() != null) {
|
||||
parametersTypeData().printDataOn(st);
|
||||
}
|
||||
ProfileData data = firstData();
|
||||
for ( ; isValid(data); data = nextData(data)) {
|
||||
st.print(dpToDi(data.dp()));
|
||||
st.print(" ");
|
||||
// st->fillTo(6);
|
||||
data.printDataOn(st);
|
||||
}
|
||||
st.println("--- Extra data:");
|
||||
DataLayout dp = extraDataBase();
|
||||
DataLayout end = extraDataLimit();
|
||||
for (;; dp = nextExtra(dp)) {
|
||||
switch(dp.tag()) {
|
||||
case DataLayout.noTag:
|
||||
continue;
|
||||
case DataLayout.bitDataTag:
|
||||
data = new BitData(dp);
|
||||
break;
|
||||
case DataLayout.speculativeTrapDataTag:
|
||||
data = new SpeculativeTrapData<ciKlass,ciMethod>(this, dp);
|
||||
break;
|
||||
case DataLayout.argInfoDataTag:
|
||||
data = new ArgInfoData(dp);
|
||||
dp = end; // ArgInfoData is at the end of extra data section.
|
||||
break;
|
||||
default:
|
||||
throw new InternalError("unexpected tag " + dp.tag());
|
||||
}
|
||||
st.print(dpToDi(data.dp()));
|
||||
st.print(" ");
|
||||
data.printDataOn(st);
|
||||
if (dp == end) return;
|
||||
}
|
||||
}
|
||||
|
||||
int dumpReplayDataTypeHelper(PrintStream out, int round, int count, int index, ProfileData pdata, ciKlass k) {
|
||||
if (k != null) {
|
||||
if (round == 0) count++;
|
||||
else out.print(" " + ((pdata.dp() + pdata.cellOffset(index)) / MethodData.cellSize) + " " + k.name());
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataReceiverTypeHelper(PrintStream out, int round, int count, ReceiverTypeData<ciKlass,ciMethod> vdata) {
|
||||
for (int i = 0; i < vdata.rowLimit(); i++) {
|
||||
ciKlass k = vdata.receiver(i);
|
||||
count = dumpReplayDataTypeHelper(out, round, count, vdata.receiverCellIndex(i), vdata, k);
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataCallTypeHelper(PrintStream out, int round, int count, CallTypeDataInterface<ciKlass> callTypeData) {
|
||||
if (callTypeData.hasArguments()) {
|
||||
for (int i = 0; i < callTypeData.numberOfArguments(); i++) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, callTypeData.argumentTypeIndex(i), (ProfileData)callTypeData, callTypeData.argumentType(i));
|
||||
}
|
||||
}
|
||||
if (callTypeData.hasReturn()) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, callTypeData.returnTypeIndex(), (ProfileData)callTypeData, callTypeData.returnType());
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataExtraDataHelper(PrintStream out, int round, int count) {
|
||||
DataLayout dp = extraDataBase();
|
||||
DataLayout end = extraDataLimit();
|
||||
|
||||
for (;dp != end; dp = nextExtra(dp)) {
|
||||
switch(dp.tag()) {
|
||||
case DataLayout.noTag:
|
||||
case DataLayout.argInfoDataTag:
|
||||
return count;
|
||||
case DataLayout.bitDataTag:
|
||||
break;
|
||||
case DataLayout.speculativeTrapDataTag: {
|
||||
SpeculativeTrapData<ciKlass,ciMethod> data = new SpeculativeTrapData<ciKlass,ciMethod>(this, dp);
|
||||
ciMethod m = data.method();
|
||||
if (m != null) {
|
||||
if (round == 0) {
|
||||
count++;
|
||||
} else {
|
||||
out.print(" " + (dpToDi(data.dp() + data.cellOffset(SpeculativeTrapData.methodIndex())) / MethodData.cellSize) + " " + m.nameAsAscii());
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
throw new InternalError("bad tag " + dp.tag());
|
||||
}
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
MethodData mdo = (MethodData)getMetadata();
|
||||
Method method = mdo.getMethod();
|
||||
out.print("ciMethodData " +
|
||||
method.nameAsAscii() + " " +
|
||||
state() + " " + currentMileage());
|
||||
byte[] orig = orig();
|
||||
out.print(" orig " + orig.length);
|
||||
for (int i = 0; i < orig.length; i++) {
|
||||
out.print(" " + (orig[i] & 0xff));
|
||||
}
|
||||
|
||||
long[] data = data();
|
||||
out.print(" data " + data.length);
|
||||
for (int i = 0; i < data.length; i++) {
|
||||
out.print(" 0x" + Long.toHexString(data[i]));
|
||||
}
|
||||
int count = 0;
|
||||
ParametersTypeData<ciKlass,ciMethod> parameters = parametersTypeData();
|
||||
for (int round = 0; round < 2; round++) {
|
||||
if (round == 1) out.print(" oops " + count);
|
||||
ProfileData pdata = firstData();
|
||||
for ( ; isValid(pdata); pdata = nextData(pdata)) {
|
||||
if (pdata instanceof ReceiverTypeData) {
|
||||
@SuppressWarnings("unchecked")
|
||||
ReceiverTypeData<ciKlass,ciMethod> receiverTypeData = (ReceiverTypeData<ciKlass,ciMethod>)pdata;
|
||||
count = dumpReplayDataReceiverTypeHelper(out, round, count, receiverTypeData);
|
||||
}
|
||||
if (pdata instanceof CallTypeDataInterface) {
|
||||
@SuppressWarnings("unchecked")
|
||||
CallTypeDataInterface<ciKlass> callTypeData = (CallTypeDataInterface<ciKlass>)pdata;
|
||||
count = dumpReplayDataCallTypeHelper(out, round, count, callTypeData);
|
||||
}
|
||||
}
|
||||
if (parameters != null) {
|
||||
for (int i = 0; i < parameters.numberOfParameters(); i++) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, ParametersTypeData.typeIndex(i), parameters, parameters.type(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
count = 0;
|
||||
for (int round = 0; round < 2; round++) {
|
||||
if (round == 1) out.print(" methods " + count);
|
||||
count = dumpReplayDataExtraDataHelper(out, round, count);
|
||||
}
|
||||
out.println();
|
||||
}
|
||||
}
|
||||
@ -1,57 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciObjArrayKlass extends ciArrayKlass {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciObjArrayKlass");
|
||||
elementKlassField = type.getAddressField("_element_klass");
|
||||
baseElementKlassField = type.getAddressField("_base_element_klass");
|
||||
}
|
||||
|
||||
private static AddressField elementKlassField;
|
||||
private static AddressField baseElementKlassField;
|
||||
|
||||
public ciObjArrayKlass(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,71 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciObject extends ciBaseObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciObject");
|
||||
klassField = type.getAddressField("_klass");
|
||||
handleField = type.getAddressField("_handle");
|
||||
}
|
||||
|
||||
private static AddressField klassField;
|
||||
private static AddressField handleField;
|
||||
|
||||
public Oop getOop() {
|
||||
OopHandle oh = handleField.getValue(getAddress()).getOopHandleAt(0);
|
||||
return VM.getVM().getObjectHeap().newOop(oh);
|
||||
}
|
||||
|
||||
public ciObject(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void printOn(PrintStream out) {
|
||||
getOop().printValueOn(out);
|
||||
out.println();
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return getOop().toString();
|
||||
}
|
||||
}
|
||||
@ -1,88 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.lang.reflect.Constructor;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.utilities.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciObjectFactory extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciObjectFactory");
|
||||
ciMetadataField = type.getAddressField("_ci_metadata");
|
||||
symbolsField = type.getAddressField("_symbols");
|
||||
|
||||
ciObjectConstructor = new VirtualBaseConstructor<ciObject>(db, db.lookupType("ciObject"), "sun.jvm.hotspot.ci", ciObject.class);
|
||||
ciMetadataConstructor = new VirtualBaseConstructor<ciMetadata>(db, db.lookupType("ciMetadata"), "sun.jvm.hotspot.ci", ciMetadata.class);
|
||||
ciSymbolConstructor = new VirtualBaseConstructor<ciSymbol>(db, db.lookupType("ciSymbol"), "sun.jvm.hotspot.ci", ciSymbol.class);
|
||||
}
|
||||
|
||||
private static AddressField ciMetadataField;
|
||||
private static AddressField symbolsField;
|
||||
|
||||
private static VirtualBaseConstructor<ciObject> ciObjectConstructor;
|
||||
private static VirtualBaseConstructor<ciMetadata> ciMetadataConstructor;
|
||||
private static VirtualBaseConstructor<ciSymbol> ciSymbolConstructor;
|
||||
|
||||
public static ciObject get(Address addr) {
|
||||
if (addr == null) return null;
|
||||
|
||||
return ciObjectConstructor.instantiateWrapperFor(addr);
|
||||
}
|
||||
|
||||
public static ciMetadata getMetadata(Address addr) {
|
||||
if (addr == null) return null;
|
||||
|
||||
return ciMetadataConstructor.instantiateWrapperFor(addr);
|
||||
}
|
||||
|
||||
public GrowableArray<ciMetadata> objects() {
|
||||
Address addr = getAddress().addOffsetTo(ciMetadataField.getOffset());
|
||||
return GrowableArray.create(addr, ciMetadataConstructor);
|
||||
}
|
||||
|
||||
public GrowableArray<ciSymbol> symbols() {
|
||||
Address addr = getAddress().addOffsetTo(symbolsField.getOffset());
|
||||
return GrowableArray.create(addr, ciSymbolConstructor);
|
||||
}
|
||||
|
||||
public ciObjectFactory(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,60 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciSymbol extends ciMetadata {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciSymbol");
|
||||
symbolField = type.getAddressField("_symbol");
|
||||
}
|
||||
|
||||
private static AddressField symbolField;
|
||||
|
||||
public String asUtf88() {
|
||||
Symbol sym = Symbol.create(symbolField.getValue(getAddress()));
|
||||
return sym.asString();
|
||||
}
|
||||
|
||||
public ciSymbol(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,54 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciType extends ciMetadata {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciType");
|
||||
basicTypeField = new CIntField(type.getCIntegerField("_basic_type"), 0);
|
||||
}
|
||||
|
||||
private static CIntField basicTypeField;
|
||||
|
||||
public ciType(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.ci;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ciTypeArrayKlass extends ciArrayKlass {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ciTypeArrayKlass");
|
||||
}
|
||||
|
||||
public ciTypeArrayKlass(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -65,8 +65,6 @@ public class CodeBlob extends VMObject {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
protected static int matcherInterpreterFramePointerReg;
|
||||
|
||||
private static void initialize(TypeDataBase db) {
|
||||
Type type = db.lookupType("CodeBlob");
|
||||
|
||||
@ -83,11 +81,6 @@ public class CodeBlob extends VMObject {
|
||||
oopMapsField = type.getAddressField("_oop_maps");
|
||||
callerMustGCArgumentsField = type.getCIntegerField("_caller_must_gc_arguments");
|
||||
|
||||
if (VM.getVM().isServerCompiler()) {
|
||||
matcherInterpreterFramePointerReg =
|
||||
db.lookupIntConstant("Matcher::interpreter_frame_pointer_reg").intValue();
|
||||
}
|
||||
|
||||
NMethodKind = db.lookupIntConstant("CodeBlobKind::Nmethod").intValue();
|
||||
RuntimeStubKind = db.lookupIntConstant("CodeBlobKind::RuntimeStub").intValue();
|
||||
UpcallKind = db.lookupIntConstant("CodeBlobKind::Upcall").intValue();
|
||||
|
||||
@ -489,42 +489,6 @@ public class NMethod extends CodeBlob {
|
||||
method.getSignature().asString();
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
HashMap<Metadata, Metadata> h = new HashMap<>();
|
||||
for (int i = 1; i < getMetadataLength(); i++) {
|
||||
Metadata meta = Metadata.instantiateWrapperFor(getMetadataAt(i));
|
||||
System.err.println(meta);
|
||||
if (h.get(meta) != null) continue;
|
||||
h.put(meta, meta);
|
||||
if (meta instanceof InstanceKlass) {
|
||||
meta.dumpReplayData(out);
|
||||
} else if (meta instanceof Method) {
|
||||
meta.dumpReplayData(out);
|
||||
MethodData mdo = ((Method)meta).getMethodData();
|
||||
if (mdo != null) {
|
||||
mdo.dumpReplayData(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
Method method = getMethod();
|
||||
if (h.get(method) == null) {
|
||||
method.dumpReplayData(out);
|
||||
MethodData mdo = method.getMethodData();
|
||||
if (mdo != null) {
|
||||
mdo.dumpReplayData(out);
|
||||
}
|
||||
}
|
||||
if (h.get(method.getMethodHolder()) == null) {
|
||||
method.getMethodHolder().dumpReplayData(out);
|
||||
}
|
||||
Klass holder = method.getMethodHolder();
|
||||
out.println("compile " + holder.getName().asString() + " " +
|
||||
OopUtilities.escapeString(method.getName().asString()) + " " +
|
||||
method.getSignature().asString() + " " +
|
||||
getEntryBCI() + " " + getCompLevel());
|
||||
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------
|
||||
// Internals only below this point
|
||||
//
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2011, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,7 +29,6 @@ import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.opto.*;
|
||||
import sun.jvm.hotspot.prims.JvmtiExport;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -965,84 +965,4 @@ public class InstanceKlass extends Klass {
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
ConstantPool cp = getConstants();
|
||||
|
||||
// Try to record related loaded classes
|
||||
Klass sub = getSubklassKlass();
|
||||
while (sub != null) {
|
||||
if (sub instanceof InstanceKlass) {
|
||||
out.println("instanceKlass " + sub.getName().asString());
|
||||
}
|
||||
sub = sub.getNextSiblingKlass();
|
||||
}
|
||||
|
||||
final int length = cp.getLength();
|
||||
out.print("ciInstanceKlass " + getName().asString() + " " + (isLinked() ? 1 : 0) + " " + (isInitialized() ? 1 : 0) + " " + length);
|
||||
for (int index = 1; index < length; index++) {
|
||||
out.print(" " + cp.getTags().at(index));
|
||||
}
|
||||
out.println();
|
||||
if (isInitialized()) {
|
||||
Field[] staticFields = getStaticFields();
|
||||
for (int i = 0; i < staticFields.length; i++) {
|
||||
Field f = staticFields[i];
|
||||
Oop mirror = getJavaMirror();
|
||||
if (f.isFinal() && !f.hasInitialValue()) {
|
||||
out.print("staticfield " + getName().asString() + " " +
|
||||
OopUtilities.escapeString(f.getID().getName()) + " " +
|
||||
f.getFieldType().getSignature().asString() + " ");
|
||||
if (f instanceof ByteField) {
|
||||
ByteField bf = (ByteField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof BooleanField) {
|
||||
BooleanField bf = (BooleanField)f;
|
||||
out.println(bf.getValue(mirror) ? 1 : 0);
|
||||
} else if (f instanceof ShortField) {
|
||||
ShortField bf = (ShortField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof CharField) {
|
||||
CharField bf = (CharField)f;
|
||||
out.println(bf.getValue(mirror) & 0xffff);
|
||||
} else if (f instanceof IntField) {
|
||||
IntField bf = (IntField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof LongField) {
|
||||
LongField bf = (LongField)f;
|
||||
out.println(bf.getValue(mirror));
|
||||
} else if (f instanceof FloatField) {
|
||||
FloatField bf = (FloatField)f;
|
||||
out.println(Float.floatToRawIntBits(bf.getValue(mirror)));
|
||||
} else if (f instanceof DoubleField) {
|
||||
DoubleField bf = (DoubleField)f;
|
||||
out.println(Double.doubleToRawLongBits(bf.getValue(mirror)));
|
||||
} else if (f instanceof OopField) {
|
||||
OopField bf = (OopField)f;
|
||||
|
||||
Oop value = bf.getValue(mirror);
|
||||
if (value == null) {
|
||||
out.println("null");
|
||||
} else if (value.isInstance()) {
|
||||
Instance inst = (Instance)value;
|
||||
if (inst.isA(SystemDictionary.getStringKlass())) {
|
||||
out.println("\"" + OopUtilities.stringOopToEscapedString(inst) + "\"");
|
||||
} else {
|
||||
out.println(inst.getKlass().getName().asString());
|
||||
}
|
||||
} else if (value.isObjArray()) {
|
||||
ObjArray oa = (ObjArray)value;
|
||||
Klass ek = (ObjArrayKlass)oa.getKlass();
|
||||
out.println(oa.getLength() + " " + ek.getName().asString());
|
||||
} else if (value.isTypeArray()) {
|
||||
TypeArray ta = (TypeArray)value;
|
||||
out.println(ta.getLength());
|
||||
} else {
|
||||
out.println(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2012, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -89,9 +89,6 @@ public abstract class Metadata extends VMObject {
|
||||
}
|
||||
|
||||
public abstract void printValueOn(PrintStream tty);
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
out.println("# Unknown Metadata");
|
||||
}
|
||||
|
||||
public boolean isShared() {
|
||||
VM vm = VM.getVM();
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2023, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -348,22 +348,6 @@ public class Method extends Metadata {
|
||||
return buf.toString().replace('/', '.');
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
NMethod nm = getNativeMethod();
|
||||
int code_size = 0;
|
||||
if (nm != null) {
|
||||
code_size = (int)nm.codeEnd().minus(nm.getVerifiedEntryPoint());
|
||||
}
|
||||
Klass holder = getMethodHolder();
|
||||
out.println("ciMethod " +
|
||||
nameAsAscii() + " " +
|
||||
getInvocationCount() + " " +
|
||||
getBackedgeCount() + " " +
|
||||
interpreterInvocationCount() + " " +
|
||||
interpreterThrowoutCount() + " " +
|
||||
code_size);
|
||||
}
|
||||
|
||||
public int interpreterThrowoutCount() {
|
||||
return getMethodCounters().interpreterThrowoutCount();
|
||||
}
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -439,111 +439,4 @@ public class MethodData extends Metadata implements MethodDataInterface<Klass,Me
|
||||
return 20000;
|
||||
}
|
||||
|
||||
int dumpReplayDataTypeHelper(PrintStream out, int round, int count, int index, ProfileData pdata, Klass k) {
|
||||
if (k != null) {
|
||||
if (round == 0) count++;
|
||||
else out.print(" " +
|
||||
(dpToDi(pdata.dp() +
|
||||
pdata.cellOffset(index)) / cellSize) + " " +
|
||||
k.getName().asString());
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataReceiverTypeHelper(PrintStream out, int round, int count, ReceiverTypeData<Klass,Method> vdata) {
|
||||
for (int i = 0; i < vdata.rowLimit(); i++) {
|
||||
Klass k = vdata.receiver(i);
|
||||
count = dumpReplayDataTypeHelper(out, round, count, vdata.receiverCellIndex(i), vdata, k);
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataCallTypeHelper(PrintStream out, int round, int count, CallTypeDataInterface<Klass> callTypeData) {
|
||||
if (callTypeData.hasArguments()) {
|
||||
for (int i = 0; i < callTypeData.numberOfArguments(); i++) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, callTypeData.argumentTypeIndex(i), (ProfileData)callTypeData, callTypeData.argumentType(i));
|
||||
}
|
||||
}
|
||||
if (callTypeData.hasReturn()) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, callTypeData.returnTypeIndex(), (ProfileData)callTypeData, callTypeData.returnType());
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int dumpReplayDataExtraDataHelper(PrintStream out, int round, int count) {
|
||||
DataLayout dp = extraDataBase();
|
||||
DataLayout end = extraDataLimit();
|
||||
|
||||
for (;dp != end; dp = nextExtra(dp)) {
|
||||
switch(dp.tag()) {
|
||||
case DataLayout.noTag:
|
||||
case DataLayout.argInfoDataTag:
|
||||
return count;
|
||||
case DataLayout.bitDataTag:
|
||||
break;
|
||||
case DataLayout.speculativeTrapDataTag: {
|
||||
SpeculativeTrapData<Klass,Method> data = new SpeculativeTrapData<Klass,Method>(this, dp);
|
||||
Method m = data.method();
|
||||
if (m != null) {
|
||||
if (round == 0) {
|
||||
count++;
|
||||
} else {
|
||||
out.print(" " + (dpToDi(data.dp() + data.cellOffset(SpeculativeTrapData.methodIndex())) / cellSize) + " " + m.nameAsAscii());
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
throw new InternalError("bad tag " + dp.tag());
|
||||
}
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
Method method = getMethod();
|
||||
out.print("ciMethodData " + method.nameAsAscii()
|
||||
+ " " + "2" + " " +
|
||||
currentMileage());
|
||||
byte[] orig = orig();
|
||||
out.print(" orig " + orig.length);
|
||||
for (int i = 0; i < orig.length; i++) {
|
||||
out.print(" " + (orig[i] & 0xff));
|
||||
}
|
||||
|
||||
long[] data = data();
|
||||
out.print(" data " + data.length);
|
||||
for (int i = 0; i < data.length; i++) {
|
||||
out.print(" 0x" + Long.toHexString(data[i]));
|
||||
}
|
||||
int count = 0;
|
||||
ParametersTypeData<Klass,Method> parameters = parametersTypeData();
|
||||
for (int round = 0; round < 2; round++) {
|
||||
if (round == 1) out.print(" oops " + count);
|
||||
ProfileData pdata = firstData();
|
||||
for ( ; isValid(pdata); pdata = nextData(pdata)) {
|
||||
if (pdata instanceof ReceiverTypeData) {
|
||||
@SuppressWarnings("unchecked")
|
||||
ReceiverTypeData<Klass,Method> receiverTypeData = (ReceiverTypeData<Klass,Method>)pdata;
|
||||
count = dumpReplayDataReceiverTypeHelper(out, round, count, receiverTypeData);
|
||||
}
|
||||
if (pdata instanceof CallTypeDataInterface) {
|
||||
@SuppressWarnings("unchecked")
|
||||
CallTypeDataInterface<Klass> callTypeData = (CallTypeDataInterface<Klass>)pdata;
|
||||
count = dumpReplayDataCallTypeHelper(out, round, count, callTypeData);
|
||||
}
|
||||
}
|
||||
if (parameters != null) {
|
||||
for (int i = 0; i < parameters.numberOfParameters(); i++) {
|
||||
count = dumpReplayDataTypeHelper(out, round, count, ParametersTypeData.typeIndex(i), parameters, parameters.type(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
count = 0;
|
||||
for (int round = 0; round < 2; round++) {
|
||||
if (round == 1) out.print(" methods " + count);
|
||||
count = dumpReplayDataExtraDataHelper(out, round, count);
|
||||
}
|
||||
out.println();
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,90 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Block extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Block");
|
||||
nodesField = type.getAddressField("_nodes");
|
||||
succsField = type.getAddressField("_succs");
|
||||
numSuccsField = new CIntField(type.getCIntegerField("_num_succs"), 0);
|
||||
preOrderField = new CIntField(type.getCIntegerField("_pre_order"), 0);
|
||||
domDepthField = new CIntField(type.getCIntegerField("_dom_depth"), 0);
|
||||
idomField = type.getAddressField("_idom");
|
||||
freqField = type.getJDoubleField("_freq");
|
||||
}
|
||||
|
||||
private static AddressField nodesField;
|
||||
private static AddressField succsField;
|
||||
private static CIntField numSuccsField;
|
||||
private static CIntField preOrderField;
|
||||
private static CIntField domDepthField;
|
||||
private static AddressField idomField;
|
||||
private static JDoubleField freqField;
|
||||
|
||||
public Block(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int preOrder() {
|
||||
return (int)preOrderField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public double freq() {
|
||||
return freqField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public Node_List nodes() {
|
||||
return new Node_List(getAddress().addOffsetTo(nodesField.getOffset()));
|
||||
}
|
||||
|
||||
public void dump(PrintStream out) {
|
||||
out.print("B" + preOrder());
|
||||
out.print(" Freq: " + freq());
|
||||
out.println();
|
||||
Node_List nl = nodes();
|
||||
int cnt = nl.size();
|
||||
for( int i=0; i<cnt; i++ )
|
||||
nl.at(i).dump(out);
|
||||
out.print("\n");
|
||||
}
|
||||
}
|
||||
@ -1,66 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Block_Array extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Block_Array");
|
||||
sizeField = new CIntField(type.getCIntegerField("_size"), 0);
|
||||
blocksField = type.getAddressField("_blocks");
|
||||
arenaField = type.getAddressField("_arena");
|
||||
}
|
||||
|
||||
private static CIntField sizeField;
|
||||
private static AddressField blocksField;
|
||||
private static AddressField arenaField;
|
||||
|
||||
public Block_Array(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int Max() {
|
||||
return (int) sizeField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public Block at(int i) {
|
||||
return new Block(blocksField.getValue(getAddress()).getAddressAt(i * (int)VM.getVM().getAddressSize()));
|
||||
}
|
||||
}
|
||||
@ -1,58 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Block_List extends Block_Array {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Block_List");
|
||||
cntField = new CIntField(type.getCIntegerField("_cnt"), 0);
|
||||
}
|
||||
|
||||
private static CIntField cntField;
|
||||
|
||||
public Block_List(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int size() {
|
||||
return (int) cntField.getValue(getAddress());
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class CallDynamicJavaNode extends CallJavaNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("CallDynamicJavaNode");
|
||||
}
|
||||
|
||||
|
||||
public CallDynamicJavaNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,68 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.*;
|
||||
import sun.jvm.hotspot.code.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.ci.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class CallJavaNode extends CallNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("CallJavaNode");
|
||||
methodField = type.getAddressField("_method");
|
||||
}
|
||||
|
||||
private static AddressField methodField;
|
||||
|
||||
public CallJavaNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public ciMethod method() {
|
||||
return (ciMethod) ciObjectFactory.getMetadata(methodField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
if (method() != null) {
|
||||
out.print(" " + method().method().externalNameAndSignature());
|
||||
}
|
||||
super.dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,67 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class CallNode extends SafePointNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("CallNode");
|
||||
entryPointField = type.getAddressField("_entry_point");
|
||||
}
|
||||
|
||||
private static AddressField entryPointField;
|
||||
|
||||
public Address entryPoint() {
|
||||
return entryPointField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public CallNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
out.print(" ");
|
||||
// tf()->dumpOn(st);
|
||||
// if (_cnt != countUnknown) st->print(" C=%f",_cnt);
|
||||
JVMState jvms = jvms();
|
||||
if (jvms != null) jvms.dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,66 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.utilities.CStringUtilities;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class CallRuntimeNode extends CallNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("CallRuntimeNode");
|
||||
nameField = type.getAddressField("_name");
|
||||
}
|
||||
|
||||
private static AddressField nameField;
|
||||
|
||||
public String name() {
|
||||
return CStringUtilities.getString(nameField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public CallRuntimeNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
out.print(" #");
|
||||
out.print(name());
|
||||
super.dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.utilities.CStringUtilities;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class CallStaticJavaNode extends CallJavaNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("CallStaticJavaNode");
|
||||
nameField = type.getAddressField("_name");
|
||||
}
|
||||
|
||||
private static AddressField nameField;
|
||||
|
||||
public String name() {
|
||||
return CStringUtilities.getString(nameField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public CallStaticJavaNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
out.print(" Static ");
|
||||
String name = name();
|
||||
if (name != null) {
|
||||
out.print(name);
|
||||
// int trapReq = uncommonTrapRequest();
|
||||
// if (trapReq != 0) {
|
||||
// char buf[100];
|
||||
// st->print("(%s)",
|
||||
// Deoptimization::formatTrapRequest(buf, sizeof(buf),
|
||||
// trapReq));
|
||||
// }
|
||||
out.print(" ");
|
||||
}
|
||||
super.dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,107 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.ci.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Compile extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Compile");
|
||||
rootField = type.getAddressField("_root");
|
||||
uniqueField = new CIntField(type.getCIntegerField("_unique"), 0);
|
||||
entryBciField = new CIntField(type.getCIntegerField("_entry_bci"), 0);
|
||||
topField = type.getAddressField("_top");
|
||||
cfgField = type.getAddressField("_cfg");
|
||||
regallocField = type.getAddressField("_regalloc");
|
||||
methodField = type.getAddressField("_method");
|
||||
iltField = type.getAddressField("_ilt");
|
||||
}
|
||||
|
||||
private static AddressField rootField;
|
||||
private static CIntField uniqueField;
|
||||
private static CIntField entryBciField;
|
||||
private static AddressField topField;
|
||||
private static AddressField cfgField;
|
||||
private static AddressField regallocField;
|
||||
private static AddressField methodField;
|
||||
private static AddressField iltField;
|
||||
|
||||
public Compile(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public Node root() {
|
||||
return new RootNode(rootField.getValue(this.getAddress()));
|
||||
}
|
||||
|
||||
public int entryBci() {
|
||||
return (int)entryBciField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public ciMethod method() {
|
||||
return (ciMethod) ciObjectFactory.getMetadata(methodField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public PhaseCFG cfg() {
|
||||
Address a = cfgField.getValue(this.getAddress());
|
||||
if (a != null) {
|
||||
return new PhaseCFG(a);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public InlineTree ilt() {
|
||||
Address a = iltField.getValue(this.getAddress());
|
||||
if (a != null) {
|
||||
return new InlineTree(a);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public void dumpInlineData(PrintStream out) {
|
||||
InlineTree inlTree = ilt();
|
||||
if (inlTree != null) {
|
||||
out.print(" inline " + inlTree.count());
|
||||
inlTree.dumpReplayData(out);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,67 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2014, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
//These definitions should be kept in sync with the definitions in the HotSpot code.
|
||||
|
||||
public enum CompilerPhaseType {
|
||||
PHASE_BEFORE_STRINGOPTS ("Before StringOpts"),
|
||||
PHASE_AFTER_STRINGOPTS ("After StringOpts"),
|
||||
PHASE_BEFORE_REMOVEUSELESS ("Before RemoveUseless"),
|
||||
PHASE_AFTER_PARSING ("After Parsing"),
|
||||
PHASE_ITER_GVN1 ("Iter GVN 1"),
|
||||
PHASE_PHASEIDEAL_BEFORE_EA ("PhaseIdealLoop before EA"),
|
||||
PHASE_ITER_GVN_AFTER_EA ("Iter GVN after EA"),
|
||||
PHASE_ITER_GVN_AFTER_ELIMINATION ("Iter GVN after eliminating allocations and locks"),
|
||||
PHASE_PHASEIDEALLOOP1 ("PhaseIdealLoop 1"),
|
||||
PHASE_PHASEIDEALLOOP2 ("PhaseIdealLoop 2"),
|
||||
PHASE_PHASEIDEALLOOP3 ("PhaseIdealLoop 3"),
|
||||
PHASE_CCP1 ("PhaseCCP 1"),
|
||||
PHASE_ITER_GVN2 ("Iter GVN 2"),
|
||||
PHASE_PHASEIDEALLOOP_ITERATIONS ("PhaseIdealLoop iterations"),
|
||||
PHASE_OPTIMIZE_FINISHED ("Optimize finished"),
|
||||
PHASE_GLOBAL_CODE_MOTION ("Global code motion"),
|
||||
PHASE_FINAL_CODE ("Final Code"),
|
||||
PHASE_AFTER_EA ("After Escape Analysis"),
|
||||
PHASE_BEFORE_CLOOPS ("Before CountedLoop"),
|
||||
PHASE_AFTER_CLOOPS ("After CountedLoop"),
|
||||
PHASE_BEFORE_BEAUTIFY_LOOPS ("Before beautify loops"),
|
||||
PHASE_AFTER_BEAUTIFY_LOOPS ("After beautify loops"),
|
||||
PHASE_BEFORE_MATCHING ("Before Matching"),
|
||||
PHASE_INCREMENTAL_INLINE ("Incremental Inline"),
|
||||
PHASE_INCREMENTAL_BOXING_INLINE ("Incremental Boxing Inline"),
|
||||
PHASE_END ("End"),
|
||||
PHASE_FAILURE ("Failure"),
|
||||
PHASE_NUM_TYPES ("Number of Phase Types");
|
||||
|
||||
private final String value;
|
||||
|
||||
CompilerPhaseType(String val) {
|
||||
this.value = val;
|
||||
}
|
||||
public String value() {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class HaltNode extends Node {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("HaltNode");
|
||||
}
|
||||
|
||||
|
||||
public HaltNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,135 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.ci.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.utilities.GrowableArray;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class InlineTree extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("InlineTree");
|
||||
callerJvmsField = type.getAddressField("_caller_jvms");
|
||||
methodField = type.getAddressField("_method");
|
||||
callerTreeField = type.getAddressField("_caller_tree");
|
||||
subtreesField = type.getAddressField("_subtrees");
|
||||
}
|
||||
|
||||
private static AddressField callerJvmsField;
|
||||
private static AddressField methodField;
|
||||
private static AddressField callerTreeField;
|
||||
private static AddressField subtreesField;
|
||||
|
||||
private static StaticBaseConstructor<InlineTree> inlineTreeConstructor = new StaticBaseConstructor<>(InlineTree.class);
|
||||
|
||||
public InlineTree(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public InlineTree callerTree() {
|
||||
Address addr = callerTreeField.getValue(getAddress());
|
||||
if (addr == null) return null;
|
||||
|
||||
return new InlineTree(addr);
|
||||
}
|
||||
|
||||
public ciMethod method() {
|
||||
return (ciMethod) ciObjectFactory.getMetadata(methodField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public JVMState callerJvms() {
|
||||
return JVMState.create(callerJvmsField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public int callerBci() {
|
||||
JVMState jvms = callerJvms();
|
||||
return (jvms != null) ? jvms.bci() : -1;
|
||||
}
|
||||
|
||||
public GrowableArray<InlineTree> subtrees() {
|
||||
Address addr = getAddress().addOffsetTo(subtreesField.getOffset());
|
||||
|
||||
return GrowableArray.create(addr, inlineTreeConstructor);
|
||||
}
|
||||
|
||||
public int inlineLevel() {
|
||||
JVMState jvms = callerJvms();
|
||||
return (jvms != null) ? jvms.depth() : 0;
|
||||
}
|
||||
|
||||
public void printImpl(PrintStream st, int indent) {
|
||||
for (int i = 0; i < indent; i++) st.print(" ");
|
||||
st.printf(" @ %d ", callerBci());
|
||||
method().printShortName(st);
|
||||
st.println();
|
||||
|
||||
GrowableArray<InlineTree> subt = subtrees();
|
||||
for (int i = 0 ; i < subt.length(); i++) {
|
||||
subt.at(i).printImpl(st, indent + 2);
|
||||
}
|
||||
}
|
||||
public void print(PrintStream st) {
|
||||
printImpl(st, 2);
|
||||
}
|
||||
|
||||
// Count number of nodes in this subtree
|
||||
public int count() {
|
||||
int result = 1;
|
||||
GrowableArray<InlineTree> subt = subtrees();
|
||||
for (int i = 0 ; i < subt.length(); i++) {
|
||||
result += subt.at(i).count();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public void dumpReplayData(PrintStream out) {
|
||||
out.printf(" %d %d ", inlineLevel(), callerBci());
|
||||
Method method = (Method)method().getMetadata();
|
||||
Klass holder = method.getMethodHolder();
|
||||
out.print(holder.getName().asString() + " " +
|
||||
OopUtilities.escapeString(method.getName().asString()) + " " +
|
||||
method.getSignature().asString());
|
||||
|
||||
GrowableArray<InlineTree> subt = subtrees();
|
||||
for (int i = 0 ; i < subt.length(); i++) {
|
||||
subt.at(i).dumpReplayData(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,112 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.ci.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class JVMState extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("JVMState");
|
||||
mapField = type.getAddressField("_map");
|
||||
methodField = type.getAddressField("_method");
|
||||
bciField = new CIntField(type.getCIntegerField("_bci"), 0);
|
||||
spField = new CIntField(type.getCIntegerField("_sp"), 0);
|
||||
endoffField = new CIntField(type.getCIntegerField("_endoff"), 0);
|
||||
try {
|
||||
scloffField = new CIntField(type.getCIntegerField("_scloff"), 0);
|
||||
} catch (Exception e) {
|
||||
}
|
||||
monoffField = new CIntField(type.getCIntegerField("_monoff"), 0);
|
||||
stkoffField = new CIntField(type.getCIntegerField("_stkoff"), 0);
|
||||
locoffField = new CIntField(type.getCIntegerField("_locoff"), 0);
|
||||
depthField = new CIntField(type.getCIntegerField("_depth"), 0);
|
||||
callerField = type.getAddressField("_caller");
|
||||
}
|
||||
|
||||
private static AddressField mapField;
|
||||
private static AddressField methodField;
|
||||
private static CIntField bciField;
|
||||
private static CIntField spField;
|
||||
private static CIntField endoffField;
|
||||
private static CIntField scloffField;
|
||||
private static CIntField monoffField;
|
||||
private static CIntField stkoffField;
|
||||
private static CIntField locoffField;
|
||||
private static CIntField depthField;
|
||||
private static AddressField callerField;
|
||||
|
||||
public static JVMState create(Address addr) {
|
||||
if (addr == null) return null;
|
||||
return new JVMState(addr);
|
||||
}
|
||||
|
||||
public JVMState(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public ciMethod method() {
|
||||
return (ciMethod) ciObjectFactory.getMetadata(methodField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public int bci() {
|
||||
return (int)bciField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public int depth() {
|
||||
return (int)depthField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public JVMState caller() {
|
||||
return create(callerField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
ciMethod m = method();
|
||||
if (m != null) {
|
||||
Method meth = m.method();
|
||||
out.print(" " + meth.getMethodHolder().getName().asString().replace('/', '.') + "::" +
|
||||
meth.getName().asString() + " @ bci:" + bci());
|
||||
} else {
|
||||
out.print(" runtime stub");
|
||||
}
|
||||
if (caller() != null) caller().dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class LoopNode extends RegionNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("LoopNode");
|
||||
}
|
||||
|
||||
|
||||
public LoopNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,72 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.ci.ciMethod;
|
||||
import sun.jvm.hotspot.ci.ciObjectFactory;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachCallJavaNode extends MachCallNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachCallJavaNode");
|
||||
methodField = type.getAddressField("_method");
|
||||
bciField = new CIntField(type.getCIntegerField("_bci"), 0);
|
||||
}
|
||||
|
||||
private static AddressField methodField;
|
||||
private static CIntField bciField;
|
||||
|
||||
public ciMethod method() {
|
||||
return (ciMethod) ciObjectFactory.getMetadata(methodField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public MachCallJavaNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream st) {
|
||||
ciMethod m = method();
|
||||
if (m != null) {
|
||||
m.printShortName(st);
|
||||
st.print(" ");
|
||||
}
|
||||
super.dumpSpec(st);
|
||||
}
|
||||
}
|
||||
@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachCallNode extends MachSafePointNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachCallNode");
|
||||
}
|
||||
|
||||
public MachCallNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream st) {
|
||||
st.print("# ");
|
||||
// tf()->dump_on(st);
|
||||
// if (_cnt != COUNT_UNKNOWN) st->print(" C=%f",_cnt);
|
||||
if (jvms() != null) jvms().dumpSpec(st);
|
||||
}
|
||||
}
|
||||
@ -1,65 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.CStringUtilities;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachCallRuntimeNode extends MachCallJavaNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachCallRuntimeNode");
|
||||
nameField = type.getAddressField("_name");
|
||||
}
|
||||
|
||||
private static AddressField nameField;
|
||||
|
||||
public String name() {
|
||||
return CStringUtilities.getString(nameField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public MachCallRuntimeNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
out.printf("%s ", name());
|
||||
super.dumpSpec(out);
|
||||
}
|
||||
}
|
||||
@ -1,71 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.CStringUtilities;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachCallStaticJavaNode extends MachCallJavaNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachCallStaticJavaNode");
|
||||
nameField = type.getAddressField("_name");
|
||||
}
|
||||
|
||||
private static AddressField nameField;
|
||||
|
||||
public String name() {
|
||||
return CStringUtilities.getString(nameField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public MachCallStaticJavaNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream st) {
|
||||
st.print("Static ");
|
||||
String n = name();
|
||||
if (n != null) {
|
||||
st.printf("wrapper for: %s", n);
|
||||
// dump_trap_args(st);
|
||||
st.print(" ");
|
||||
}
|
||||
super.dumpSpec(st);
|
||||
}
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachIfNode extends MachNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachIfNode");
|
||||
probField = type.getJFloatField("_prob");
|
||||
fcntField = type.getJFloatField("_fcnt");
|
||||
}
|
||||
|
||||
private static JFloatField probField;
|
||||
private static JFloatField fcntField;
|
||||
|
||||
float prob() {
|
||||
return probField.getValue(getAddress());
|
||||
}
|
||||
|
||||
float cnt() {
|
||||
return fcntField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public MachIfNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
out.print("P=" + prob() + ", C=" + cnt());
|
||||
}
|
||||
}
|
||||
@ -1,51 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachNode extends Node {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachNode");
|
||||
}
|
||||
|
||||
public MachNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,51 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachReturnNode extends MachNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachReturnNode");
|
||||
}
|
||||
|
||||
public MachReturnNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MachSafePointNode extends MachReturnNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MachSafePointNode");
|
||||
jvmsField = type.getAddressField("_jvms");
|
||||
jvmadjField = new CIntField(type.getCIntegerField("_jvmadj"), 0);
|
||||
}
|
||||
|
||||
private static AddressField jvmsField;
|
||||
private static CIntField jvmadjField;
|
||||
|
||||
public MachSafePointNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public JVMState jvms() {
|
||||
return JVMState.create(jvmsField.getValue(getAddress()));
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
try {
|
||||
JVMState jvms = jvms();
|
||||
if (jvms != null) out.print(" !");
|
||||
if (jvms == null) out.print("empty jvms");
|
||||
while (jvms != null) {
|
||||
Method m = jvms.method().method();
|
||||
int bci = jvms.bci();
|
||||
out.print(" " + m.getMethodHolder().getName().asString().replace('/', '.') + "::" + m.getName().asString() + " @ bci:" + bci);
|
||||
jvms = jvms.caller();
|
||||
}
|
||||
} catch (Exception e) {
|
||||
out.print(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class MultiNode extends Node {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("MultiNode");
|
||||
}
|
||||
|
||||
|
||||
public MultiNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,271 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.io.*;
|
||||
import java.lang.reflect.Constructor;
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Node extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Node");
|
||||
outmaxField = new CIntField(type.getCIntegerField("_outmax"), 0);
|
||||
outcntField = new CIntField(type.getCIntegerField("_outcnt"), 0);
|
||||
maxField = new CIntField(type.getCIntegerField("_max"), 0);
|
||||
cntField = new CIntField(type.getCIntegerField("_cnt"), 0);
|
||||
idxField = new CIntField(type.getCIntegerField("_idx"), 0);
|
||||
outField = type.getAddressField("_out");
|
||||
inField = type.getAddressField("_in");
|
||||
|
||||
nodeType = db.lookupType("Node");
|
||||
|
||||
virtualConstructor = new VirtualBaseConstructor<>(db, nodeType, "sun.jvm.hotspot.opto", Node.class);
|
||||
}
|
||||
|
||||
private static CIntField outmaxField;
|
||||
private static CIntField outcntField;
|
||||
private static CIntField maxField;
|
||||
private static CIntField cntField;
|
||||
private static CIntField idxField;
|
||||
private static AddressField outField;
|
||||
private static AddressField inField;
|
||||
|
||||
private static VirtualBaseConstructor<Node> virtualConstructor;
|
||||
|
||||
private static Type nodeType;
|
||||
|
||||
static HashMap<Address, Node> nodes = new HashMap<>();
|
||||
|
||||
static HashMap constructors = new HashMap();
|
||||
|
||||
abstract static class Instantiator {
|
||||
abstract Node create(Address addr);
|
||||
}
|
||||
|
||||
public static Node create(Address addr) {
|
||||
if (addr == null) return null;
|
||||
Node result = nodes.get(addr);
|
||||
if (result == null) {
|
||||
result = virtualConstructor.instantiateWrapperFor(addr);
|
||||
nodes.put(addr, result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public Node(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int outcnt() {
|
||||
return (int)outcntField.getValue(this.getAddress());
|
||||
}
|
||||
|
||||
public int req() {
|
||||
return (int)cntField.getValue(this.getAddress());
|
||||
}
|
||||
|
||||
public int len() {
|
||||
return (int)maxField.getValue(this.getAddress());
|
||||
}
|
||||
|
||||
public int idx() {
|
||||
return (int)idxField.getValue(this.getAddress());
|
||||
}
|
||||
|
||||
private Node[] _out;
|
||||
private Node[] _in;
|
||||
|
||||
public Node rawOut(int i) {
|
||||
if (_out == null) {
|
||||
int addressSize = (int)VM.getVM().getAddressSize();
|
||||
_out = new Node[outcnt()];
|
||||
Address ptr = outField.getValue(this.getAddress());
|
||||
for (int j = 0; j < outcnt(); j++) {
|
||||
_out[j] = Node.create(ptr.getAddressAt(j * addressSize));
|
||||
}
|
||||
}
|
||||
return _out[i];
|
||||
}
|
||||
|
||||
public Node in(int i) {
|
||||
if (_in == null) {
|
||||
int addressSize = (int)VM.getVM().getAddressSize();
|
||||
_in = new Node[len()];
|
||||
Address ptr = inField.getValue(this.getAddress());
|
||||
for (int j = 0; j < len(); j++) {
|
||||
_in[j] = Node.create(ptr.getAddressAt(j * addressSize));
|
||||
}
|
||||
}
|
||||
return _in[i];
|
||||
}
|
||||
|
||||
public ArrayList<Node> collect(int d, boolean onlyCtrl) {
|
||||
int depth = Math.abs(d);
|
||||
ArrayList<Node> nstack = new ArrayList<>();
|
||||
BitSet set = new BitSet();
|
||||
|
||||
nstack.add(this);
|
||||
set.set(idx());
|
||||
int begin = 0;
|
||||
int end = 0;
|
||||
for (int i = 0; i < depth; i++) {
|
||||
end = nstack.size();
|
||||
for(int j = begin; j < end; j++) {
|
||||
Node tp = nstack.get(j);
|
||||
int limit = d > 0 ? tp.len() : tp.outcnt();
|
||||
for(int k = 0; k < limit; k++) {
|
||||
Node n = d > 0 ? tp.in(k) : tp.rawOut(k);
|
||||
|
||||
// if (not_a_node(n)) continue;
|
||||
if (n == null) continue;
|
||||
// do not recurse through top or the root (would reach unrelated stuff)
|
||||
// if (n.isRoot() || n.isTop()) continue;
|
||||
// if (onlyCtrl && !n.isCfg()) continue;
|
||||
|
||||
if (!set.get(n.idx())) {
|
||||
nstack.add(n);
|
||||
set.set(n.idx());
|
||||
}
|
||||
}
|
||||
}
|
||||
begin = end;
|
||||
}
|
||||
return nstack;
|
||||
}
|
||||
|
||||
protected void dumpNodes(Node s, int d, boolean onlyCtrl, PrintStream out) {
|
||||
if (s == null) return;
|
||||
|
||||
ArrayList nstack = s.collect(d, onlyCtrl);
|
||||
int end = nstack.size();
|
||||
if (d > 0) {
|
||||
for(int j = end-1; j >= 0; j--) {
|
||||
((Node)nstack.get(j)).dump(out);
|
||||
}
|
||||
} else {
|
||||
for(int j = 0; j < end; j++) {
|
||||
((Node)nstack.get(j)).dump(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void dump(int depth, PrintStream out) {
|
||||
dumpNodes(this, depth, false, out);
|
||||
}
|
||||
|
||||
public String Name() {
|
||||
Type t = VM.getVM().getTypeDataBase().findDynamicTypeForAddress(getAddress(), nodeType);
|
||||
String name = null;
|
||||
if (t != null) {
|
||||
name = t.toString();
|
||||
} else {
|
||||
Class c = getClass();
|
||||
if (c == Node.class) {
|
||||
// couldn't identify class type
|
||||
return "UnknownNode<" + getAddress().getAddressAt(0) + ">";
|
||||
}
|
||||
name = getClass().getName();
|
||||
if (name.startsWith("sun.jvm.hotspot.opto.")) {
|
||||
name = name.substring("sun.jvm.hotspot.opto.".length());
|
||||
}
|
||||
}
|
||||
if (name.endsWith("Node")) {
|
||||
return name.substring(0, name.length() - 4);
|
||||
}
|
||||
return name;
|
||||
}
|
||||
|
||||
public void dump(PrintStream out) {
|
||||
out.print(" ");
|
||||
out.print(idx());
|
||||
out.print("\t");
|
||||
out.print(Name());
|
||||
out.print("\t=== ");
|
||||
int i = 0;
|
||||
for (i = 0; i < req(); i++) {
|
||||
Node n = in(i);
|
||||
if (n != null) {
|
||||
out.print(' ');
|
||||
out.print(in(i).idx());
|
||||
} else {
|
||||
out.print("_");
|
||||
}
|
||||
out.print(" ");
|
||||
}
|
||||
if (len() != req()) {
|
||||
int prec = 0;
|
||||
for (; i < len(); i++) {
|
||||
Node n = in(i);
|
||||
if (n != null) {
|
||||
if (prec++ == 0) {
|
||||
out.print("| ");
|
||||
}
|
||||
out.print(in(i).idx());
|
||||
}
|
||||
out.print(" ");
|
||||
}
|
||||
}
|
||||
dumpOut(out);
|
||||
dumpSpec(out);
|
||||
out.println();
|
||||
}
|
||||
|
||||
void dumpOut(PrintStream out) {
|
||||
// Delimit the output edges
|
||||
out.print(" [[");
|
||||
// Dump the output edges
|
||||
for (int i = 0; i < outcnt(); i++) { // For all outputs
|
||||
Node u = rawOut(i);
|
||||
if (u == null) {
|
||||
out.print("_ ");
|
||||
// } else if (not_a_node(u)) {
|
||||
// out.print("not_a_node ");
|
||||
} else {
|
||||
// out.print("%c%d ", Compile::current()->nodeArena()->contains(u) ? ' ' : 'o', u->_idx);
|
||||
out.print(' ');
|
||||
out.print(u.idx());
|
||||
out.print(' ');
|
||||
}
|
||||
}
|
||||
out.print("]] ");
|
||||
}
|
||||
|
||||
public void dumpSpec(PrintStream out) {
|
||||
}
|
||||
}
|
||||
@ -1,66 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Node_Array extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Node_Array");
|
||||
maxField = new CIntField(type.getCIntegerField("_max"), 0);
|
||||
nodesField = type.getAddressField("_nodes");
|
||||
aField = type.getAddressField("_a");
|
||||
}
|
||||
|
||||
private static CIntField maxField;
|
||||
private static AddressField nodesField;
|
||||
private static AddressField aField;
|
||||
|
||||
public Node_Array(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int Size() {
|
||||
return (int) maxField.getValue(getAddress());
|
||||
}
|
||||
|
||||
public Node at(int i) {
|
||||
return Node.create(nodesField.getValue(getAddress()).getAddressAt(i * (int)VM.getVM().getAddressSize()));
|
||||
}
|
||||
}
|
||||
@ -1,58 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Node_List extends Node_Array {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Node_List");
|
||||
cntField = new CIntField(type.getCIntegerField("_cnt"), 0);
|
||||
}
|
||||
|
||||
private static CIntField cntField;
|
||||
|
||||
public Node_List(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public int size() {
|
||||
return (int) cntField.getValue(getAddress());
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class Phase extends VMObject {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("Phase");
|
||||
}
|
||||
|
||||
|
||||
public Phase(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,71 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.PrintStream;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class PhaseCFG extends Phase {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("PhaseCFG");
|
||||
numBlocksField = new CIntField(type.getCIntegerField("_number_of_blocks"), 0);
|
||||
blocksField = type.getAddressField("_blocks");
|
||||
bbsField = type.getAddressField("_node_to_block_mapping");
|
||||
brootField = type.getAddressField("_root_block");
|
||||
}
|
||||
|
||||
private static CIntField numBlocksField;
|
||||
private static AddressField blocksField;
|
||||
private static AddressField bbsField;
|
||||
private static AddressField brootField;
|
||||
|
||||
public PhaseCFG(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
|
||||
public void dump(PrintStream out) {
|
||||
int addressSize = (int)VM.getVM().getAddressSize();
|
||||
int numBlocks = (int)numBlocksField.getValue(getAddress());
|
||||
Block_List blocks = new Block_List(getAddress().addOffsetTo(blocksField.getOffset()));
|
||||
int offset = 0;
|
||||
for (int i = 0; i < numBlocks; i++) {
|
||||
blocks.at(i).dump(out);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,60 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class PhaseRegAlloc extends Phase {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("PhaseRegAlloc");
|
||||
nodeRegsField = type.getAddressField("_node_regs");
|
||||
nodeRegsMaxIndexField = new CIntField(type.getCIntegerField("_node_regs_max_index"), 0);
|
||||
framesizeField = new CIntField(type.getCIntegerField("_framesize"), 0);
|
||||
maxRegField = new CIntField(type.getCIntegerField("_max_reg"), 0);
|
||||
}
|
||||
|
||||
private static AddressField nodeRegsField;
|
||||
private static CIntField nodeRegsMaxIndexField;
|
||||
private static CIntField framesizeField;
|
||||
private static CIntField maxRegField;
|
||||
|
||||
public PhaseRegAlloc(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class PhiNode extends TypeNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("PhiNode");
|
||||
}
|
||||
|
||||
|
||||
public PhiNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class ProjNode extends Node {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("ProjNode");
|
||||
}
|
||||
|
||||
|
||||
public ProjNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class RegionNode extends Node {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("RegionNode");
|
||||
}
|
||||
|
||||
|
||||
public RegionNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
@ -1,52 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
package sun.jvm.hotspot.opto;
|
||||
|
||||
import java.util.*;
|
||||
import sun.jvm.hotspot.debugger.*;
|
||||
import sun.jvm.hotspot.runtime.*;
|
||||
import sun.jvm.hotspot.oops.*;
|
||||
import sun.jvm.hotspot.types.*;
|
||||
import sun.jvm.hotspot.utilities.Observable;
|
||||
import sun.jvm.hotspot.utilities.Observer;
|
||||
|
||||
public class RootNode extends LoopNode {
|
||||
static {
|
||||
VM.registerVMInitializedObserver(new Observer() {
|
||||
public void update(Observable o, Object data) {
|
||||
initialize(VM.getVM().getTypeDataBase());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static synchronized void initialize(TypeDataBase db) throws WrongTypeException {
|
||||
Type type = db.lookupType("RootNode");
|
||||
}
|
||||
|
||||
|
||||
public RootNode(Address addr) {
|
||||
super(addr);
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user