3.7.3.6 Version 6 Test Suites
(require cpsc411/test-suite/public/v6) | |
package: cpsc411-lib |
procedure
(v6-public-test-suite pass-list interp-list) → test-suite? pass-list : (listof (-> any/c any/c)) interp-list : (listof (or/c #f (-> any/c any/c)))
pass-list is expected to be a list of passes that compile from values-lang-v6? to x64, compatible with current-pass-list.
See v1-public-test-suite for details about the interpretation of pass-list and interp-list.
procedure
(replace-halts p [done]) → 'a
p : 'a done : symbol? = 'r15
This can be used to update v5 tests that are now incompatible with the new v6 languages.
> (replace-halts '(module (halt 5))) '(module (begin (set! rax 5) (jump r15)))
procedure
(replace-implicit-return p) → 'a
p : 'a
This can be used to update v5 tests that are now incompatible with the new v6 languages.
> (replace-implicit-return '(module (begin (set! x.1 6) x.1))) '(module (begin (set! x.1 6) (begin (set! rax x.1) (jump r15))))
procedure
(add-new-frames p) → 'a
p : 'a
This can be used to update v5 tests that are now incompatible with the new v6 languages. All v5 programs have empty new frames, since they only supported tail calls.
> (add-new-frames '(module () (define L.id.1 () (begin (set! x.1 r9) (halt x.1))) (call L.id.1 5)))
'(module
((new-frames (())))
(define L.id.1 ((new-frames (()))) (begin (set! x.1 r9) (halt x.1)))
(call L.id.1 5))
procedure
(fixup-begin p) → 'a
p : 'a
This can be used to update v5 tests that are now incompatible with the new v6 languages.
> (replace-halts '(begin (halt 5))) '(begin (begin (set! rax 5) (jump r15)))
> (fixup-begin (replace-halts '(begin (halt 5)))) '(begin (set! rax 5) (jump r15))