/** * Gets the number of parameters the native function accepts. * * @return The number of parameters the native function accepts. */ public final int getParameterCount() { return callContext.getParameterCount(); }
/** * Gets the number of parameters the native function accepts. * * @return The number of parameters the native function accepts. */ public final int getParameterCount() { return callContext.getParameterCount(); }
/** * Gets the number of parameters the native function accepts. * * @return The number of parameters the native function accepts. */ public final int getParameterCount() { return callContext.getParameterCount(); }
public final int getBufferSize(CallContext callContext) { return callContext.getParameterCount() * PARAM_SIZE; } public final int putByte(byte[] buffer, int offset, int value) {
public final int getBufferSize(CallContext callContext) { return callContext.getParameterCount() * PARAM_SIZE; } public final int putByte(byte[] buffer, int offset, int value) {
public final int getBufferSize(CallContext callContext) { return callContext.getParameterCount() * PARAM_SIZE; } public final int putByte(byte[] buffer, int offset, int value) {
static Invoker create(CallContext callContext, long address) { switch (callContext.getParameterCount()) { case 0: return new N0(callContext, address); case 1: return new N1(callContext, address); case 2: return new N2(callContext, address); case 3: return new N3(callContext, address); default: throw new UnsatisfiedLinkError("unsupported arity: " + callContext.getParameterCount()); } }
if (callContext.getParameterCount() > 6) { return null; isFastLong &= (cpu == Platform.CPU.I386 || cpu == Platform.CPU.X86_64); for (int i = 0; i < callContext.getParameterCount() && (isFastInt || isFastLong); i++) { if (!(callContext.getParameterType(i) instanceof Type.Builtin)) { return null; String methodName = (isFastInt ? "invokeI" : isFastLong ? "invokeL" : "invokeN") + callContext.getParameterCount(); Class[] params = new Class[2 + callContext.getParameterCount()]; params[0] = long.class; params[1] = long.class;
if (callContext.getParameterCount() > 6) { return null; isFastLong &= (cpu == Platform.CPU.I386 || cpu == Platform.CPU.X86_64); for (int i = 0; i < callContext.getParameterCount() && (isFastInt || isFastLong); i++) { if (!(callContext.getParameterType(i) instanceof Type.Builtin)) { return null; String methodName = (isFastInt ? "invokeI" : isFastLong ? "invokeL" : "invokeN") + callContext.getParameterCount(); Class[] params = new Class[2 + callContext.getParameterCount()]; params[0] = long.class; params[1] = long.class;
if (callContext.getParameterCount() > 6) { return null; isFastLong &= (cpu == Platform.CPU.I386 || cpu == Platform.CPU.X86_64); for (int i = 0; i < callContext.getParameterCount() && (isFastInt || isFastLong); i++) { if (!(callContext.getParameterType(i) instanceof Type.Builtin)) { return null; String methodName = (isFastInt ? "invokeI" : isFastLong ? "invokeL" : "invokeN") + callContext.getParameterCount(); Class[] params = new Class[2 + callContext.getParameterCount()]; params[0] = long.class; params[1] = long.class;