src/os_cpu/solaris_x86/vm/solaris_x86_64.il

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:


  13 // accompanied this code).
  14 //
  15 // You should have received a copy of the GNU General Public License version
  16 // 2 along with this work; if not, write to the Free Software Foundation,
  17 // Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18 //
  19 // Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20 // or visit www.oracle.com if you need additional information or have any
  21 // questions.
  22 //  
  23 //
  24 
  25   // The argument size of each inline directive is ignored by the compiler
  26   // and is set to the number of arguments as documentation.
  27 
  28   // Get the raw thread ID from %gs:0
  29       .inline _raw_thread_id,0
  30       movq     %fs:0, %rax 
  31       .end
  32 






  33   // Get current fp
  34       .inline _get_current_fp,0
  35       .volatile
  36       movq     %rbp, %rax 
  37       .end
  38 
  39   // Support for os::rdtsc()
  40       .inline _raw_rdtsc,0
  41       rdtsc
  42       salq     $32, %rdx
  43       orq      %rdx, %rax
  44       .end
  45 
  46   // Support for jint Atomic::add(jint add_value, volatile jint* dest)
  47       .inline _Atomic_add,2
  48       movl     %edi, %eax      // save add_value for return
  49       lock
  50       xaddl    %edi, (%rsi)
  51       addl     %edi, %eax
  52       .end




  13 // accompanied this code).
  14 //
  15 // You should have received a copy of the GNU General Public License version
  16 // 2 along with this work; if not, write to the Free Software Foundation,
  17 // Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18 //
  19 // Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20 // or visit www.oracle.com if you need additional information or have any
  21 // questions.
  22 //  
  23 //
  24 
  25   // The argument size of each inline directive is ignored by the compiler
  26   // and is set to the number of arguments as documentation.
  27 
  28   // Get the raw thread ID from %gs:0
  29       .inline _raw_thread_id,0
  30       movq     %fs:0, %rax 
  31       .end
  32 
  33   // Get current sp
  34       .inline _get_current_sp,0
  35       .volatile
  36       movq     %rbp, %rax 
  37       .end
  38 
  39   // Get current fp
  40       .inline _get_current_fp,0
  41       .volatile
  42       movq     %rbp, %rax 
  43       .end
  44 
  45   // Support for os::rdtsc()
  46       .inline _raw_rdtsc,0
  47       rdtsc
  48       salq     $32, %rdx
  49       orq      %rdx, %rax
  50       .end
  51 
  52   // Support for jint Atomic::add(jint add_value, volatile jint* dest)
  53       .inline _Atomic_add,2
  54       movl     %edi, %eax      // save add_value for return
  55       lock
  56       xaddl    %edi, (%rsi)
  57       addl     %edi, %eax
  58       .end