Mercurial > hg > graal-jvmci-8
diff c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotRegisterConfig.java @ 1448:9196a2b32950
Modified C++ to reflect changes in calling convention CRI code.
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Tue, 09 Nov 2010 17:40:15 +0100 |
parents | 4d1d3bd140f9 |
children | 43a93774d24f |
line wrap: on
line diff
--- a/c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotRegisterConfig.java Tue Nov 09 17:38:40 2010 +0100 +++ b/c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotRegisterConfig.java Tue Nov 09 17:40:15 2010 +0100 @@ -96,18 +96,18 @@ } @Override - public CiCallingConvention getCallingConvention(Type type, CiKind[] parameters, boolean outgoing, CiTarget target) { - if (type == Type.Native) { + public CiCallingConvention getCallingConvention(Type type, CiKind[] parameters, CiTarget target) { + if (type == Type.NativeCall) { throw new UnsupportedOperationException(); } - return callingConvention(parameters, type == Type.Runtime ? true : outgoing, target); + return callingConvention(parameters, type, target); } public CiRegister[] getCallingConventionRegisters(Type type) { return allParameterRegisters; } - private CiCallingConvention callingConvention(CiKind[] types, boolean outgoing, CiTarget target) { + private CiCallingConvention callingConvention(CiKind[] types, Type type, CiTarget target) { CiValue[] locations = new CiValue[types.length]; int currentGeneral = 0; @@ -144,7 +144,7 @@ if (locations[i] == null) { // we need to adjust for the frame pointer stored on the stack, which shifts incoming arguments by one slot - locations[i] = CiStackSlot.get(kind.stackKind(), currentStackIndex + (outgoing ? 0 : 1), !outgoing); + locations[i] = CiStackSlot.get(kind.stackKind(), currentStackIndex + (type.out ? 0 : 1), !type.out); currentStackIndex += target.spillSlots(kind); } }