/* * Copyright 2002-2019 Intel Corporation. * * This software is provided to you as Sample Source Code as defined in the accompanying * End User License Agreement for the Intel(R) Software Development Products ("Agreement") * section 1.L. * * This software and the related documents are provided as is, with no express or implied * warranties, other than those that are expressly stated in the License. */ // This tool test RTN_InsHead RTN_InsHeadOnly and RTN_InsertCall (before) #include #include #include #include #include "pin.H" using std::ofstream; using std::hex; using std::endl; ofstream OutFile; VOID AtRtn1(VOID* name, ADDRINT pc, UINT64 tsc, ADDRINT pc2) { OutFile << std::left << std::setw(32) << reinterpret_cast(name) << "," << hex << tsc << "," << hex << pc << " , "<< pc2 << endl; } VOID PIN_FAST_ANALYSIS_CALL AtRtn2(VOID* name, ADDRINT pc, UINT64 tsc, ADDRINT pc2) { OutFile << std::left << std::setw(32) << reinterpret_cast(name) << "," << hex << tsc << "," << hex << pc << " , "<< pc2 <