diff --git a/src/ikarus.boot b/src/ikarus.boot index d8c5753..3459c57 100644 Binary files a/src/ikarus.boot and b/src/ikarus.boot differ diff --git a/src/makefile.ss b/src/makefile.ss index 38c6549..ac6fd2c 100755 --- a/src/makefile.ss +++ b/src/makefile.ss @@ -125,6 +125,7 @@ [$strings (ikarus system $strings) #f] [$vectors (ikarus system $vectors) #f] [$bignums (ikarus system $bignums) #f] + [$flonums (ikarus system $flonums) #f] [$bytes (ikarus system $bytevectors) #f] [$fx (ikarus system $fx) #f] [$rat (ikarus system $ratnums) #f] @@ -154,6 +155,7 @@ [$chars (ikarus system $chars) #f] [$strings (ikarus system $strings) #f] [$vectors (ikarus system $vectors) #f] + [$flonums (ikarus system $flonums) #f] [$bignums (ikarus system $bignums) #f] [$bytes (ikarus system $bytevectors) #f] [$fx (ikarus system $fx) #f] @@ -558,6 +560,8 @@ [$bytevector-u8-ref $bytes] [$bytevector-set! $bytes] + ; [$flonum-u8-ref $flonums] + [$make-bignum $bignums] [$bignum-positive? $bignums] [$bignum-size $bignums] diff --git a/src/pass-specify-rep-primops.ss b/src/pass-specify-rep-primops.ss index eb32289..cd67070 100644 --- a/src/pass-specify-rep-primops.ss +++ b/src/pass-specify-rep-primops.ss @@ -725,6 +725,21 @@ [(P x) (sec-tag-test (T x) vector-mask vector-tag #f flonum-tag)] [(E x) (nop)]) +(define-primop $flonum-u8-ref unsafe + [(V s i) + (record-case i + [(constant i) + (unless (and (fixnum? i) (fx<= 0 i) (fx<= i 7)) + (interrupt)) + (prm 'sll + (prm 'logand + (prm 'bref (T s) + (K (+ i (- disp-flonum-data record-tag)))) + (K 255)) + (K fx-shift))] + [else (interrupt)])] + [(P s i) (K #t)] + [(E s i) (nop)]) /section) @@ -1110,7 +1125,7 @@ (unless (fixnum? i) (interrupt)) (prm 'sll (prm 'logand - (prm 'mref (T s) + (prm 'bref (T s) (K (+ i (- disp-bytevector-data bytevector-tag)))) (K 255)) (K fx-shift))] @@ -1134,7 +1149,7 @@ (prm 'sra (prm 'sll (prm 'logand - (prm 'mref (T s) + (prm 'bref (T s) (K (+ i (- disp-bytevector-data bytevector-tag)))) (K 255)) (K (- (* wordsize 8) 8)))