Raymond Toy pushed to branch issue-168-no-negated-forms-for-jmp at cmucl / cmucl

Commits:

6 changed files:

Changes:

  • .gitlab-ci.yml
    1 1
     variables:
    
    2 2
       download_url: "https://common-lisp.net/project/cmucl/downloads/snapshots/2021/07"
    
    3 3
       version: "2021-07-x86"
    
    4
    -  bootstrap: "-B boot-2021-07-2"
    
    4
    +  bootstrap: "-B boot-2021-07-1 -B boot-2021-07-2"
    
    5 5
     
    
    6 6
     stages:
    
    7 7
       - install
    

  • src/bootfiles/21d/boot-2021-07-1.lisp
    1
    +;; Bootstrap file
    
    2
    +;;
    
    3
    +;; Use "bin/build.sh -B boot-2021-07-1" to build this.
    
    4
    +;;
    
    5
    +;; We want to export the symbols from the KERNEL package which also
    
    6
    +;; exists in the C package, so we unintern the conflicting symbols from
    
    7
    +;; the C package.
    
    8
    +
    
    9
    +(in-package "KERNEL")
    
    10
    +(ext:without-package-locks
    
    11
    +  (handler-bind
    
    12
    +      ((error (lambda (c)
    
    13
    +		(declare (ignore c))
    
    14
    +		(invoke-restart 'lisp::unintern-conflicting-symbols))))
    
    15
    +    (export '(DOUBLE-FLOAT-INT-EXPONENT
    
    16
    +	      SINGLE-FLOAT-INT-EXPONENT))))
    
    17
    +

  • src/code/exports.lisp
    ... ... @@ -2329,10 +2329,11 @@
    2329 2329
     	   "DOUBLE-FLOAT-EXPONENT"
    
    2330 2330
     	   "DOUBLE-FLOAT-BITS"
    
    2331 2331
     	   "DOUBLE-FLOAT-HIGH-BITS"
    
    2332
    +	   "DOUBLE-FLOAT-INT-EXPONENT"
    
    2332 2333
     	   "DOUBLE-FLOAT-LOW-BITS" "DOUBLE-FLOAT-P" "FLOAT-WAIT"
    
    2333 2334
     	   "DYNAMIC-SPACE-FREE-POINTER" "ERROR-NUMBER-OR-LOSE" "FILENAME"
    
    2334 2335
     	   "FLOAT-DIGITS" "FLOAT-EXPONENT" "FLOAT-FORMAT-DIGITS"
    
    2335
    -	   "FLOAT-FORMAT-MAX" "FLOAT-RADIX" "FORM" "FUNCALLABLE-INSTANCE-P"
    
    2336
    +	   "FLOAT-FORMAT-MAX" "FLOAT-INT-EXPONENT" "FLOAT-RADIX" "FORM" "FUNCALLABLE-INSTANCE-P"
    
    2336 2337
     	   "FUNCTION-CODE-HEADER" "FUNCTION-TYPE" "FUNCTION-TYPE-ALLOWP"
    
    2337 2338
     	   "FUNCTION-TYPE-KEYP" "FUNCTION-TYPE-KEYWORDS"
    
    2338 2339
     	   "FUNCTION-TYPE-NARGS" "FUNCTION-TYPE-OPTIONAL" "FUNCTION-TYPE-P"
    
    ... ... @@ -2426,6 +2427,7 @@
    2426 2427
      	   "SIMPLE-ARRAY-SIGNED-BYTE-16-P" "SIMPLE-ARRAY-SIGNED-BYTE-30-P"
    
    2427 2428
     	   "SIMPLE-ARRAY-SIGNED-BYTE-32-P" "SIMPLE-ARRAY-SIGNED-BYTE-8-P" 
    
    2428 2429
     	   "SIMPLE-UNBOXED-ARRAY" "SINGLE-FLOAT-BITS" "SINGLE-FLOAT-EXPONENT"
    
    2430
    +	   "SINGLE-FLOAT-INT-EXPONENT"
    
    2429 2431
     	   "SINGLE-FLOAT-P" "SINGLE-VALUE-TYPE" "SPECIFIER-TYPE" "STACK-REF"
    
    2430 2432
     	   "STD-COMPUTE-CLASS-PRECEDENCE-LIST"
    
    2431 2433
     	   "STREAMLIKE" "SIMPLE-STREAM-BUFFER" "STRINGABLE" "STRINGLIKE"
    

  • src/compiler/fndb.lisp
    ... ... @@ -319,7 +319,7 @@
    319 319
     (defknown (float-digits float-precision) (float) float-digits
    
    320 320
       (movable foldable flushable explicit-check))
    
    321 321
     (defknown integer-decode-float (float)
    
    322
    -	  (values integer float-exponent (member -1 1))
    
    322
    +	  (values integer float-int-exponent (member -1 1))
    
    323 323
     	  (movable foldable flushable explicit-check))
    
    324 324
     
    
    325 325
     (defknown complex (real &optional real) number
    

  • src/compiler/generic/vm-type.lisp
    ... ... @@ -50,6 +50,8 @@
    50 50
     (deftype float-exponent ()
    
    51 51
       #-long-float 'double-float-exponent
    
    52 52
       #+long-float 'long-float-exponent)
    
    53
    +(deftype float-int-exponent ()
    
    54
    +  'double-float-int-exponent)
    
    53 55
     (deftype float-digits ()
    
    54 56
       #-long-float `(integer 0 ,vm:double-float-digits)
    
    55 57
       #+long-float `(integer 0 ,vm:long-float-digits))
    

  • tests/issues.lisp
    ... ... @@ -829,3 +829,14 @@
    829 829
     	(*compile-print* nil))
    
    830 830
         (assert-true (stream::find-external-format :euckr))
    
    831 831
         (assert-true (stream::find-external-format :cp949))))
    
    832
    +
    
    833
    +
    
    834
    +
    
    835
    +(define-test issue.166
    
    836
    +    (:tag :issues)
    
    837
    +  ;; While this tests for the correct return value, the problem was
    
    838
    +  ;; that the compiler was miscompiling the function below and causing
    
    839
    +  ;; an error when the function run.
    
    840
    +  (let ((f (compile nil #'(lambda ()
    
    841
    +			    (nth-value 1 (integer-decode-float least-positive-double-float))))))
    
    842
    +    (assert-equal -1126 (funcall f))))