mirror of
https://github.com/openjdk/jdk.git
synced 2026-07-14 21:19:00 +00:00
8388120: [s390x] c2: c_return_value is redundant
Reviewed-by: amitkumar, rrich
This commit is contained in:
parent
bc1bd75e7b
commit
0dcfa722aa
@ -2617,28 +2617,31 @@ frame %{
|
||||
// stack slot.
|
||||
return_addr(REG Z_R14);
|
||||
|
||||
// Location of native (C/C++) and interpreter return values. This
|
||||
// is specified to be the same as Java. In the 32-bit VM, long
|
||||
// values are actually returned from native calls in O0:O1 and
|
||||
// returned to the interpreter in I0:I1. The copying to and from
|
||||
// the register pairs is done by the appropriate call and epilog
|
||||
// opcodes. This simplifies the register allocator.
|
||||
//
|
||||
// Use register pair for c return value.
|
||||
c_return_value %{
|
||||
assert(ideal_reg >= Op_RegI && ideal_reg <= Op_RegL, "only return normal values");
|
||||
static int typeToRegLo[Op_RegL+1] = { 0, 0, Z_R2_num, Z_R2_num, Z_R2_num, Z_F0_num, Z_F0_num, Z_R2_num };
|
||||
static int typeToRegHi[Op_RegL+1] = { 0, 0, OptoReg::Bad, OptoReg::Bad, Z_R2_H_num, OptoReg::Bad, Z_F0_H_num, Z_R2_H_num };
|
||||
return OptoRegPair(typeToRegHi[ideal_reg], typeToRegLo[ideal_reg]);
|
||||
%}
|
||||
|
||||
// Use register pair for return value.
|
||||
// Location of compiled Java return values. Same as C
|
||||
return_value %{
|
||||
assert(ideal_reg >= Op_RegI && ideal_reg <= Op_RegL, "only return normal values");
|
||||
static int typeToRegLo[Op_RegL+1] = { 0, 0, Z_R2_num, Z_R2_num, Z_R2_num, Z_F0_num, Z_F0_num, Z_R2_num };
|
||||
static int typeToRegHi[Op_RegL+1] = { 0, 0, OptoReg::Bad, OptoReg::Bad, Z_R2_H_num, OptoReg::Bad, Z_F0_H_num, Z_R2_H_num };
|
||||
return OptoRegPair(typeToRegHi[ideal_reg], typeToRegLo[ideal_reg]);
|
||||
static const int lo[Op_RegL + 1] = {
|
||||
0,
|
||||
0,
|
||||
Z_R2_num, // Op_RegN
|
||||
Z_R2_num, // Op_RegI
|
||||
Z_R2_num, // Op_RegP
|
||||
Z_F0_num, // Op_RegF
|
||||
Z_F0_num, // Op_RegD
|
||||
Z_R2_num // Op_RegL
|
||||
};
|
||||
static const int hi[Op_RegL + 1] = {
|
||||
0,
|
||||
0,
|
||||
OptoReg::Bad, // Op_RegN
|
||||
OptoReg::Bad, // Op_RegI
|
||||
Z_R2_H_num, // Op_RegP
|
||||
OptoReg::Bad, // Op_RegF
|
||||
Z_F0_H_num, // Op_RegD
|
||||
Z_R2_H_num // Op_RegL
|
||||
};
|
||||
return OptoRegPair(hi[ideal_reg], lo[ideal_reg]);
|
||||
%}
|
||||
%}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user