version hacks for benchmarking

This commit is contained in:
ESL 2024-07-28 18:19:40 -04:00
parent 19563b11cc
commit 0e4031ac6e
4 changed files with 46 additions and 34 deletions

2
misc/Skint-postlude.scm Normal file
View file

@ -0,0 +1,2 @@
(define (this-scheme-implementation-name)
(string-append "skint-" (implementation-version)))

0
misc/Skint-prelude.scm Normal file
View file

View file

@ -2139,7 +2139,7 @@
(string-cmp) (string-ci-cmp) (vector-cat) (bytevector=?) (bytevector->list) (list->bytevector) (string-cmp) (string-ci-cmp) (vector-cat) (bytevector=?) (bytevector->list) (list->bytevector)
(subbytevector) (standard-input-port) (standard-output-port) (standard-error-port) (tty-port?) (subbytevector) (standard-input-port) (standard-output-port) (standard-error-port) (tty-port?)
(port-fold-case?) (set-port-fold-case!) (rename-file) (current-directory) (directory-separator) (port-fold-case?) (set-port-fold-case!) (rename-file) (current-directory) (directory-separator)
(void) (void?) (void) (void?) (implementation-name) (implementation-version)
; (repl hidden) library entries below the auto-adder need to be added explicitly ; (repl hidden) library entries below the auto-adder need to be added explicitly
(*user-name-registry* . hidden) (make-readonly-environment . hidden) (*user-name-registry* . hidden) (make-readonly-environment . hidden)
(make-controlled-environment . hidden) (make-sld-environment . hidden) (make-controlled-environment . hidden) (make-sld-environment . hidden)
@ -2697,6 +2697,9 @@
(define *skint-version* "0.4.9") (define *skint-version* "0.4.9")
(define (implementation-version) *skint-version*)
(define (implementation-name) "SKINT")
(define (skint-main) (define (skint-main)
; see if command line asks for special processing ; see if command line asks for special processing
(define (eval! str print?) (define (eval! str print?)

71
t.c
View file

@ -1179,7 +1179,7 @@ char *t_code[] = {
"0:*root-name-registry*),@(y11:name-lookup)[03}", "0:*root-name-registry*),@(y11:name-lookup)[03}",
"C", 0, "C", 0,
"${'(l508:l3:y1:*;y1:v;y1:b;;l3:y1:+;y1:v;y1:b;;l3:y1:-;y1:v;y1:b;;l4:y" "${'(l510:l3:y1:*;y1:v;y1:b;;l3:y1:+;y1:v;y1:b;;l3:y1:-;y1:v;y1:b;;l4:y"
"3:...;y1:v;y1:u;y1:b;;l3:y1:/;y1:v;y1:b;;l3:y1:<;y1:v;y1:b;;l3:y2:<=;y" "3:...;y1:v;y1:u;y1:b;;l3:y1:/;y1:v;y1:b;;l3:y1:<;y1:v;y1:b;;l3:y2:<=;y"
"1:v;y1:b;;l3:y1:=;y1:v;y1:b;;l4:y2:=>;y1:v;y1:u;y1:b;;l3:y1:>;y1:v;y1:" "1:v;y1:b;;l3:y1:=;y1:v;y1:b;;l4:y2:=>;y1:v;y1:u;y1:b;;l3:y1:>;y1:v;y1:"
"b;;l3:y2:>=;y1:v;y1:b;;l2:y1:_;y1:b;;l3:y3:abs;y1:v;y1:b;;l4:y3:and;y1" "b;;l3:y2:>=;y1:v;y1:b;;l2:y1:_;y1:b;;l3:y3:abs;y1:v;y1:b;;l4:y3:and;y1"
@ -1343,37 +1343,38 @@ char *t_code[] = {
"ndard-output-port;;l1:y19:standard-error-port;;l1:y9:tty-port?;;l1:y15" "ndard-output-port;;l1:y19:standard-error-port;;l1:y9:tty-port?;;l1:y15"
":port-fold-case?;;l1:y19:set-port-fold-case!;;l1:y11:rename-file;;l1:y" ":port-fold-case?;;l1:y19:set-port-fold-case!;;l1:y11:rename-file;;l1:y"
"17:current-directory;;l1:y19:directory-separator;;l1:y4:void;;l1:y5:vo" "17:current-directory;;l1:y19:directory-separator;;l1:y4:void;;l1:y5:vo"
"id?;;py20:*user-name-registry*;y6:hidden;;py25:make-readonly-environme" "id?;;l1:y19:implementation-name;;l1:y22:implementation-version;;py20:*"
"nt;y6:hidden;;py27:make-controlled-environment;y6:hidden;;py20:make-sl" "user-name-registry*;y6:hidden;;py25:make-readonly-environment;y6:hidde"
"d-environment;y6:hidden;;py21:make-repl-environment;y6:hidden;;py19:fi" "n;;py27:make-controlled-environment;y6:hidden;;py20:make-sld-environme"
"nd-library-in-env;y6:hidden;;py16:root-environment;y6:hidden;;py16:rep" "nt;y6:hidden;;py21:make-repl-environment;y6:hidden;;py19:find-library-"
"l-environment;y6:hidden;;py17:empty-environment;y6:hidden;;py32:make-h" "in-env;y6:hidden;;py16:root-environment;y6:hidden;;py16:repl-environme"
"istoric-report-environment;y6:hidden;;py16:r5rs-environment;y6:hidden;" "nt;y6:hidden;;py17:empty-environment;y6:hidden;;py32:make-historic-rep"
";py21:r5rs-null-environment;y6:hidden;;py9:*verbose*;y6:hidden;;py7:*q" "ort-environment;y6:hidden;;py16:r5rs-environment;y6:hidden;;py21:r5rs-"
"uiet*;y6:hidden;;py25:compile-and-run-core-expr;y6:hidden;;py17:evalua" "null-environment;y6:hidden;;py9:*verbose*;y6:hidden;;py7:*quiet*;y6:hi"
"te-top-form;y6:hidden;;py10:run-script;y6:hidden;;py11:run-program;y6:" "dden;;py25:compile-and-run-core-expr;y6:hidden;;py17:evaluate-top-form"
"hidden;;py22:repl-evaluate-top-form;y6:hidden;;py9:repl-read;y6:hidden" ";y6:hidden;;py10:run-script;y6:hidden;;py11:run-program;y6:hidden;;py2"
";;py17:repl-exec-command;y6:hidden;;py14:repl-from-port;y6:hidden;;py1" "2:repl-evaluate-top-form;y6:hidden;;py9:repl-read;y6:hidden;;py17:repl"
"3:run-benchmark;y6:hidden;;py4:repl;y6:hidden;;),&0{%1,,,,#0#1#2#3&0{%" "-exec-command;y6:hidden;;py14:repl-from-port;y6:hidden;;py13:run-bench"
"1.0,'(y1:w),.1v?{'(l2:y6:scheme;y5:write;)]2}'(y1:t),.1v?{'(l2:y6:sche" "mark;y6:hidden;;py4:repl;y6:hidden;;),&0{%1,,,,#0#1#2#3&0{%1.0,'(y1:w)"
"me;y4:time;)]2}'(y1:p),.1v?{'(l2:y6:scheme;y4:repl;)]2}'(y1:r),.1v?{'(" ",.1v?{'(l2:y6:scheme;y5:write;)]2}'(y1:t),.1v?{'(l2:y6:scheme;y4:time;"
"l2:y6:scheme;y4:read;)]2}'(y1:v),.1v?{'(l2:y6:scheme;y4:r5rs;)]2}'(y1:" ")]2}'(y1:p),.1v?{'(l2:y6:scheme;y4:repl;)]2}'(y1:r),.1v?{'(l2:y6:schem"
"u),.1v?{'(l2:y6:scheme;y9:r5rs-null;)]2}'(y1:d),.1v?{'(l2:y6:scheme;y4" "e;y4:read;)]2}'(y1:v),.1v?{'(l2:y6:scheme;y4:r5rs;)]2}'(y1:u),.1v?{'(l"
":load;)]2}'(y1:z),.1v?{'(l2:y6:scheme;y4:lazy;)]2}'(y1:s),.1v?{'(l2:y6" "2:y6:scheme;y9:r5rs-null;)]2}'(y1:d),.1v?{'(l2:y6:scheme;y4:load;)]2}'"
":scheme;y15:process-context;)]2}'(y1:i),.1v?{'(l2:y6:scheme;y7:inexact" "(y1:z),.1v?{'(l2:y6:scheme;y4:lazy;)]2}'(y1:s),.1v?{'(l2:y6:scheme;y15"
";)]2}'(y1:f),.1v?{'(l2:y6:scheme;y4:file;)]2}'(y1:e),.1v?{'(l2:y6:sche" ":process-context;)]2}'(y1:i),.1v?{'(l2:y6:scheme;y7:inexact;)]2}'(y1:f"
"me;y4:eval;)]2}'(y1:o),.1v?{'(l2:y6:scheme;y7:complex;)]2}'(y1:h),.1v?" "),.1v?{'(l2:y6:scheme;y4:file;)]2}'(y1:e),.1v?{'(l2:y6:scheme;y4:eval;"
"{'(l2:y6:scheme;y4:char;)]2}'(y1:l),.1v?{'(l2:y6:scheme;y11:case-lambd" ")]2}'(y1:o),.1v?{'(l2:y6:scheme;y7:complex;)]2}'(y1:h),.1v?{'(l2:y6:sc"
"a;)]2}'(y1:a),.1v?{'(l2:y6:scheme;y3:cxr;)]2}'(y1:b),.1v?{'(l2:y6:sche" "heme;y4:char;)]2}'(y1:l),.1v?{'(l2:y6:scheme;y11:case-lambda;)]2}'(y1:"
"me;y4:base;)]2}'(y1:x),.1v?{'(l2:y6:scheme;y3:box;)]2}.1I0?{.1,'(y4:sr" "a),.1v?{'(l2:y6:scheme;y3:cxr;)]2}'(y1:b),.1v?{'(l2:y6:scheme;y4:base;"
"fi),l2]2}.1,l1]2}.!0&0{%1${&0{%1n,'(l1:y5:begin;),V12]1},.3,@(y20:*roo" ")]2}'(y1:x),.1v?{'(l2:y6:scheme;y3:box;)]2}.1I0?{.1,'(y4:srfi),l2]2}.1"
"t-name-registry*),@(y11:name-lookup)[03}z]1}.!1&0{%3'1,.1V4,.0,.3A3,.0" ",l1]2}.!0&0{%1${&0{%1n,'(l1:y5:begin;),V12]1},.3,@(y20:*root-name-regi"
"?{.4,.1sd]5}.1,.5,.5cc,'1,.4V5]5}.!2&0{%1&0{%1.0,'(y5:const),l2]1},.1," "stry*),@(y11:name-lookup)[03}z]1}.!1&0{%3'1,.1V4,.0,.3A3,.0?{.4,.1sd]5"
"@(y20:*root-name-registry*),@(y11:name-lookup)[13}.!3.4d,.5a,,#0.0,.6," "}.1,.5,.5cc,'1,.4V5]5}.!2&0{%1&0{%1.0,'(y5:const),l2]1},.1,@(y20:*root"
".5,.7,.(i10),&5{%2.1u?{${.2,:0^[01},.1,${'(l1:y5:skint;),:1^[01},:3^[2" "-name-registry*),@(y11:name-lookup)[13}.!3.4d,.5a,,#0.0,.6,.5,.7,.(i10"
"3}.1p~?{${.2,:0^[01},.1,${n,.6c,'(y5:skint)c,:1^[01},:3^[23}${${.4,:0^" "),&5{%2.1u?{${.2,:0^[01},.1,${'(l1:y5:skint;),:1^[01},:3^[23}.1p~?{${."
"[01},.3,${${.9a,:2^[01},:1^[01},:3^[03}.1d,.1,:4^[22}.!0.0^_1[52},@(y1" "2,:0^[01},.1,${n,.6c,'(y5:skint)c,:1^[01},:3^[23}${${.4,:0^[01},.3,${$"
"0:%25for-each1)[02}", "{.9a,:2^[01},:1^[01},:3^[03}.1d,.1,:4^[22}.!0.0^_1[52},@(y10:%25for-ea"
"ch1)[02}",
"C", 0, "C", 0,
"@(y20:*root-name-registry*),${f,'(l1:y5:skint;),.4,@(y11:name-lookup)[" "@(y20:*root-name-registry*),${f,'(l1:y5:skint;),.4,@(y11:name-lookup)["
@ -1713,6 +1714,12 @@ char *t_code[] = {
"C", 0, "C", 0,
"'(s5:0.4.9)@!(y15:*skint-version*)", "'(s5:0.4.9)@!(y15:*skint-version*)",
"P", "implementation-version",
"%0@(y15:*skint-version*)]0",
"P", "implementation-name",
"%0'(s5:SKINT)]0",
"P", "skint-main", "P", "skint-main",
"%0,,,,,#0#1#2#3#4&0{%2${.2,@(y16:read-from-string)[01},${@(y4:list),.3" "%0,,,,,#0#1#2#3#4&0{%2${.2,@(y16:read-from-string)[01},${@(y4:list),.3"
",&1{%0:0,@(y4:eval)[01},@(y16:call-with-values)[02},.3,&1{%1:0?{Po,.1W" ",&1{%0:0,@(y4:eval)[01},@(y16:call-with-values)[02},.3,&1{%1:0?{Po,.1W"