# HG changeset patch # User Doug Simon # Date 1368712900 -7200 # Node ID 2e4f035186cf397e911a25fa5633362fbc80d790 # Parent 1313dd590c6223ed5f6ead5aaface4ceba360d37 rename: Descriptor -> ForeignCallDescriptor diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/CodeCacheProvider.java --- a/graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/CodeCacheProvider.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/CodeCacheProvider.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.api.code; import com.oracle.graal.api.code.CompilationResult.DataPatch; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; /** @@ -70,7 +70,7 @@ /** * Gets the signature and linkage information for a runtime call. */ - RuntimeCallTarget lookupRuntimeCall(Descriptor descriptor); + RuntimeCallTarget lookupRuntimeCall(ForeignCallDescriptor descriptor); /** * Encodes a deoptimization action and a deoptimization reason in an integer value. diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/RuntimeCallTarget.java --- a/graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/RuntimeCallTarget.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/RuntimeCallTarget.java Thu May 16 16:01:40 2013 +0200 @@ -35,14 +35,14 @@ /** * The name and signature of a runtime call. */ - public static class Descriptor { + public static class ForeignCallDescriptor { private final String name; private final boolean hasSideEffect; private final Class resultType; private final Class[] argumentTypes; - public Descriptor(String name, boolean hasSideEffect, Class resultType, Class... argumentTypes) { + public ForeignCallDescriptor(String name, boolean hasSideEffect, Class resultType, Class... argumentTypes) { this.name = name; this.hasSideEffect = hasSideEffect; this.resultType = resultType; @@ -85,8 +85,8 @@ @Override public boolean equals(Object obj) { - if (obj instanceof Descriptor) { - Descriptor nas = (Descriptor) obj; + if (obj instanceof ForeignCallDescriptor) { + ForeignCallDescriptor nas = (ForeignCallDescriptor) obj; return nas.name.equals(name) && nas.resultType.equals(resultType) && Arrays.equals(nas.argumentTypes, argumentTypes); } return false; @@ -113,7 +113,7 @@ */ long getMaxCallTargetOffset(); - Descriptor getDescriptor(); + ForeignCallDescriptor getDescriptor(); /** * Determines if the target routine destroys all registers. diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.compiler.ptx/src/com/oracle/graal/compiler/ptx/PTXLIRGenerator.java --- a/graal/com.oracle.graal.compiler.ptx/src/com/oracle/graal/compiler/ptx/PTXLIRGenerator.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.compiler.ptx/src/com/oracle/graal/compiler/ptx/PTXLIRGenerator.java Thu May 16 16:01:40 2013 +0200 @@ -29,7 +29,7 @@ import static com.oracle.graal.lir.ptx.PTXCompare.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.asm.NumUtil; import com.oracle.graal.compiler.gen.LIRGenerator; @@ -70,8 +70,8 @@ */ public class PTXLIRGenerator extends LIRGenerator { - public static final Descriptor ARITHMETIC_FREM = new Descriptor("arithmeticFrem", false, float.class, float.class, float.class); - public static final Descriptor ARITHMETIC_DREM = new Descriptor("arithmeticDrem", false, double.class, double.class, double.class); + public static final ForeignCallDescriptor ARITHMETIC_FREM = new ForeignCallDescriptor("arithmeticFrem", false, float.class, float.class, float.class); + public static final ForeignCallDescriptor ARITHMETIC_DREM = new ForeignCallDescriptor("arithmeticDrem", false, double.class, double.class, double.class); public static class PTXSpillMoveFactory implements LIR.SpillMoveFactory { diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotBackend.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotBackend.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotBackend.java Thu May 16 16:01:40 2013 +0200 @@ -22,7 +22,7 @@ */ package com.oracle.graal.hotspot; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.hotspot.bridge.*; @@ -39,34 +39,34 @@ /** * Descriptor for SharedRuntime::deopt_blob()->uncommon_trap(). */ - public static final Descriptor UNCOMMON_TRAP = new Descriptor("deoptimize", true, void.class); + public static final ForeignCallDescriptor UNCOMMON_TRAP = new ForeignCallDescriptor("deoptimize", true, void.class); /** * Descriptor for {@link ExceptionHandlerStub}. This stub is called by the * {@linkplain Marks#MARK_EXCEPTION_HANDLER_ENTRY exception handler} in a compiled method. */ - public static final Descriptor EXCEPTION_HANDLER = new Descriptor("exceptionHandler", true, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor EXCEPTION_HANDLER = new ForeignCallDescriptor("exceptionHandler", true, void.class, Object.class, Word.class); /** * Descriptor for SharedRuntime::deopt_blob()->unpack(). */ - public static final Descriptor DEOPT_HANDLER = new Descriptor("deoptHandler", true, void.class); + public static final ForeignCallDescriptor DEOPT_HANDLER = new ForeignCallDescriptor("deoptHandler", true, void.class); /** * Descriptor for SharedRuntime::get_ic_miss_stub(). */ - public static final Descriptor IC_MISS_HANDLER = new Descriptor("icMissHandler", true, void.class); + public static final ForeignCallDescriptor IC_MISS_HANDLER = new ForeignCallDescriptor("icMissHandler", true, void.class); /** * Descriptor for {@link UnwindExceptionToCallerStub}. This stub is called by code generated * from {@link UnwindNode}. */ - public static final Descriptor UNWIND_EXCEPTION_TO_CALLER = new Descriptor("unwindExceptionToCaller", true, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor UNWIND_EXCEPTION_TO_CALLER = new ForeignCallDescriptor("unwindExceptionToCaller", true, void.class, Object.class, Word.class); /** * Descriptor for the arguments when unwinding to an exception handler in a caller. */ - public static final Descriptor EXCEPTION_HANDLER_IN_CALLER = new Descriptor("exceptionHandlerInCaller", false, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor EXCEPTION_HANDLER_IN_CALLER = new ForeignCallDescriptor("exceptionHandlerInCaller", false, void.class, Object.class, Word.class); public HotSpotBackend(HotSpotRuntime runtime, TargetDescription target) { super(runtime, target); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeCallTarget.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeCallTarget.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeCallTarget.java Thu May 16 16:01:40 2013 +0200 @@ -66,7 +66,7 @@ /** * The descriptor of the call. */ - private final Descriptor descriptor; + private final ForeignCallDescriptor descriptor; /** * The entry point address of this call's target. @@ -97,7 +97,7 @@ * @param ccType calling convention type * @param transition specifies if this is a {@linkplain #isLeaf() leaf} call */ - public static HotSpotRuntimeCallTarget create(Descriptor descriptor, long address, RegisterEffect effect, Type ccType, Transition transition) { + public static HotSpotRuntimeCallTarget create(ForeignCallDescriptor descriptor, long address, RegisterEffect effect, Type ccType, Transition transition) { CallingConvention targetCc = createCallingConvention(descriptor, ccType); return new HotSpotRuntimeCallTarget(descriptor, address, effect, transition, targetCc); } @@ -105,7 +105,7 @@ /** * Gets a calling convention for a given descriptor and call type. */ - public static CallingConvention createCallingConvention(Descriptor descriptor, Type ccType) { + public static CallingConvention createCallingConvention(ForeignCallDescriptor descriptor, Type ccType) { HotSpotRuntime runtime = graalRuntime().getRuntime(); Class[] argumentTypes = descriptor.getArgumentTypes(); JavaType[] parameterTypes = new JavaType[argumentTypes.length]; @@ -125,7 +125,7 @@ } } - public HotSpotRuntimeCallTarget(Descriptor descriptor, long address, RegisterEffect effect, Transition transition, CallingConvention cc) { + public HotSpotRuntimeCallTarget(ForeignCallDescriptor descriptor, long address, RegisterEffect effect, Transition transition, CallingConvention cc) { this.address = address; this.effect = effect; this.transition = transition; @@ -146,7 +146,7 @@ return graalRuntime().getCompilerToVM().getMaxCallTargetOffset(address); } - public Descriptor getDescriptor() { + public ForeignCallDescriptor getDescriptor() { return descriptor; } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotRuntime.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotRuntime.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotRuntime.java Thu May 16 16:01:40 2013 +0200 @@ -70,7 +70,7 @@ import com.oracle.graal.api.code.CompilationResult.DataPatch; import com.oracle.graal.api.code.CompilationResult.Infopoint; import com.oracle.graal.api.code.CompilationResult.Mark; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.*; import com.oracle.graal.hotspot.*; @@ -100,8 +100,8 @@ */ public abstract class HotSpotRuntime implements GraalCodeCacheProvider, DisassemblerProvider, BytecodeDisassemblerProvider { - public static final Descriptor OSR_MIGRATION_END = new Descriptor("OSR_migration_end", true, void.class, long.class); - public static final Descriptor IDENTITY_HASHCODE = new Descriptor("identity_hashcode", false, int.class, Object.class); + public static final ForeignCallDescriptor OSR_MIGRATION_END = new ForeignCallDescriptor("OSR_migration_end", true, void.class, long.class); + public static final ForeignCallDescriptor IDENTITY_HASHCODE = new ForeignCallDescriptor("identity_hashcode", false, int.class, Object.class); public final HotSpotVMConfig config; @@ -116,7 +116,7 @@ private BoxingSnippets.Templates boxingSnippets; private LoadExceptionObjectSnippets.Templates exceptionObjectSnippets; - private final Map runtimeCalls = new HashMap<>(); + private final Map runtimeCalls = new HashMap<>(); /** * The offset from the origin of an array to the first element. @@ -193,14 +193,14 @@ /** * Registers the details for linking a call to a {@link Stub}. */ - protected RuntimeCallTarget registerStubCall(Descriptor descriptor) { + protected RuntimeCallTarget registerStubCall(ForeignCallDescriptor descriptor) { return register(HotSpotRuntimeCallTarget.create(descriptor, 0L, PRESERVES_REGISTERS, JavaCallee, NOT_LEAF)); } /** * Registers the details for a call to a runtime C/C++ function. */ - protected RuntimeCallTarget registerCRuntimeCall(Descriptor descriptor, long address) { + protected RuntimeCallTarget registerCRuntimeCall(ForeignCallDescriptor descriptor, long address) { Class resultType = descriptor.getResultType(); assert resultType.isPrimitive() || Word.class.isAssignableFrom(resultType) : "C runtime call must return object thread local storage: " + descriptor; return register(HotSpotRuntimeCallTarget.create(descriptor, address, DESTROYS_REGISTERS, NativeCall, NOT_LEAF)); @@ -209,7 +209,7 @@ /** * Registers the details for a call to a stub that never returns. */ - protected RuntimeCallTarget registerNoReturnStub(Descriptor descriptor, long address, CallingConvention.Type ccType) { + protected RuntimeCallTarget registerNoReturnStub(ForeignCallDescriptor descriptor, long address, CallingConvention.Type ccType) { return register(HotSpotRuntimeCallTarget.create(descriptor, address, PRESERVES_REGISTERS, ccType, NOT_LEAF)); } @@ -218,7 +218,7 @@ * throw exceptions. That is, the thread's execution state during the call is never inspected by * another thread. */ - protected RuntimeCallTarget registerLeafCall(Descriptor descriptor, long address, CallingConvention.Type ccType, RegisterEffect effect) { + protected RuntimeCallTarget registerLeafCall(ForeignCallDescriptor descriptor, long address, CallingConvention.Type ccType, RegisterEffect effect) { return register(HotSpotRuntimeCallTarget.create(descriptor, address, effect, ccType, LEAF)); } @@ -320,7 +320,7 @@ stub.getLinkage().setCompiledStub(stub); } - private void linkRuntimeCall(Descriptor descriptor, long address, Replacements replacements) { + private void linkRuntimeCall(ForeignCallDescriptor descriptor, long address, Replacements replacements) { RuntimeCallStub stub = new RuntimeCallStub(address, descriptor, true, this, replacements); HotSpotRuntimeCallTarget linkage = stub.getLinkage(); HotSpotRuntimeCallTarget targetLinkage = stub.getTargetLinkage(); @@ -855,7 +855,7 @@ return HotSpotResolvedObjectType.fromClass(clazz); } - public HotSpotRuntimeCallTarget lookupRuntimeCall(Descriptor descriptor) { + public HotSpotRuntimeCallTarget lookupRuntimeCall(ForeignCallDescriptor descriptor) { HotSpotRuntimeCallTarget callTarget = runtimeCalls.get(descriptor); assert runtimeCalls != null : descriptor; callTarget.finalizeAddress(graalRuntime.getBackend()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/CRuntimeCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/CRuntimeCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/CRuntimeCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; @@ -39,9 +39,9 @@ @Input private final NodeInputList arguments; - private final Descriptor descriptor; + private final ForeignCallDescriptor descriptor; - public CRuntimeCall(Descriptor descriptor, ValueNode... arguments) { + public CRuntimeCall(ForeignCallDescriptor descriptor, ValueNode... arguments) { super(StampFactory.forKind(Kind.fromJavaClass(descriptor.getResultType()))); this.arguments = new NodeInputList<>(this, arguments); this.descriptor = descriptor; diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorEnterStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorEnterStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorEnterStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.nodes.*; @@ -37,7 +37,7 @@ @Input private ValueNode object; @Input private ValueNode lock; - public static final Descriptor MONITORENTER = new Descriptor("monitorenter", true, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor MONITORENTER = new ForeignCallDescriptor("monitorenter", true, void.class, Object.class, Word.class); public MonitorEnterStubCall(ValueNode object, ValueNode lock) { super(StampFactory.forVoid()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorExitStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorExitStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/MonitorExitStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.hotspot.*; @@ -38,7 +38,7 @@ @Input private ValueNode object; private int lockDepth; - public static final Descriptor MONITOREXIT = new Descriptor("monitorexit", true, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor MONITOREXIT = new ForeignCallDescriptor("monitorexit", true, void.class, Object.class, Word.class); public MonitorExitStubCall(ValueNode object, int lockDepth) { super(StampFactory.forVoid()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewArrayStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewArrayStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewArrayStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.hotspot.meta.*; @@ -43,7 +43,7 @@ @Input private ValueNode hub; @Input private ValueNode length; - public static final Descriptor NEW_ARRAY = new Descriptor("new_array", false, Object.class, Word.class, int.class); + public static final ForeignCallDescriptor NEW_ARRAY = new ForeignCallDescriptor("new_array", false, Object.class, Word.class, int.class); public NewArrayStubCall(ValueNode hub, ValueNode length) { super(defaultStamp); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewInstanceStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewInstanceStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewInstanceStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.hotspot.meta.*; @@ -42,7 +42,7 @@ @Input private ValueNode hub; - public static final Descriptor NEW_INSTANCE = new Descriptor("new_instance", false, Object.class, Word.class); + public static final ForeignCallDescriptor NEW_INSTANCE = new ForeignCallDescriptor("new_instance", false, Object.class, Word.class); public NewInstanceStubCall(ValueNode hub) { super(defaultStamp); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewMultiArrayStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewMultiArrayStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/NewMultiArrayStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; @@ -45,7 +45,7 @@ @Input private ValueNode dims; private final int rank; - public static final Descriptor NEW_MULTI_ARRAY = new Descriptor("new_multi_array", false, Object.class, Word.class, int.class, Word.class); + public static final ForeignCallDescriptor NEW_MULTI_ARRAY = new ForeignCallDescriptor("new_multi_array", false, Object.class, Word.class, int.class, Word.class); public NewMultiArrayStubCall(ValueNode hub, int rank, ValueNode dims) { super(defaultStamp); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/ThreadIsInterruptedStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/ThreadIsInterruptedStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/ThreadIsInterruptedStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import java.lang.reflect.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; @@ -42,7 +42,7 @@ @Input private ValueNode thread; @Input private ValueNode clearIsInterrupted; - public static final Descriptor THREAD_IS_INTERRUPTED = new Descriptor("thread_is_interrupted", false, boolean.class, Object.class, boolean.class); + public static final ForeignCallDescriptor THREAD_IS_INTERRUPTED = new ForeignCallDescriptor("thread_is_interrupted", false, boolean.class, Object.class, boolean.class); public ThreadIsInterruptedStubCall(ValueNode thread, ValueNode clearIsInterrupted) { super(StampFactory.forInteger(Kind.Int, 0, 1)); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VMErrorNode.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VMErrorNode.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VMErrorNode.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; @@ -39,7 +39,7 @@ private final String format; @Input private ValueNode value; - public static final Descriptor VM_ERROR = new Descriptor("vm_error", false, void.class, Object.class, Object.class, long.class); + public static final ForeignCallDescriptor VM_ERROR = new ForeignCallDescriptor("vm_error", false, void.class, Object.class, Object.class, long.class); private VMErrorNode(String format, ValueNode value) { super(StampFactory.forVoid()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VerifyOopStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VerifyOopStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/VerifyOopStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.hotspot.stubs.*; @@ -36,7 +36,7 @@ public class VerifyOopStubCall extends DeoptimizingStubCall implements LIRGenLowerable { @Input private ValueNode object; - public static final Descriptor VERIFY_OOP = new Descriptor("verify_oop", false, Object.class, Object.class); + public static final ForeignCallDescriptor VERIFY_OOP = new ForeignCallDescriptor("verify_oop", false, Object.class, Object.class); public VerifyOopStubCall(ValueNode object) { super(StampFactory.objectNonNull()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPostStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPostStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPostStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.nodes.*; @@ -37,7 +37,7 @@ @Input private ValueNode object; @Input private ValueNode card; - public static final Descriptor WRITE_BARRIER_POST = new Descriptor("writeBarrierPost", true, void.class, Object.class, Word.class); + public static final ForeignCallDescriptor WRITE_BARRIER_POST = new ForeignCallDescriptor("writeBarrierPost", true, void.class, Object.class, Word.class); public WriteBarrierPostStubCall(ValueNode object, ValueNode card) { super(StampFactory.forVoid()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPreStubCall.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPreStubCall.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/nodes/WriteBarrierPreStubCall.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.hotspot.nodes; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.compiler.target.*; import com.oracle.graal.nodes.*; @@ -35,7 +35,7 @@ public class WriteBarrierPreStubCall extends FixedWithNextNode implements LIRGenLowerable { @Input private ValueNode object; - public static final Descriptor WRITE_BARRIER_PRE = new Descriptor("writeBarrierPre", true, void.class, Object.class); + public static final ForeignCallDescriptor WRITE_BARRIER_PRE = new ForeignCallDescriptor("writeBarrierPre", true, void.class, Object.class); public WriteBarrierPreStubCall(ValueNode object) { super(StampFactory.forVoid()); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/AESCryptSubstitutions.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/AESCryptSubstitutions.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/AESCryptSubstitutions.java Thu May 16 16:01:40 2013 +0200 @@ -26,7 +26,7 @@ import sun.misc.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.api.replacements.*; import com.oracle.graal.compiler.gen.*; @@ -85,9 +85,9 @@ @Input private ValueNode out; @Input private ValueNode key; - private final Descriptor descriptor; + private final ForeignCallDescriptor descriptor; - public CryptBlockStubCall(ValueNode in, ValueNode out, ValueNode key, Descriptor descriptor) { + public CryptBlockStubCall(ValueNode in, ValueNode out, ValueNode key, ForeignCallDescriptor descriptor) { super(StampFactory.forVoid()); this.in = in; this.out = out; @@ -104,7 +104,7 @@ public static class EncryptBlockStubCall extends CryptBlockStubCall { - public static final Descriptor ENCRYPT_BLOCK = new Descriptor("encrypt_block", false, void.class, Word.class, Word.class, Word.class); + public static final ForeignCallDescriptor ENCRYPT_BLOCK = new ForeignCallDescriptor("encrypt_block", false, void.class, Word.class, Word.class, Word.class); public EncryptBlockStubCall(ValueNode in, ValueNode out, ValueNode key) { super(in, out, key, ENCRYPT_BLOCK); @@ -116,7 +116,7 @@ public static class DecryptBlockStubCall extends CryptBlockStubCall { - public static final Descriptor DECRYPT_BLOCK = new Descriptor("decrypt_block", false, void.class, Word.class, Word.class, Word.class); + public static final ForeignCallDescriptor DECRYPT_BLOCK = new ForeignCallDescriptor("decrypt_block", false, void.class, Word.class, Word.class, Word.class); public DecryptBlockStubCall(ValueNode in, ValueNode out, ValueNode key) { super(in, out, key, DECRYPT_BLOCK); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/CipherBlockChainingSubstitutions.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/CipherBlockChainingSubstitutions.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/CipherBlockChainingSubstitutions.java Thu May 16 16:01:40 2013 +0200 @@ -26,7 +26,7 @@ import sun.misc.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.api.replacements.*; import com.oracle.graal.compiler.gen.*; @@ -104,9 +104,9 @@ @Input private ValueNode r; @Input private ValueNode inLength; - private final Descriptor descriptor; + private final ForeignCallDescriptor descriptor; - public AESCryptStubCall(ValueNode in, ValueNode out, ValueNode key, ValueNode r, ValueNode inLength, Descriptor descriptor) { + public AESCryptStubCall(ValueNode in, ValueNode out, ValueNode key, ValueNode r, ValueNode inLength, ForeignCallDescriptor descriptor) { super(StampFactory.forVoid()); this.in = in; this.out = out; @@ -125,7 +125,7 @@ public static class EncryptAESCryptStubCall extends AESCryptStubCall { - public static final Descriptor ENCRYPT = new Descriptor("encrypt", false, void.class, Word.class, Word.class, Word.class, Word.class, int.class); + public static final ForeignCallDescriptor ENCRYPT = new ForeignCallDescriptor("encrypt", false, void.class, Word.class, Word.class, Word.class, Word.class, int.class); public EncryptAESCryptStubCall(ValueNode in, ValueNode out, ValueNode key, ValueNode r, ValueNode inLength) { super(in, out, key, r, inLength, ENCRYPT); @@ -137,7 +137,7 @@ public static class DecryptAESCryptStubCall extends AESCryptStubCall { - public static final Descriptor DECRYPT = new Descriptor("decrypt", false, void.class, Word.class, Word.class, Word.class, Word.class, int.class); + public static final ForeignCallDescriptor DECRYPT = new ForeignCallDescriptor("decrypt", false, void.class, Word.class, Word.class, Word.class, Word.class, int.class); public DecryptAESCryptStubCall(ValueNode in, ValueNode out, ValueNode key, ValueNode r, ValueNode inLength) { super(in, out, key, r, inLength, DECRYPT); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/HotSpotReplacementsUtil.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/HotSpotReplacementsUtil.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/HotSpotReplacementsUtil.java Thu May 16 16:01:40 2013 +0200 @@ -28,7 +28,7 @@ import sun.misc.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -675,7 +675,7 @@ @SuppressWarnings("unused") @NodeIntrinsic(CRuntimeCall.class) - public static int identityHashCode(@ConstantNodeParameter Descriptor descriptor, Object object) { + public static int identityHashCode(@ConstantNodeParameter ForeignCallDescriptor descriptor, Object object) { return System.identityHashCode(object); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/SystemSubstitutions.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/SystemSubstitutions.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/replacements/SystemSubstitutions.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.replacements.nodes.BranchProbabilityNode.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.replacements.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -38,8 +38,8 @@ @ClassSubstitution(java.lang.System.class) public class SystemSubstitutions { - public static final Descriptor JAVA_TIME_MILLIS = new Descriptor("javaTimeMillis", false, long.class); - public static final Descriptor JAVA_TIME_NANOS = new Descriptor("javaTimeNanos", false, long.class); + public static final ForeignCallDescriptor JAVA_TIME_MILLIS = new ForeignCallDescriptor("javaTimeMillis", false, long.class); + public static final ForeignCallDescriptor JAVA_TIME_NANOS = new ForeignCallDescriptor("javaTimeNanos", false, long.class); @MacroSubstitution(macro = ArrayCopyNode.class) public static native void arraycopy(Object src, int srcPos, Object dest, int destPos, int length); @@ -64,7 +64,7 @@ } @NodeIntrinsic(value = CRuntimeCall.class, setStampFromReturnType = true) - public static long callLong(@ConstantNodeParameter Descriptor descriptor) { + public static long callLong(@ConstantNodeParameter ForeignCallDescriptor descriptor) { if (descriptor == JAVA_TIME_MILLIS) { return System.currentTimeMillis(); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ExceptionHandlerStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ExceptionHandlerStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ExceptionHandlerStub.java Thu May 16 16:01:40 2013 +0200 @@ -27,7 +27,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -125,8 +125,8 @@ return enabled || graalRuntime().getConfig().cAssertions; } - public static final Descriptor EXCEPTION_HANDLER_FOR_PC = descriptorFor(ExceptionHandlerStub.class, "exceptionHandlerForPc", false); + public static final ForeignCallDescriptor EXCEPTION_HANDLER_FOR_PC = descriptorFor(ExceptionHandlerStub.class, "exceptionHandlerForPc", false); @NodeIntrinsic(value = CRuntimeCall.class, setStampFromReturnType = true) - public static native Word exceptionHandlerForPc(@ConstantNodeParameter Descriptor exceptionHandlerForPc, Word thread); + public static native Word exceptionHandlerForPc(@ConstantNodeParameter ForeignCallDescriptor exceptionHandlerForPc, Word thread); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogObjectStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogObjectStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogObjectStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -50,8 +50,8 @@ logObjectC(LOG_OBJECT_C, thread(), object, flags); } - public static final Descriptor LOG_OBJECT_C = descriptorFor(LogObjectStub.class, "logObjectC", false); + public static final ForeignCallDescriptor LOG_OBJECT_C = descriptorFor(LogObjectStub.class, "logObjectC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void logObjectC(@ConstantNodeParameter Descriptor logObjectC, Word thread, Object object, int flags); + public static native void logObjectC(@ConstantNodeParameter ForeignCallDescriptor logObjectC, Word thread, Object object, int flags); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrimitiveStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrimitiveStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrimitiveStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -50,8 +50,8 @@ logPrimitivefC(LOG_PRIMITIVE_C, thread(), typeChar, value, newline); } - public static final Descriptor LOG_PRIMITIVE_C = descriptorFor(LogPrimitiveStub.class, "logPrimitivefC", false); + public static final ForeignCallDescriptor LOG_PRIMITIVE_C = descriptorFor(LogPrimitiveStub.class, "logPrimitivefC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void logPrimitivefC(@ConstantNodeParameter Descriptor logPrimitivefC, Word thread, char typeChar, long value, boolean newline); + public static native void logPrimitivefC(@ConstantNodeParameter ForeignCallDescriptor logPrimitivefC, Word thread, char typeChar, long value, boolean newline); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrintfStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrintfStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/LogPrintfStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -50,8 +50,8 @@ logPrintfC(LOG_PRINTF_C, thread(), format, v1, v2, v3); } - public static final Descriptor LOG_PRINTF_C = descriptorFor(LogPrintfStub.class, "logPrintfC", false); + public static final ForeignCallDescriptor LOG_PRINTF_C = descriptorFor(LogPrintfStub.class, "logPrintfC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void logPrintfC(@ConstantNodeParameter Descriptor logPrintfC, Word thread, String format, long v1, long v2, long v3); + public static native void logPrintfC(@ConstantNodeParameter ForeignCallDescriptor logPrintfC, Word thread, String format, long v1, long v2, long v3); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewArrayStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewArrayStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewArrayStub.java Thu May 16 16:01:40 2013 +0200 @@ -28,7 +28,7 @@ import static com.oracle.graal.hotspot.stubs.NewInstanceStub.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; @@ -120,8 +120,8 @@ return verifyObject(getAndClearObjectResult(thread())); } - public static final Descriptor NEW_ARRAY_C = descriptorFor(NewArrayStub.class, "newArrayC", false); + public static final ForeignCallDescriptor NEW_ARRAY_C = descriptorFor(NewArrayStub.class, "newArrayC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void newArrayC(@ConstantNodeParameter Descriptor newArrayC, Word thread, Word hub, int length); + public static native void newArrayC(@ConstantNodeParameter ForeignCallDescriptor newArrayC, Word thread, Word hub, int length); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewInstanceStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewInstanceStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewInstanceStub.java Thu May 16 16:01:40 2013 +0200 @@ -28,7 +28,7 @@ import static com.oracle.graal.hotspot.replacements.NewObjectSnippets.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; @@ -239,8 +239,8 @@ return Boolean.getBoolean("graal.newInstanceStub.forceSlowPath"); } - public static final Descriptor NEW_INSTANCE_C = descriptorFor(NewInstanceStub.class, "newInstanceC", false); + public static final ForeignCallDescriptor NEW_INSTANCE_C = descriptorFor(NewInstanceStub.class, "newInstanceC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void newInstanceC(@ConstantNodeParameter Descriptor newInstanceC, Word thread, Word hub); + public static native void newInstanceC(@ConstantNodeParameter ForeignCallDescriptor newInstanceC, Word thread, Word hub); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewMultiArrayStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewMultiArrayStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/NewMultiArrayStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -52,8 +52,8 @@ return verifyObject(getAndClearObjectResult(thread())); } - public static final Descriptor NEW_MULTI_ARRAY_C = descriptorFor(NewMultiArrayStub.class, "newMultiArrayC", false); + public static final ForeignCallDescriptor NEW_MULTI_ARRAY_C = descriptorFor(NewMultiArrayStub.class, "newMultiArrayC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void newMultiArrayC(@ConstantNodeParameter Descriptor newArrayC, Word thread, Word hub, int rank, Word dims); + public static native void newMultiArrayC(@ConstantNodeParameter ForeignCallDescriptor newArrayC, Word thread, Word hub, int rank, Word dims); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/OSRMigrationEndStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/OSRMigrationEndStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/OSRMigrationEndStub.java Thu May 16 16:01:40 2013 +0200 @@ -24,7 +24,7 @@ import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -50,8 +50,8 @@ osrMigrationEndC(OSR_MIGRATION_END_C, buffer); } - public static final Descriptor OSR_MIGRATION_END_C = descriptorFor(OSRMigrationEndStub.class, "osrMigrationEndC", false); + public static final ForeignCallDescriptor OSR_MIGRATION_END_C = descriptorFor(OSRMigrationEndStub.class, "osrMigrationEndC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void osrMigrationEndC(@ConstantNodeParameter Descriptor osrMigrationEndC, Word buffer); + public static native void osrMigrationEndC(@ConstantNodeParameter ForeignCallDescriptor osrMigrationEndC, Word buffer); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/RuntimeCallStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/RuntimeCallStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/RuntimeCallStub.java Thu May 16 16:01:40 2013 +0200 @@ -31,7 +31,7 @@ import java.lang.reflect.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.debug.*; import com.oracle.graal.hotspot.*; @@ -75,11 +75,11 @@ * @param prependThread true if the JavaThread value for the current thread is to be prepended * to the arguments for the call to {@code address} */ - public RuntimeCallStub(long address, Descriptor sig, boolean prependThread, HotSpotRuntime runtime, Replacements replacements) { + public RuntimeCallStub(long address, ForeignCallDescriptor sig, boolean prependThread, HotSpotRuntime runtime, Replacements replacements) { super(runtime, replacements, HotSpotRuntimeCallTarget.create(sig, 0L, PRESERVES_REGISTERS, JavaCallee, NOT_LEAF)); this.prependThread = prependThread; Class[] targetParameterTypes = createTargetParameters(sig); - Descriptor targetSig = new Descriptor(sig.getName() + ":C", sig.hasSideEffect(), sig.getResultType(), targetParameterTypes); + ForeignCallDescriptor targetSig = new ForeignCallDescriptor(sig.getName() + ":C", sig.hasSideEffect(), sig.getResultType(), targetParameterTypes); target = HotSpotRuntimeCallTarget.create(targetSig, address, DESTROYS_REGISTERS, NativeCall, NOT_LEAF); } @@ -90,7 +90,7 @@ return target; } - private Class[] createTargetParameters(Descriptor sig) { + private Class[] createTargetParameters(ForeignCallDescriptor sig) { Class[] parameters = sig.getArgumentTypes(); if (prependThread) { Class[] newParameters = new Class[parameters.length + 1]; @@ -111,7 +111,7 @@ return new JavaMethod() { public Signature getSignature() { - Descriptor d = linkage.getDescriptor(); + ForeignCallDescriptor d = linkage.getDescriptor(); Class[] arguments = d.getArgumentTypes(); JavaType[] parameters = new JavaType[arguments.length]; for (int i = 0; i < arguments.length; i++) { diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/StubUtil.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/StubUtil.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/StubUtil.java Thu May 16 16:01:40 2013 +0200 @@ -31,7 +31,7 @@ import java.lang.reflect.*; import java.util.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; import com.oracle.graal.hotspot.nodes.*; @@ -46,20 +46,20 @@ */ public class StubUtil { - public static final Descriptor VM_MESSAGE_C = descriptorFor(StubUtil.class, "vmMessageC", false); + public static final ForeignCallDescriptor VM_MESSAGE_C = descriptorFor(StubUtil.class, "vmMessageC", false); /** * Looks for a {@link CRuntimeCall} node intrinsic named {@code name} in {@code stubClass} and - * returns a {@link Descriptor} based on its signature and the value of {@code hasSideEffect}. + * returns a {@link ForeignCallDescriptor} based on its signature and the value of {@code hasSideEffect}. */ - public static Descriptor descriptorFor(Class stubClass, String name, boolean hasSideEffect) { + public static ForeignCallDescriptor descriptorFor(Class stubClass, String name, boolean hasSideEffect) { Method found = null; for (Method method : stubClass.getDeclaredMethods()) { if (Modifier.isStatic(method.getModifiers()) && method.getAnnotation(NodeIntrinsic.class) != null && method.getName().equals(name)) { if (method.getAnnotation(NodeIntrinsic.class).value() == CRuntimeCall.class) { assert found == null : "found more than one C runtime call named " + name + " in " + stubClass; - assert method.getParameterTypes().length != 0 && method.getParameterTypes()[0] == Descriptor.class : "first parameter of C runtime call '" + name + "' in " + stubClass + - " must be of type " + Descriptor.class.getSimpleName(); + assert method.getParameterTypes().length != 0 && method.getParameterTypes()[0] == ForeignCallDescriptor.class : "first parameter of C runtime call '" + name + "' in " + stubClass + + " must be of type " + ForeignCallDescriptor.class.getSimpleName(); found = method; } } @@ -67,7 +67,7 @@ assert found != null : "could not find C runtime call named " + name + " in " + stubClass; List> paramList = Arrays.asList(found.getParameterTypes()); Class[] cCallTypes = paramList.subList(1, paramList.size()).toArray(new Class[paramList.size() - 1]); - return new Descriptor(name, hasSideEffect, found.getReturnType(), cCallTypes); + return new ForeignCallDescriptor(name, hasSideEffect, found.getReturnType(), cCallTypes); } public static void handlePendingException(boolean isObjectResult) { @@ -80,7 +80,7 @@ } @NodeIntrinsic(CRuntimeCall.class) - private static native void vmMessageC(@ConstantNodeParameter Descriptor stubPrintfC, boolean vmError, Word format, long v1, long v2, long v3); + private static native void vmMessageC(@ConstantNodeParameter ForeignCallDescriptor stubPrintfC, boolean vmError, Word format, long v1, long v2, long v3); /** * Prints a message to the log stream. diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ThreadIsInterruptedStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ThreadIsInterruptedStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/ThreadIsInterruptedStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -52,8 +52,8 @@ return result; } - public static final Descriptor THREAD_IS_INTERRUPTED_C = descriptorFor(ThreadIsInterruptedStub.class, "threadIsInterruptedC", false); + public static final ForeignCallDescriptor THREAD_IS_INTERRUPTED_C = descriptorFor(ThreadIsInterruptedStub.class, "threadIsInterruptedC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native boolean threadIsInterruptedC(@ConstantNodeParameter Descriptor threadIsInterruptedC, Word thread, Thread receiverThread, boolean clearIsInterrupted); + public static native boolean threadIsInterruptedC(@ConstantNodeParameter ForeignCallDescriptor threadIsInterruptedC, Word thread, Thread receiverThread, boolean clearIsInterrupted); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/UnwindExceptionToCallerStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/UnwindExceptionToCallerStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/UnwindExceptionToCallerStub.java Thu May 16 16:01:40 2013 +0200 @@ -28,7 +28,7 @@ import static com.oracle.graal.hotspot.stubs.ExceptionHandlerStub.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -97,8 +97,8 @@ return enabled || graalRuntime().getConfig().cAssertions; } - public static final Descriptor EXCEPTION_HANDLER_FOR_RETURN_ADDRESS = descriptorFor(UnwindExceptionToCallerStub.class, "exceptionHandlerForReturnAddress", false); + public static final ForeignCallDescriptor EXCEPTION_HANDLER_FOR_RETURN_ADDRESS = descriptorFor(UnwindExceptionToCallerStub.class, "exceptionHandlerForReturnAddress", false); @NodeIntrinsic(value = CRuntimeCall.class, setStampFromReturnType = true) - public static native Word exceptionHandlerForReturnAddress(@ConstantNodeParameter Descriptor exceptionHandlerForReturnAddress, Word thread, Word returnAddress); + public static native Word exceptionHandlerForReturnAddress(@ConstantNodeParameter ForeignCallDescriptor exceptionHandlerForReturnAddress, Word thread, Word returnAddress); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/VMErrorStub.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/VMErrorStub.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/stubs/VMErrorStub.java Thu May 16 16:01:40 2013 +0200 @@ -25,7 +25,7 @@ import static com.oracle.graal.hotspot.replacements.HotSpotReplacementsUtil.*; import static com.oracle.graal.hotspot.stubs.StubUtil.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.code.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -50,8 +50,8 @@ vmErrorC(VM_ERROR_C, thread(), where, format, value); } - public static final Descriptor VM_ERROR_C = descriptorFor(VMErrorStub.class, "vmErrorC", false); + public static final ForeignCallDescriptor VM_ERROR_C = descriptorFor(VMErrorStub.class, "vmErrorC", false); @NodeIntrinsic(CRuntimeCall.class) - public static native void vmErrorC(@ConstantNodeParameter Descriptor vmErrorC, Word thread, String where, String format, long value); + public static native void vmErrorC(@ConstantNodeParameter ForeignCallDescriptor vmErrorC, Word thread, String where, String format, long value); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.java/src/com/oracle/graal/java/GraphBuilderPhase.java --- a/graal/com.oracle.graal.java/src/com/oracle/graal/java/GraphBuilderPhase.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.java/src/com/oracle/graal/java/GraphBuilderPhase.java Thu May 16 16:01:40 2013 +0200 @@ -33,7 +33,7 @@ import java.util.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.api.meta.ProfilingInfo.TriState; import com.oracle.graal.api.meta.ResolvedJavaType.Representation; @@ -59,8 +59,8 @@ public static final class RuntimeCalls { - public static final Descriptor CREATE_NULL_POINTER_EXCEPTION = new Descriptor("createNullPointerException", true, Object.class); - public static final Descriptor CREATE_OUT_OF_BOUNDS_EXCEPTION = new Descriptor("createOutOfBoundsException", true, Object.class, int.class); + public static final ForeignCallDescriptor CREATE_NULL_POINTER_EXCEPTION = new ForeignCallDescriptor("createNullPointerException", true, Object.class); + public static final ForeignCallDescriptor CREATE_OUT_OF_BOUNDS_EXCEPTION = new ForeignCallDescriptor("createOutOfBoundsException", true, Object.class, int.class); } /** diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallNode.java --- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallNode.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallNode.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.nodes.extended; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.*; import com.oracle.graal.nodes.*; @@ -35,15 +35,15 @@ @Input private final NodeInputList arguments; - private final Descriptor descriptor; + private final ForeignCallDescriptor descriptor; - public RuntimeCallNode(Descriptor descriptor, ValueNode... arguments) { + public RuntimeCallNode(ForeignCallDescriptor descriptor, ValueNode... arguments) { super(StampFactory.forKind(Kind.fromJavaClass(descriptor.getResultType()))); this.arguments = new NodeInputList<>(this, arguments); this.descriptor = descriptor; } - public Descriptor getDescriptor() { + public ForeignCallDescriptor getDescriptor() { return descriptor; } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallStateSplitNode.java --- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallStateSplitNode.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/RuntimeCallStateSplitNode.java Thu May 16 16:01:40 2013 +0200 @@ -22,7 +22,7 @@ */ package com.oracle.graal.nodes.extended; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.graph.*; import com.oracle.graal.nodes.*; import com.oracle.graal.nodes.spi.*; @@ -35,7 +35,7 @@ @Input(notDataflow = true) private FrameState stateAfter; - public RuntimeCallStateSplitNode(Descriptor descriptor, ValueNode... arguments) { + public RuntimeCallStateSplitNode(ForeignCallDescriptor descriptor, ValueNode... arguments) { super(descriptor, arguments); } diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/java/RegisterFinalizerNode.java --- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/java/RegisterFinalizerNode.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/java/RegisterFinalizerNode.java Thu May 16 16:01:40 2013 +0200 @@ -23,7 +23,7 @@ package com.oracle.graal.nodes.java; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.nodes.*; import com.oracle.graal.nodes.spi.*; @@ -35,7 +35,7 @@ */ public final class RegisterFinalizerNode extends AbstractStateSplit implements StateSplit, Canonicalizable, LIRLowerable, Virtualizable, DeoptimizingNode { - public static final Descriptor REGISTER_FINALIZER = new Descriptor("registerFinalizer", true, void.class, Object.class); + public static final ForeignCallDescriptor REGISTER_FINALIZER = new ForeignCallDescriptor("registerFinalizer", true, void.class, Object.class); @Input private FrameState deoptState; @Input private ValueNode object; diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/Log.java --- a/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/Log.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/Log.java Thu May 16 16:01:40 2013 +0200 @@ -24,7 +24,7 @@ import java.io.*; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.meta.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -37,9 +37,9 @@ */ public final class Log { - public static final Descriptor LOG_PRIMITIVE = new Descriptor("logPrimitive", false, void.class, int.class, long.class, boolean.class); - public static final Descriptor LOG_OBJECT = new Descriptor("logObject", false, void.class, Object.class, int.class); - public static final Descriptor LOG_PRINTF = new Descriptor("logPrintf", false, void.class, Object.class, long.class, long.class, long.class); + public static final ForeignCallDescriptor LOG_PRIMITIVE = new ForeignCallDescriptor("logPrimitive", false, void.class, int.class, long.class, boolean.class); + public static final ForeignCallDescriptor LOG_OBJECT = new ForeignCallDescriptor("logObject", false, void.class, Object.class, int.class); + public static final ForeignCallDescriptor LOG_PRINTF = new ForeignCallDescriptor("logPrintf", false, void.class, Object.class, long.class, long.class, long.class); // Note: Must be kept in sync with constants in graalRuntime.hpp private static final int LOG_OBJECT_NEWLINE = 0x01; @@ -47,13 +47,13 @@ private static final int LOG_OBJECT_ADDRESS = 0x04; @NodeIntrinsic(RuntimeCallNode.class) - private static native void log(@ConstantNodeParameter Descriptor logObject, Object object, int flags); + private static native void log(@ConstantNodeParameter ForeignCallDescriptor logObject, Object object, int flags); @NodeIntrinsic(RuntimeCallNode.class) - private static native void log(@ConstantNodeParameter Descriptor logPrimitive, int typeChar, long value, boolean newline); + private static native void log(@ConstantNodeParameter ForeignCallDescriptor logPrimitive, int typeChar, long value, boolean newline); @NodeIntrinsic(RuntimeCallNode.class) - private static native void printf(@ConstantNodeParameter Descriptor logPrintf, String format, long v1, long v2, long v3); + private static native void printf(@ConstantNodeParameter ForeignCallDescriptor logPrintf, String format, long v1, long v2, long v3); public static void print(boolean value) { log(LOG_PRIMITIVE, Kind.Boolean.getTypeChar(), value ? 1L : 0L, false); diff -r 1313dd590c62 -r 2e4f035186cf graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/MathSubstitutionsX86.java --- a/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/MathSubstitutionsX86.java Thu May 16 15:51:16 2013 +0200 +++ b/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/MathSubstitutionsX86.java Thu May 16 16:01:40 2013 +0200 @@ -22,7 +22,7 @@ */ package com.oracle.graal.replacements; -import com.oracle.graal.api.code.RuntimeCallTarget.Descriptor; +import com.oracle.graal.api.code.RuntimeCallTarget.ForeignCallDescriptor; import com.oracle.graal.api.replacements.*; import com.oracle.graal.graph.Node.ConstantNodeParameter; import com.oracle.graal.graph.Node.NodeIntrinsic; @@ -91,12 +91,12 @@ } } - public static final Descriptor ARITHMETIC_SIN = new Descriptor("arithmeticSin", false, double.class, double.class); - public static final Descriptor ARITHMETIC_COS = new Descriptor("arithmeticCos", false, double.class, double.class); - public static final Descriptor ARITHMETIC_TAN = new Descriptor("arithmeticTan", false, double.class, double.class); + public static final ForeignCallDescriptor ARITHMETIC_SIN = new ForeignCallDescriptor("arithmeticSin", false, double.class, double.class); + public static final ForeignCallDescriptor ARITHMETIC_COS = new ForeignCallDescriptor("arithmeticCos", false, double.class, double.class); + public static final ForeignCallDescriptor ARITHMETIC_TAN = new ForeignCallDescriptor("arithmeticTan", false, double.class, double.class); @NodeIntrinsic(value = RuntimeCallNode.class, setStampFromReturnType = true) - public static double callDouble(@ConstantNodeParameter Descriptor descriptor, double value) { + public static double callDouble(@ConstantNodeParameter ForeignCallDescriptor descriptor, double value) { if (descriptor == ARITHMETIC_SIN) { return Math.sin(value); }