Example #1
0
MTable::MethodInfo::MethodInfo(Method_Handle _mh, size_t _num) {
    num = _num;
    mh = _mh;
    Class_Handle ch = method_get_class(mh);
    className = class_get_name(ch);
    methodName = method_get_name(mh);
    signature = method_get_descriptor(mh);
    assert(!className.empty() && !methodName.empty() && !signature.empty());
}
Example #2
0
static void logReadyProfile(const std::string& catName, const std::string& profilerName, EBMethodProfile* mp) {
    const char* methodName = method_get_name(mp->mh);
    Class_Handle ch = method_get_class(mp->mh);
    const char* className = class_get_name(ch);
    const char* signature = method_get_descriptor(mp->mh);

    std::ostringstream msg;
    msg <<"EM: profiler["<<profilerName.c_str()<<"] profile is ready [e:"
        << mp->entryCounter <<" b:"<<mp->backedgeCounter<<"] "
        <<className<<"::"<<methodName<<signature;
    INFO2(catName.c_str(), msg.str().c_str());
}