public int getNativeSignaturesCount() { int count = varSignature == null ? 0 : 1; if ( signatures != null ) count += signatures.size(); return count; }
public int getNativeSignaturesCount() { int count = varSignature == null ? 0 : 1; if ( signatures != null ) count += signatures.size(); return count; }
@Override public String toString() { return "Invocation(#" + methodSerialNumber + " count="+ count + " duration="+ duration + " parent="+ ( parent == null ? null : "#" + parent.methodSerialNumber ) + " children.size=" + children.size() + ")"; }
@Override public String toString() { return "Invocation(#" + methodSerialNumber + " count="+ count + " duration="+ duration + " parent="+ ( parent == null ? null : "#" + parent.methodSerialNumber ) + " children.size=" + children.size() + ")"; }
@Override public String toString() { return "Invocation(#" + methodSerialNumber + " count="+ count + " duration="+ duration + " parent="+ ( parent == null ? null : "#" + parent.methodSerialNumber ) + " children.size=" + children.size() + ")"; }
@Override public String toString() { return "Invocation(#" + methodSerialNumber + " count="+ count + " duration="+ duration + " parent="+ ( parent == null ? null : "#" + parent.methodSerialNumber ) + " children.size=" + children.size() + ")"; }
public synchronized int seenTypesCount() { return seenTypes.size(); }
public synchronized int seenTypesCount() { return seenTypes.size(); }
/** * Compute the profiling results from gathered data. * @return the top invocation */ public Invocation computeResults() { setRecursiveDepths(); if (topInvocation.getChildren().size() != 1) { return setDuration(topInvocation); } if (topInvocation.getChildren().size() == 1) { Invocation singleTopChild = topInvocation.getChildren().values().iterator().next(); int serial = singleTopChild.getMethodSerialNumber(); if ( PROFILER_PROFILE_METHOD.equals( methodName(serial) ) ) { for ( Invocation inv : singleTopChild.getChildren().values() ) { serial = inv.getMethodSerialNumber(); if ( PROFILER_PROFILED_CODE_METHOD.equals( methodName(serial) ) ) { return setDuration(inv.copyWithNewSerialAndParent(0, null)); } } } } return setDuration(topInvocation); }
/** * Compute the profiling results from gathered data. * @return the top invocation */ public Invocation computeResults() { setRecursiveDepths(); if (topInvocation.getChildren().size() != 1) { return setDuration(topInvocation); } if (topInvocation.getChildren().size() == 1) { Invocation singleTopChild = topInvocation.getChildren().values().iterator().next(); int serial = singleTopChild.getMethodSerialNumber(); if ( ProfilePrinter.PROFILER_PROFILE_METHOD.equals( methodName(serial) ) ) { for ( Invocation inv : singleTopChild.getChildren().values() ) { serial = inv.getMethodSerialNumber(); if ( ProfilePrinter.PROFILER_PROFILED_CODE_METHOD.equals( methodName(serial) ) ) { return setDuration(inv.copyWithNewSerialAndParent(0, null)); } } } } return setDuration(topInvocation); }
/** * Compute the profiling results from gathered data. * @return the top invocation */ public Invocation computeResults() { setRecursiveDepths(); if (topInvocation.getChildren().size() != 1) { return setDuration(topInvocation); } if (topInvocation.getChildren().size() == 1) { Invocation singleTopChild = topInvocation.getChildren().values().iterator().next(); int serial = singleTopChild.getMethodSerialNumber(); if ( ProfilePrinter.PROFILER_PROFILE_METHOD.equals( methodName(serial) ) ) { for ( Invocation inv : singleTopChild.getChildren().values() ) { serial = inv.getMethodSerialNumber(); if ( ProfilePrinter.PROFILER_PROFILED_CODE_METHOD.equals( methodName(serial) ) ) { return setDuration(inv.copyWithNewSerialAndParent(0, null)); } } } } return setDuration(topInvocation); }
/** * Compute the profiling results from gathered data. * @return the top invocation */ public Invocation computeResults() { setRecursiveDepths(); if (topInvocation.getChildren().size() != 1) { return setDuration(topInvocation); } if (topInvocation.getChildren().size() == 1) { Invocation singleTopChild = topInvocation.getChildren().values().iterator().next(); int serial = singleTopChild.getMethodSerialNumber(); if ( PROFILER_PROFILE_METHOD.equals( methodName(serial) ) ) { for ( Invocation inv : singleTopChild.getChildren().values() ) { serial = inv.getMethodSerialNumber(); if ( PROFILER_PROFILED_CODE_METHOD.equals( methodName(serial) ) ) { return setDuration(inv.copyWithNewSerialAndParent(0, null)); } } } } return setDuration(topInvocation); }
final long[][] tuples = new long[methods.size()][];
final long[][] tuples = new long[methods.size()][];
MethodData[] sortedMethods = methods.values().toArray(new MethodData[methods.size()]);
MethodData[] sortedMethods = methods.values().toArray(new MethodData[methods.size()]);
final long[][] tuples = new long[methods.size()][];
final long[][] tuples = new long[methods.size()][];
private String pushHandlesForDef(String variableName, String specificName, IntHashMap<MethodType> signaturesExceptVariable, MethodType variable, String variableOnly, String variableAndSpecific) { String defSignature; jvmMethod().pushHandle(new Handle( Opcodes.H_INVOKESTATIC, jvm.clsData().clsName, variableName, sig(variable.returnType(), variable.parameterArray()), false)); if (signaturesExceptVariable.size() == 0) { defSignature = variableOnly; } else { defSignature = variableAndSpecific; for (IntHashMap.Entry<MethodType> entry : signaturesExceptVariable.entrySet()) { jvmMethod().pushHandle(new Handle( Opcodes.H_INVOKESTATIC, jvm.clsData().clsName, specificName, sig(entry.getValue().returnType(), entry.getValue().parameterArray()), false)); jvmAdapter().pushInt(entry.getKey()); break; // FIXME: only supports one arity } } return defSignature; }
private String pushHandlesForDef(String variableName, String specificName, IntHashMap<MethodType> signaturesExceptVariable, MethodType variable, String variableOnly, String variableAndSpecific) { String defSignature; jvmMethod().pushHandle(new Handle( Opcodes.H_INVOKESTATIC, jvm.clsData().clsName, variableName, sig(variable.returnType(), variable.parameterArray()), false)); if (signaturesExceptVariable.size() == 0) { defSignature = variableOnly; } else { defSignature = variableAndSpecific; for (IntHashMap.Entry<MethodType> entry : signaturesExceptVariable.entrySet()) { jvmMethod().pushHandle(new Handle( Opcodes.H_INVOKESTATIC, jvm.clsData().clsName, specificName, sig(entry.getValue().returnType(), entry.getValue().parameterArray()), false)); jvmAdapter().pushInt(entry.getKey()); break; // FIXME: only supports one arity } } return defSignature; }