import { Measure, Profiler, ScreenRecorder } from "@perf-profiler/types"; import { CppPerformanceMeasure } from "../cppProfiler"; export declare const CppProfilerName = "BAMPerfProfiler"; export declare abstract class UnixProfiler implements Profiler { stop(): void; private hasInstalledProfiler; private cpuClockTick; private RAMPageSize; /** * Main setup function for the cpp profiler * * It will: * - install the C++ profiler for the correct architecture on the device * - Starts the atrace process (the c++ profiler will then starts another thread to read from it) * - Populate needed values like CPU clock tick and RAM page size * * This needs to be done before measures and can take a few seconds */ installProfilerOnDevice(): void; private retrieveCpuClockTick; private retrieveRAMPageSize; getCpuClockTick(): number; getRAMPageSize(): number; private installCppProfilerOnDevice; pollPerformanceMeasures(bundleId: string, { onMeasure, onStartMeasuring, }: { onMeasure: (measure: Measure) => void; onStartMeasuring?: () => void; }): { stop: () => void; }; pollPerformanceMeasuresWeirdSubfunction: (pid: string, onData: (measure: CppPerformanceMeasure) => void, onPidChanged?: (pid: string) => void) => { stop: () => void; }; getScreenRecorder(videoPath: string): ScreenRecorder | undefined; stopApp(bundleId: string): Promise; cleanup(): void; abstract getDeviceCommand(command: string): string; protected abstract getAbi(): string; protected abstract pushExecutable(binaryTmpPath: string): void; protected abstract assertSupported(): void; abstract getDeviceProfilerPath(): string; abstract detectCurrentBundleId(): string; abstract supportFPS(): boolean; }