Browse files

Produce numbered graphs in the order that the benchmarks were first s…

…een in the input file(s).
  • Loading branch information...
1 parent 9a0c631 commit 18c7736f864ea23385ad33f5074a56e511b721af @jafingerhut committed Nov 7, 2012
Showing with 6 additions and 4 deletions.
  1. +6 −4 bin/results2graphs
View
10 bin/results2graphs
@@ -296,8 +296,10 @@ consisting of one or more Measurement elements\n"
(let [data-xrel (mapcat #(validated-xrel-from-xml-file % prog-name) filenames)
data (->> data-xrel
- xml-add-columns-benchmark-platform-language
-
+ xml-add-columns-benchmark-platform-language)
+ benchmark-input-order (zipmap (distinct (map :benchmark data))
+ (iterate inc 1))
+ data (->> data
;; If there are multiple measurements for the same
;; benchmark and language/Clojure version, group them
;; together for later processing.
@@ -339,8 +341,8 @@ consisting of one or more Measurement elements\n"
;; :benchmark :language :platform :elapsed_time_sec
(when (:plots opts)
(doseq [[idx [benchmark benchmark-measurements]]
- (zipmap (iterate inc 1)
- (group-by :benchmark data))]
+ (zipmap (iterate inc 1) (sort-by #(get benchmark-input-order (key %))
+ (group-by :benchmark data)))]
;; For each benchmark, create one chart with language/Clojure
;; version on the X axis, and run time on the Y axis. There

0 comments on commit 18c7736

Please sign in to comment.