Skip to content

Commit 1e3c827

Browse files
authored
Merge pull request #629 from herbie-fp/minor-2.0
Minor fixes for 2.0
2 parents f26711c + f2ddb16 commit 1e3c827

File tree

11 files changed

+16
-14
lines changed

11 files changed

+16
-14
lines changed

egg-herbie/info.rkt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#lang info
22

33
(define collection "egg-herbie")
4-
(define version "1.6")
4+
(define version "2.0")
55

66
(define pkg-desc "Racket bindings for simplifying math expressions using egg")
77
(define pkg-authors

src/config.rkt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@
122122
(if (equal? out "") default out))
123123
default))
124124

125-
(define *herbie-version* "1.6")
125+
(define *herbie-version* "2.0")
126126

127127
(define *hostname* (run-command "hostname"))
128128

src/datafile.rkt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,9 @@
4646
#:unless (null? cost-accuracy))
4747
(match cost-accuracy
4848
[(list (list _ initial-accuracy) _ _) initial-accuracy]))])
49-
(exact->inexact (- 1 (/ initial-accuracies-sum maximum-accuracy)))))
49+
(if (> maximum-accuracy 0)
50+
(exact->inexact (- 1 (/ initial-accuracies-sum maximum-accuracy)))
51+
1.0)))
5052
(define rescaled
5153
(for/list ([cost-accuracy (in-list cost-accuracies)]
5254
#:unless (null? cost-accuracy))

src/info.rkt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#lang info
22

33
(define collection "herbie")
4-
(define version "1.6")
4+
(define version "2.0")
55

66
;; Packaging information
77

@@ -28,7 +28,7 @@
2828
"profile-lib"
2929
"rackunit-lib"
3030
"web-server-lib"
31-
("egg-herbie" #:version "1.6")
31+
("egg-herbie" #:version "2.0")
3232
("rival" #:version "1.7")
3333
("fpbench" #:version "2.0.3")))
3434

src/web/pages.rkt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
["interactive.js"
3636
(make-interactive-js result out ctx)]
3737
["timeline.html"
38-
(make-timeline (test-name test) (job-result-timeline result) out)]
38+
(make-timeline (test-name test) (job-result-timeline result) out #:path "..")]
3939
["timeline.json"
4040
(write-json (job-result-timeline result) out)]
4141
["points.json"

src/web/resources/report.css

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -228,10 +228,8 @@ section { display: flow-root; }
228228

229229
/* Process / debug info */
230230

231-
#process-info { background: #ddd; }
231+
#process-info { background: #ddd; padding: 0; }
232232
#process-info p.header { font-size: 110%; padding: 1em 1em .5em; margin: 0; }
233-
#process-info p.header .attachment { float: right; margin: 0 0 0 1em; }
234-
#process-info > p { margin: 1em .75em 0; }
235233

236234
.timeline {
237235
height: 2em; border: 1px solid #888; border-width: 1px 0px; margin-bottom: 1em;

src/web/run.rkt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474

7575
(call-with-output-file (build-path dir "timeline.html")
7676
#:exists 'replace
77-
(λ (out) (make-timeline "Herbie run" timeline out #:info info)))
77+
(λ (out) (make-timeline "Herbie run" timeline out #:info info #:path ".")))
7878

7979
; Delete old files
8080
(let* ([expected-dirs (map string->path (filter identity (map table-row-link (report-info-tests info))))]

src/web/timeline.rkt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
;; This first part handles timelines for a single Herbie run
1010

11-
(define (make-timeline name timeline out #:info [info #f])
11+
(define (make-timeline name timeline out #:info [info #f] #:path [path "."])
1212
(fprintf out "<!doctype html>\n")
1313
(write-xexpr
1414
`(html
@@ -20,6 +20,7 @@
2020
(body
2121
,(render-menu
2222
(~a name)
23+
#:path path
2324
(if info
2425
`(("Report" . "index.html"))
2526
`(("Details" . "graph.html"))))
@@ -32,7 +33,6 @@
3233
(-> timeline? xexpr?)
3334
(define time (apply + (map (curryr dict-ref 'time) timeline)))
3435
`(section ([id "process-info"])
35-
(h1 "Details")
3636
(p ((class "header"))
3737
"Time bar (total: " (span ((class "number")) ,(format-time time)) ")")
3838
(div ((class "timeline"))

www/doc/2.0/using-cli.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ <h2 id="batch">Batch processing FPCores</h2>
7272
1/3 [ 0.882s] 30→ 0 Cancel like terms
7373
Warning: 24.7% of points produce a very large (infinite) output.
7474
You may want to add a precondition.
75-
See <a href="https://herbie.uwplse.org/doc/1.6/faq.html#inf-points">&lt;https://herbie.uwplse.org/doc/1.6/faq.html#inf-points&gt;</a> for more.
75+
See <a href="https://herbie.uwplse.org/doc/2.0/faq.html#inf-points">&lt;https://herbie.uwplse.org/doc/2.0/faq.html#inf-points&gt;</a> for more.
7676
2/3 [ 1.721s] 29→ 0 Expanding a square
7777
3/3 [ 2.426s] 0→ 0 Commute and associate</pre>
7878

www/doc/latest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.6
1+
2.0

0 commit comments

Comments
 (0)