mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 11:04:34 +02:00
7121373: Clean up CollectedHeap::is_in
Fixed G1CollectedHeap::is_in, added tests, cleaned up comments and made Space::is_in pure virtual. Reviewed-by: brutisso, tonyp, jcoomes
This commit is contained in:
parent
714e978aac
commit
a3943834e1
15 changed files with 54 additions and 32 deletions
|
@ -5037,16 +5037,25 @@ _JNI_IMPORT_OR_EXPORT_ jint JNICALL JNI_GetDefaultJavaVMInitArgs(void *args_) {
|
|||
|
||||
#ifndef PRODUCT
|
||||
|
||||
#include "gc_interface/collectedHeap.hpp"
|
||||
#include "utilities/quickSort.hpp"
|
||||
|
||||
#define run_unit_test(unit_test_function_call) \
|
||||
tty->print_cr("Running test: " #unit_test_function_call); \
|
||||
unit_test_function_call
|
||||
|
||||
void execute_internal_vm_tests() {
|
||||
if (ExecuteInternalVMTests) {
|
||||
assert(QuickSort::test_quick_sort(), "test_quick_sort failed");
|
||||
assert(arrayOopDesc::test_max_array_length(), "test_max_array_length failed");
|
||||
tty->print_cr("Running internal VM tests");
|
||||
run_unit_test(arrayOopDesc::test_max_array_length());
|
||||
run_unit_test(CollectedHeap::test_is_in());
|
||||
run_unit_test(QuickSort::test_quick_sort());
|
||||
tty->print_cr("All internal VM tests passed");
|
||||
}
|
||||
}
|
||||
|
||||
#undef run_unit_test
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef USDT2
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue