public GACodeGeneratorTester( IMachineDescriptionProvider mdp, IProgramGraphProvider pgp, int k, GAInstructionSelectorConfiguration isConfig, GASchedulerConfiguration scConfig, TextWriter textWriter, TextWriter dataWriter) { machineDescription = mdp.CreateMachineDescription(); programGraph = pgp.CreateUnrolledProgramGraph(k); codeGenerator = new GACodeGenerator(isConfig, scConfig); iSelector = codeGenerator.InstructionSelector; scheduler = codeGenerator.Scheduler; this.textWriter = textWriter; this.dataWriter = dataWriter; }
protected void GenerationComputed(GAScheduler scheduler) { if (scheduler.GA.Generation % schedulerDumpsEvery == 0) PrintSchedulerStatistics(); }