mirror of
https://github.com/momo5502/emulator.git
synced 2026-01-19 19:53:56 +00:00
Support ignored functions and interesting modules
This commit is contained in:
@@ -6,6 +6,8 @@ export interface Settings {
|
||||
persist: boolean;
|
||||
execAccess: boolean;
|
||||
wasm64: boolean;
|
||||
ignoredFunctions: string[];
|
||||
interestingModules: string[];
|
||||
}
|
||||
|
||||
export function createDefaultSettings(): Settings {
|
||||
@@ -17,6 +19,8 @@ export function createDefaultSettings(): Settings {
|
||||
persist: false,
|
||||
execAccess: true,
|
||||
wasm64: false,
|
||||
ignoredFunctions: [],
|
||||
interestingModules: [],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -69,5 +73,15 @@ export function translateSettings(settings: Settings): string[] {
|
||||
switches.push("-x");
|
||||
}
|
||||
|
||||
settings.ignoredFunctions.forEach((f) => {
|
||||
switches.push("-i");
|
||||
switches.push(f);
|
||||
});
|
||||
|
||||
settings.interestingModules.forEach((m) => {
|
||||
switches.push("-m");
|
||||
switches.push(m);
|
||||
});
|
||||
|
||||
return switches;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user