MCPcopy Create free account
hub / github.com/async-profiler/async-profiler / patchSafeFetch

Method patchSafeFetch

src/vmStructs.cpp:568–581  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

566}
567
568void VMStructs::patchSafeFetch() {
569 // Workarounds for JDK-8307549 and JDK-8321116
570 if (WX_MEMORY && VM::hotspot_version() == 17) {
571 void** entry = (void**)_libjvm->findSymbol("_ZN12StubRoutines18_safefetch32_entryE");
572 if (entry != NULL) {
573 *entry = (void*)SafeAccess::load32;
574 }
575 } else if (WX_MEMORY && VM::hotspot_version() == 11) {
576 void** entry = (void**)_libjvm->findSymbol("_ZN12StubRoutines17_safefetchN_entryE");
577 if (entry != NULL) {
578 *entry = (void*)SafeAccess::load;
579 }
580 }
581}
582
583void VMStructs::initTLS(void* vm_thread) {
584 for (int i = 0; i < 1024; i++) {

Callers

nothing calls this directly

Calls 1

findSymbolMethod · 0.80

Tested by

no test coverage detected