diff --git a/toolflow/src/main/scala/com/minres/tgc/hammer/options/CommandGroup.scala b/toolflow/src/main/scala/com/minres/tgc/hammer/options/CommandGroup.scala index d3cc0f2..f27552a 100644 --- a/toolflow/src/main/scala/com/minres/tgc/hammer/options/CommandGroup.scala +++ b/toolflow/src/main/scala/com/minres/tgc/hammer/options/CommandGroup.scala @@ -5,8 +5,8 @@ import os.Shellable class CommandGroup(name: String) extends BaseGroup { override def getToolParameters: Seq[Shellable] = { - val sub = options.toSeq.flatMap(_.getToolParameters) - Seq(s"""$name="${sub.mkString(" ")}"""") + val sub = options.toSeq.map(_.getToolParameters) + Seq(s"""--$name="${sub.flatMap(_.value).mkString(" ")}"""") } override def init(scallopConf: ScallopConf, group: ScallopOptionGroup): Unit = { diff --git a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/Task.scala b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/Task.scala index 7f3f086..224289d 100644 --- a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/Task.scala +++ b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/Task.scala @@ -7,6 +7,8 @@ trait Task { def execute(): Unit def runExecutable(execPath: Path, args: Shellable*): os.CommandResult = { + println(s"Executing $execPath with") + println(args.flatMap(_.value).mkString(" ")) os.proc(execPath, args).call() } } diff --git a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/LongnailScheduleTask.scala b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/LongnailScheduleTask.scala index 19ed593..7d014d1 100644 --- a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/LongnailScheduleTask.scala +++ b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/LongnailScheduleTask.scala @@ -30,8 +30,6 @@ class LongnailScheduleTask(isaxMLIR: Path, coreDatasheet: Path, params: Scheduli )*/ runExecutable(EXECUTABLE, "--lower-coredsl-to-lil", - "--schedule-lil", - "--datasheet", coreDatasheet, params.getToolParameters, isaxMLIR ) diff --git a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/SchedulingParameters.scala b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/SchedulingParameters.scala index 29fa7f2..933dfa9 100644 --- a/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/SchedulingParameters.scala +++ b/toolflow/src/main/scala/com/minres/tgc/hammer/tasks/longnail/SchedulingParameters.scala @@ -7,16 +7,19 @@ import org.rogach.scallop.* class SchedulingParameters extends OptionGroup { override def name: String = "Longnail Scheduling Args" + add(new CommandGroup("prepare-schedule-lil") { + choiceS(Seq("LEGACY", "MS", "PAMS", "PARAMS", "MI_MS", "MI_PAMS", "MI_PARAMS"), name = "schedulingAlgo", default = Some("LEGACY")) + value[Path](cliName = "cellLibrary", toolName = "library") + valueS[Path](name = "opTyLibrary") + }) + add(new CommandGroup("schedule-lil") { valueS[Int](name = "schedulingTimeout") value[Int](cliName = "schedulingRefineTimeout", toolName = "schedRefineTimeout") value[Path](cliName = "schedulingKconf", toolName = "solSelKconfPath") - choiceS(Seq("LEGACY", "MS", "PAMS", "PARAMS", "MI_MS", "MI_PAMS", "MI_PARAMS"), name = "schedulingAlgo", default = Some("LEGACY")) choice(Seq("CBC", "GLPK", "SCIP", "HIGHS", "GUROBI", "CPLEX", "XPRESS", "COPT"), cliName = "ilpSolver", toolName = "solver", default = Some("CBC")) toggle(cliName = "verboseSched", toolName = "verbose") - valueS[Path](name = "opTyLibrary") value[Int](cliName = "clockPeriod", toolName = "clockTime") - value[Path](cliName = "cellLibrary", toolName = "library") }) value[Int](cliName = "maxLoopUnrollFactor", toolName = "max-unroll-factor")