Don't add other files TR logs to optimization tests.
original commit: f6a0494f65bcc0793cde102a0a55fa4ad6a83fbe
This commit is contained in:
parent
12475b9985
commit
eae6aaa90f
|
@ -1,9 +1,7 @@
|
|||
#;#;
|
||||
#<<END
|
||||
TR info: multi-file1.rkt 13:2 (* x (ann 3 Integer)) -- exact real arith
|
||||
TR missed opt: multi-file1.rkt 13:2 (* x (ann 3 Integer)) -- all args float-arg-expr, result not Float -- caused by: 13:12 3
|
||||
TR opt: multi-file2.rkt 16:10 (+ 3 5) -- fixnum bounded expr
|
||||
TR opt: multi-file2.rkt 16:3 (* 3.4 (+ 3 5)) -- binary float
|
||||
TR opt: multi-file2.rkt 14:10 (+ 3 5) -- fixnum bounded expr
|
||||
TR opt: multi-file2.rkt 14:3 (* 3.4 (+ 3 5)) -- binary float
|
||||
END
|
||||
#<<END
|
||||
81.6
|
||||
|
|
|
@ -70,6 +70,9 @@
|
|||
(define file (simplify-path (build-path dir name)))
|
||||
(define orig-load/use-compiled (current-load/use-compiled))
|
||||
(define orig-use-compiled-file-paths (use-compiled-file-paths))
|
||||
(define full-tr-logs (make-queue))
|
||||
(define sub-tr-logs (make-queue))
|
||||
|
||||
(define (test-load/use-compiled path name)
|
||||
(parameterize [(use-compiled-file-paths null)
|
||||
(current-load/use-compiled reset-load/use-compiled)]
|
||||
|
@ -77,14 +80,16 @@
|
|||
(define (reset-load/use-compiled path name)
|
||||
(parameterize [(use-compiled-file-paths orig-use-compiled-file-paths)
|
||||
(current-load/use-compiled orig-load/use-compiled)]
|
||||
(orig-load/use-compiled path name)))
|
||||
(define tr-logs (make-queue))
|
||||
(with-tr-logging-to-queue
|
||||
sub-tr-logs
|
||||
(thunk
|
||||
(orig-load/use-compiled path name)))))
|
||||
|
||||
(define regular-output
|
||||
(with-output-to-string
|
||||
(lambda ()
|
||||
(with-tr-logging-to-queue
|
||||
tr-logs
|
||||
full-tr-logs
|
||||
(thunk
|
||||
(parameterize ([current-namespace (make-base-empty-namespace)]
|
||||
[current-load/use-compiled test-load/use-compiled])
|
||||
|
@ -92,4 +97,12 @@
|
|||
(namespace-attach-module orig-namespace 'racket)
|
||||
(namespace-attach-module orig-namespace 'typed-racket/core)
|
||||
(dynamic-require file #f)))))))
|
||||
(list (sort (queue->list tr-logs) string<?) regular-output))
|
||||
|
||||
(define tr-logs
|
||||
(let ((tr-logs (queue->list full-tr-logs)))
|
||||
(sort
|
||||
(for/fold ((tr-logs tr-logs)) ((entry (in-queue sub-tr-logs)))
|
||||
(remove entry tr-logs))
|
||||
string<?)))
|
||||
|
||||
(list tr-logs regular-output))
|
||||
|
|
Loading…
Reference in New Issue
Block a user