49 pushq(r11);
50
51 movl(c_rarg0, ThreadLocalStorage::thread_index());
52 call(RuntimeAddress((address)TlsGetValue));
53
54 popq(r11);
55 popq(rsp);
56 popq(r10);
57 popq(r9);
58 popq(r8);
59 popq(rcx);
60 popq(rdx);
61 popq(rsi);
62 popq(rdi);
63 if (thread != rax) {
64 movq(thread, rax);
65 popq(rax);
66 }
67 }
68
69 bool MacroAssembler::needs_explicit_null_check(int offset) {
70 return offset < 0 || (int)os::vm_page_size() <= offset;
71 }
|
49 pushq(r11);
50
51 movl(c_rarg0, ThreadLocalStorage::thread_index());
52 call(RuntimeAddress((address)TlsGetValue));
53
54 popq(r11);
55 popq(rsp);
56 popq(r10);
57 popq(r9);
58 popq(r8);
59 popq(rcx);
60 popq(rdx);
61 popq(rsi);
62 popq(rdi);
63 if (thread != rax) {
64 movq(thread, rax);
65 popq(rax);
66 }
67 }
68
69 bool MacroAssembler::needs_explicit_null_check(intptr_t offset) {
70 if (UseCompressedOops) {
71 uintptr_t heap_base = (uintptr_t)Universe::heap_base();
72 if ((uintptr_t)offset >= heap_base) {
73 offset = (intptr_t)(pointer_delta((void*)offset, (void*)heap_base, 1));
74 }
75 }
76 return offset < 0 || os::vm_page_size() <= offset;
77 }
|