Mercurial > hg > graal-compiler
comparison src/cpu/sparc/vm/sharedRuntime_sparc.cpp @ 6792:137868b7aa6f
7196199: java/text/Bidi/Bug6665028.java failed: Bidi run count incorrect
Summary: Save whole XMM/YMM registers in safepoint interrupt handler.
Reviewed-by: roland, twisti
author | kvn |
---|---|
date | Mon, 17 Sep 2012 19:39:07 -0700 |
parents | 2cb2f30450c7 |
children | 18fb7da42534 |
comparison
equal
deleted
inserted
replaced
6791:8d3cc6612bd1 | 6792:137868b7aa6f |
---|---|
309 // Now reload the 64bit Oregs after we've restore the window. | 309 // Now reload the 64bit Oregs after we've restore the window. |
310 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8, O0); | 310 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8, O0); |
311 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8, O1); | 311 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8, O1); |
312 #endif /* _LP64 */ | 312 #endif /* _LP64 */ |
313 | 313 |
314 } | |
315 | |
316 // Is vector's size (in bytes) bigger than a size saved by default? | |
317 // 8 bytes FP registers are saved by default on SPARC. | |
318 bool SharedRuntime::is_wide_vector(int size) { | |
319 // Note, MaxVectorSize == 8 on SPARC. | |
320 assert(size <= 8, err_msg_res("%d bytes vectors are not supported", size)); | |
321 return size > 8; | |
314 } | 322 } |
315 | 323 |
316 // The java_calling_convention describes stack locations as ideal slots on | 324 // The java_calling_convention describes stack locations as ideal slots on |
317 // a frame with no abi restrictions. Since we must observe abi restrictions | 325 // a frame with no abi restrictions. Since we must observe abi restrictions |
318 // (like the placement of the register window) the slots must be biased by | 326 // (like the placement of the register window) the slots must be biased by |
3732 // the adjusted FP off to the GC stack-crawler: this will modify the caller's | 3740 // the adjusted FP off to the GC stack-crawler: this will modify the caller's |
3733 // SP and mess up HIS OopMaps. So we first adjust the caller's SP, then save | 3741 // SP and mess up HIS OopMaps. So we first adjust the caller's SP, then save |
3734 // the 64-bit %o's, then do a save, then fixup the caller's SP (our FP). | 3742 // the 64-bit %o's, then do a save, then fixup the caller's SP (our FP). |
3735 // Tricky, tricky, tricky... | 3743 // Tricky, tricky, tricky... |
3736 | 3744 |
3737 SafepointBlob* SharedRuntime::generate_handler_blob(address call_ptr, bool cause_return) { | 3745 SafepointBlob* SharedRuntime::generate_handler_blob(address call_ptr, int poll_type) { |
3738 assert (StubRoutines::forward_exception_entry() != NULL, "must be generated before"); | 3746 assert (StubRoutines::forward_exception_entry() != NULL, "must be generated before"); |
3739 | 3747 |
3740 // allocate space for the code | 3748 // allocate space for the code |
3741 ResourceMark rm; | 3749 ResourceMark rm; |
3742 // setup code generation tools | 3750 // setup code generation tools |
3750 OopMapSet *oop_maps = new OopMapSet(); | 3758 OopMapSet *oop_maps = new OopMapSet(); |
3751 OopMap* map = NULL; | 3759 OopMap* map = NULL; |
3752 | 3760 |
3753 int start = __ offset(); | 3761 int start = __ offset(); |
3754 | 3762 |
3763 bool cause_return = (poll_type == POLL_AT_RETURN); | |
3755 // If this causes a return before the processing, then do a "restore" | 3764 // If this causes a return before the processing, then do a "restore" |
3756 if (cause_return) { | 3765 if (cause_return) { |
3757 __ restore(); | 3766 __ restore(); |
3758 } else { | 3767 } else { |
3759 // Make it look like we were called via the poll | 3768 // Make it look like we were called via the poll |