perf(adapters): eliminate hot-path overhead across WASM, EVM, Frida, web modules, and HAR (#13356)

* perf(adapters): eliminate hot-path overhead across WASM, EVM, Frida, web modules, and HAR

* fix(wasm): scan only WAT form heads before budget checks and drop unbounded formParts retention
This commit is contained in:
morluto authored and GitHub committed 2026-11-22 08:04:05 -05:00
1 parent ec56d1b020
commit 26465e8ae6
14 files changed
+2165 -786

No files matched your search

+3 -4
View File
@@ -17,7 +17,7 @@ import { jsonObjectSchema } from "../domain/jsonValue.js";
import { err, ok, type Result } from "../domain/result.js";
import {
collectWebModuleImports,
matchCapturedModules,
createCapturedModuleMatcher,
} from "../domain/webModuleImports.js";
import {
webModuleTraceInputSchema,
@@ -204,6 +204,7 @@ export class WebModuleTraceService {
);
}
let literalIndex = 0;
const matchCaptured = createCapturedModuleMatcher(data.manifest.scripts);
const imports: WebModuleTraceResult["imports"] = [];
for (const reference of syntax.imports) {
let resolved:
@@ -226,9 +227,7 @@ export class WebModuleTraceService {
...reference,
resolution: resolved,
captured_candidates:
resolved.state === "resolved"
? matchCapturedModules(resolved.url, data.manifest.scripts)
: [],
resolved.state === "resolved" ? matchCaptured(resolved.url) : [],
execution: "unknown",
});
}