Skip to content

Commit

Permalink
output dir
Browse files Browse the repository at this point in the history
  • Loading branch information
ailrst committed Sep 16, 2024
1 parent 87988f5 commit a2a4401
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/test/analysisTiming/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
*.dat
*.svg
*.gp
*.csv
7 changes: 5 additions & 2 deletions src/test/scala/TimeAnalysis.scala
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import ExecutionContext.Implicits.global
import ir.cilvisitor.*
import scala.sys.process.*

val ANALYSE_TIMEOUT : Duration = 240000.millis

class TimeStaticAnalysis extends AnyFunSuite, TestUtil {

Expand Down Expand Up @@ -91,7 +92,7 @@ class TimeStaticAnalysis extends AnyFunSuite, TestUtil {
val chars = (File(cfg.inputFile)).length
(c,cfg,chars)
})
val loads3 = loads2.sortBy(_._3).take(50).map(c => (c._1, c._2))
val loads3 = loads2.sortBy(_._3).map(c => (c._1, c._2))
Logger.info(loads2.map(c => s"${c._2.inputFile} ${c._3}").mkString("\n"))

val sorted = loads3
Expand All @@ -117,7 +118,7 @@ class TimeStaticAnalysis extends AnyFunSuite, TestUtil {
None
} else {
Logger.warn(s"TESTING $testn")
val (comp,r) = Await.result(doAnalysis(testn), 240000.millis)
val (comp,r) = Await.result(doAnalysis(testn), ANALYSE_TIMEOUT)
Logger.warn(comp)
Logger.warn("CHECKPOINTS:")
Logger.warn(r.map(c => s"${c._1},${c._2},${c._3}").mkString("\n"))
Expand Down Expand Up @@ -194,5 +195,7 @@ class TimeStaticAnalysis extends AnyFunSuite, TestUtil {
val header = "test filename,statements,blocks,procedures,interval name,interval call loc,timedelta (ms)\n"
val text = header + csv
val path = "analysis-times.csv"
log(outputPathPrefix + "/analysis-times.csv", text)

}
}

0 comments on commit a2a4401

Please sign in to comment.