mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 06:45:07 +02:00
7016112: CMS: crash during promotion testing
Also reviewed by mikael.gerdin@oracle.com; stdlib:qsort() does byte-by-byte swapping on Windows. This leads to pointer shearing. Fix is to implement a quicksort that does full pointer updates. Reviewed-by: never, coleenp, ysr
This commit is contained in:
parent
4597e4c7a8
commit
3aaa5fb06d
5 changed files with 394 additions and 58 deletions
|
@ -3296,6 +3296,19 @@ _JNI_IMPORT_OR_EXPORT_ jint JNICALL JNI_GetDefaultJavaVMInitArgs(void *args_) {
|
|||
return ret;
|
||||
}
|
||||
|
||||
#ifndef PRODUCT
|
||||
|
||||
#include "utilities/quickSort.hpp"
|
||||
|
||||
void execute_internal_vm_tests() {
|
||||
if (ExecuteInternalVMTests) {
|
||||
assert(QuickSort::test_quick_sort(), "test_quick_sort failed");
|
||||
tty->print_cr("All tests passed");
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
HS_DTRACE_PROBE_DECL3(hotspot_jni, CreateJavaVM__entry, vm, penv, args);
|
||||
DT_RETURN_MARK_DECL(CreateJavaVM, jint);
|
||||
|
||||
|
@ -3386,6 +3399,7 @@ _JNI_IMPORT_OR_EXPORT_ jint JNICALL JNI_CreateJavaVM(JavaVM **vm, void **penv, v
|
|||
}
|
||||
|
||||
NOT_PRODUCT(test_error_handler(ErrorHandlerTest));
|
||||
NOT_PRODUCT(execute_internal_vm_tests());
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue