cuplv / TraceRunner

Tool for generating dynamic traces of android applications.
3 stars 0 forks source link

Logging Callins #7

Closed ftc closed 7 years ago

ftc commented 7 years ago

TODO: finish filling this out

Method call:

origional code

v = rec.foo(arg1,... argn)

instrumented code

Object[] args = new Object[n];
args[0] = rec
args[1] = arg1
...
args[n] = argn
signature = "...rec"
methodname="foo"
sourceLocation="..."
caller = this;
try{
    tmp_uniqueIDForEntryFromAtomicInteger = recordEntry(signature, methodName, sourceLocation, args, caller);
    v = rec.foo(arg1,.... argn)
    recordExit(signature, methodName, sourceLocation, v, tmp_uniqueIDForEntryFromAtomicInteger) //v is return value
}catch(Throwable t){
    logThrow(t);
    throw t;
}

We want to log

Note: these include primitives since java auto casts We want to log: