blob: 20be20adb413ef7506f00142f1eefc253d6519c7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
gczeal(2);
g = newGlobal({newCompartment: true, disableLazyParsing: true});
dbg = Debugger(g);
dbg.onNewScript = function() { return function() { return this; } };
schedulegc(10);
g.evaluate("function one() {}");
g.evaluate(`
function target () {}
function two2() {}
`, {});
g.evaluate(`
function three1() {}
function three2() {}
function three3() {}
`, {});
dbg.memory.takeCensus({
breakdown: {
by: "coarseType",
scripts: {
by: "filename"
}
}
});
|