@specs-feup/clava
Version:
A C/C++ source-to-source compiler written in Typescript
26 lines • 836 B
TypeScript
import { Joinpoint, Op } from "../../Joinpoints.js";
/**
* Instruments an application so that it counts total operations in a region of code.
*
* @param filterFunction - Function that receives an $op. If returns false, $op will not be counted.
*/
export default class OpsCounter {
private static validOps;
private counters;
private $counterType;
private instrumentedFunctions;
private filterFunction;
constructor(filterFunction?: (op: Op) => boolean);
instrument($region: Joinpoint): void;
private countOp;
private getCounter;
private getCounterPrefix;
private getCounterType;
private toBuiltinType;
/**
* Adds code that prints the operation counting report.
*/
log($insertionPoint: Joinpoint): void;
private isValidOp;
}
//# sourceMappingURL=OpsCounter.d.ts.map