src/os_cpu/bsd_x86/vm/os_bsd_x86.cpp

Print this page
rev 3149 : 7147740: add assertions to check stack alignment on VM entry from generated code (x64)
Summary: check stack alignment on VM entry on x64.
Reviewed-by:


1109   st->print("EAX="); print_location(st, uc->context_eax);
1110   st->print("EBX="); print_location(st, uc->context_ebx);
1111   st->print("ECX="); print_location(st, uc->context_ecx);
1112   st->print("EDX="); print_location(st, uc->context_edx);
1113   st->print("ESP="); print_location(st, uc->context_esp);
1114   st->print("EBP="); print_location(st, uc->context_ebp);
1115   st->print("ESI="); print_location(st, uc->context_esi);
1116   st->print("EDI="); print_location(st, uc->context_edi);
1117 #endif // AMD64
1118 
1119   st->cr();
1120 }
1121 
1122 void os::setup_fpu() {
1123 #ifndef AMD64
1124   address fpu_cntrl = StubRoutines::addr_fpu_cntrl_wrd_std();
1125   __asm__ volatile (  "fldcw (%0)" :
1126                       : "r" (fpu_cntrl) : "memory");
1127 #endif // !AMD64
1128 }







1109   st->print("EAX="); print_location(st, uc->context_eax);
1110   st->print("EBX="); print_location(st, uc->context_ebx);
1111   st->print("ECX="); print_location(st, uc->context_ecx);
1112   st->print("EDX="); print_location(st, uc->context_edx);
1113   st->print("ESP="); print_location(st, uc->context_esp);
1114   st->print("EBP="); print_location(st, uc->context_ebp);
1115   st->print("ESI="); print_location(st, uc->context_esi);
1116   st->print("EDI="); print_location(st, uc->context_edi);
1117 #endif // AMD64
1118 
1119   st->cr();
1120 }
1121 
1122 void os::setup_fpu() {
1123 #ifndef AMD64
1124   address fpu_cntrl = StubRoutines::addr_fpu_cntrl_wrd_std();
1125   __asm__ volatile (  "fldcw (%0)" :
1126                       : "r" (fpu_cntrl) : "memory");
1127 #endif // !AMD64
1128 }
1129 
1130 #ifndef PRODUCT
1131 void os::verify_stack_alignment() {
1132 }
1133 #endif