public CodeGenerator(IModule module, PeReader.DefaultHost host, Log.Log logger, Random prng, MethodCfg methodCfg, bool debugging = false, CfgManipulator manipulator = null) { this.host = host; this.logger = logger; this.module = module; this.prng = prng; this.methodCfg = methodCfg; this.debugging = debugging; this.manipulator = manipulator; callableMethods = retrieveCallableMethods(); }
public CodeMutator(IModule module, PeReader.DefaultHost host, Log.Log logger, Random prng, MethodCfg methodCfg, CfgManipulator manipulator, bool debugging = false) { this.host = host; this.logger = logger; this.module = module; this.prng = prng; this.methodCfg = methodCfg; this.debugging = debugging; this.manipulator = manipulator; returnBlock = new BasicBlock(); var exitBranch = new ExitBranchTarget(); returnBlock.exitBranch = exitBranch; returnBlock.operations.Add(createNewOperation(OperationCode.Ret)); methodCfg.basicBlocks.Add(returnBlock); }