comparison src/cpu/x86/vm/x86_32.ad @ 1579:e9ff18c4ace7

Merge
author jrose
date Wed, 02 Jun 2010 22:45:42 -0700
parents c18cbe5936b8 3657cb01ffc5
children f55c4f82ab9d
comparison
equal deleted inserted replaced
1562:dfe27f03244a 1579:e9ff18c4ace7
1375 // Should the Matcher clone shifts on addressing modes, expecting them to 1375 // Should the Matcher clone shifts on addressing modes, expecting them to
1376 // be subsumed into complex addressing expressions or compute them into 1376 // be subsumed into complex addressing expressions or compute them into
1377 // registers? True for Intel but false for most RISCs 1377 // registers? True for Intel but false for most RISCs
1378 const bool Matcher::clone_shift_expressions = true; 1378 const bool Matcher::clone_shift_expressions = true;
1379 1379
1380 bool Matcher::narrow_oop_use_complex_address() {
1381 ShouldNotCallThis();
1382 return true;
1383 }
1384
1385
1380 // Is it better to copy float constants, or load them directly from memory? 1386 // Is it better to copy float constants, or load them directly from memory?
1381 // Intel can load a float constant from a direct address, requiring no 1387 // Intel can load a float constant from a direct address, requiring no
1382 // extra registers. Most RISCs will have to materialize an address into a 1388 // extra registers. Most RISCs will have to materialize an address into a
1383 // register first, so they would do better to copy the constant from stack. 1389 // register first, so they would do better to copy the constant from stack.
1384 const bool Matcher::rematerialize_float_constants = true; 1390 const bool Matcher::rematerialize_float_constants = true;
1839 enc_class preserve_SP %{ 1845 enc_class preserve_SP %{
1840 debug_only(int off0 = cbuf.code_size()); 1846 debug_only(int off0 = cbuf.code_size());
1841 MacroAssembler _masm(&cbuf); 1847 MacroAssembler _masm(&cbuf);
1842 // RBP is preserved across all calls, even compiled calls. 1848 // RBP is preserved across all calls, even compiled calls.
1843 // Use it to preserve RSP in places where the callee might change the SP. 1849 // Use it to preserve RSP in places where the callee might change the SP.
1844 __ movptr(rbp, rsp); 1850 __ movptr(rbp_mh_SP_save, rsp);
1845 debug_only(int off1 = cbuf.code_size()); 1851 debug_only(int off1 = cbuf.code_size());
1846 assert(off1 - off0 == preserve_SP_size(), "correct size prediction"); 1852 assert(off1 - off0 == preserve_SP_size(), "correct size prediction");
1847 %} 1853 %}
1848 1854
1849 enc_class restore_SP %{ 1855 enc_class restore_SP %{
1850 MacroAssembler _masm(&cbuf); 1856 MacroAssembler _masm(&cbuf);
1851 __ movptr(rsp, rbp); 1857 __ movptr(rsp, rbp_mh_SP_save);
1852 %} 1858 %}
1853 1859
1854 enc_class Java_Static_Call (method meth) %{ // JAVA STATIC CALL 1860 enc_class Java_Static_Call (method meth) %{ // JAVA STATIC CALL
1855 // CALL to fixup routine. Fixup routine uses ScopeDesc info to determine 1861 // CALL to fixup routine. Fixup routine uses ScopeDesc info to determine
1856 // who we intended to call. 1862 // who we intended to call.
13568 %} 13574 %}
13569 13575
13570 // Call Java Static Instruction (method handle version) 13576 // Call Java Static Instruction (method handle version)
13571 // Note: If this code changes, the corresponding ret_addr_offset() and 13577 // Note: If this code changes, the corresponding ret_addr_offset() and
13572 // compute_padding() functions will have to be adjusted. 13578 // compute_padding() functions will have to be adjusted.
13573 instruct CallStaticJavaHandle(method meth, eBPRegP ebp) %{ 13579 instruct CallStaticJavaHandle(method meth, eBPRegP ebp_mh_SP_save) %{
13574 match(CallStaticJava); 13580 match(CallStaticJava);
13575 predicate(((CallStaticJavaNode*)n)->is_method_handle_invoke()); 13581 predicate(((CallStaticJavaNode*)n)->is_method_handle_invoke());
13576 effect(USE meth); 13582 effect(USE meth);
13577 // EBP is saved by all callees (for interpreter stack correction). 13583 // EBP is saved by all callees (for interpreter stack correction).
13578 // We use it here for a similar purpose, in {preserve,restore}_SP. 13584 // We use it here for a similar purpose, in {preserve,restore}_SP.