emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bignum branch


From: Tom Tromey
Subject: Re: bignum branch
Date: Sat, 04 Aug 2018 10:39:45 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1.50 (gnu/linux)

>>>>> "Andy" == Andy Moreton <address@hidden> writes:

Andy> The patch has been tested with the attached ccl-tests.el ERT tests to
Andy> check that ash/lsh shifts behave properly, and that the CCL machinery
Andy> uses its 28bit codewords correctly in a bignum build.

Andy> Please check this works for you, and feel free to commit it to the
Andy> bignum branch.

I've applied the patch but the new test fails for me.
I've appended the log.

I'm still going to push your patch to the branch in a minute, because I
read through it and I agree with all the changes.  Thanks again for
doing this.

I fixed a couple of trivial formatting issues in your patch, and I also
added a comment by ccl-fixnum, but otherwise it's what you wrote.

Tom


Running 7 tests (2018-08-04 10:37:28-0600, selector `(not (tag :unstable))')
   passed  1/7  ccl-compile-midi (0.000601 sec)
   passed  2/7  ccl-compile-pgg (0.000303 sec)
Test ccl-dump-midi backtrace:
  signal(ert-test-failed (((should (equal (buffer-string) prog-midi-du
  ert-fail(((should (equal (buffer-string) prog-midi-dump)) :form (equ
  (if (unwind-protect (setq value-92 (apply fn-90 args-91)) (setq form
  (let (form-description-94) (if (unwind-protect (setq value-92 (apply
  (let ((value-92 'ert-form-evaluation-aborted-93)) (let (form-descrip
  (let* ((fn-90 #'equal) (args-91 (condition-case err (let ((signal-ho
  (progn (ccl-dump prog-midi-code) (let* ((fn-90 #'equal) (args-91 (co
  (unwind-protect (progn (ccl-dump prog-midi-code) (let* ((fn-90 #'equ
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn
  (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-b
  (lambda nil (let ((temp-buffer (generate-new-buffer " *temp*"))) (sa
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name ccl-dump-midi :documentation nil :bod
  ert-run-or-rerun-test(#s(ert--stats :selector (not (tag :unstable)) 
  ert-run-tests((not (tag :unstable)) #f(compiled-function (event-type
  ert-run-tests-batch((not (tag :unstable)))
  ert-run-tests-batch-and-exit((not (tag :unstable)))
  eval((ert-run-tests-batch-and-exit '(not (tag :unstable))))
  command-line-1(("-L" ":." "-l" "ert" "-l" "lisp/international/ccl-te
  command-line()
  normal-top-level()
Test ccl-dump-midi condition:
    (ert-test-failed
     ((should
       (equal
        (buffer-string)
        prog-midi-dump))
      :form
      (equal "Out-buffer must be 2 times bigger than in-buffer.
Main-body:
    2:[read-jump-cond-expr-const] read r0, if !(r0 < 128), jump to 22(+20)
    5:[branch] jump to array[r3] of length 4
        11 12 15 18 22 
   11:[jump] jump to 2(-9)
   12:[set-register] r1 = r0
   13:[set-register] r0 = r4
   14:[jump] jump to 41(+27)
   15:[set-register] r1 = r0
   16:[set-short-const] r3 = 3
   17:[jump] jump to 2(-15)
   18:[set-register] r2 = r0
   19:[set-short-const] r3 = 2
   20:[set-register] r0 = r4
   21:[jump] jump to 41(+20)
   22:[jump-cond-expr-const] if !(r0 >= 248), jump to 26(+4)
   25:[jump] jump to 41(+16)
   26:[jump-cond-expr-const] if !(r0 < 240), jump to 39(+13)
   29:[set-register] r4 = r0
   30:[set-expr-const] r7 = r0 & 224
   32:[jump-cond-expr-const] if !(r7 == 192), jump to 37(+5)
   35:[set-short-const] r3 = 1
   36:[jump] jump to 38(+2)
   37:[set-short-const] r3 = 2
   38:[jump] jump to 2(-36)
   39:[set-short-const] r3 = 0
   40:[jump] jump to 2(-38)
   41:[set-expr-const] r7 = r0 & 240
   43:[jump-cond-expr-const] if !(r7 == 144), jump to 59(+16)
   46:[jump-cond-expr-const] if !(r2 == 0), jump to 52(+6)
   49:[set-assign-expr-const] r0 -= 16
   51:[jump] jump to 59(+8)
   52:[set-assign-expr-const] r0 &= 15
   54:[write-const-string] write char \".\"
   55:[write-register] write r0 (2 remaining)
   56:[write-register] write r1 (1 remaining)
   57:[write-register] write r2 (0 remaining)
   58:[jump] jump to 2(-56)
   59:[set-expr-const] r7 = r0 & 240
   61:[jump-cond-expr-const] if !(r7 == 128), jump to 71(+10)
   64:[set-assign-expr-const] r0 &= 15
   66:[write-const-string] write char \".\"
   67:[write-register] write r0 (2 remaining)
   68:[write-register] write r1 (1 remaining)
   69:[write-register] write r2 (0 remaining)
   70:[jump] jump to 2(-68)
   71:[jump] jump to 2(-69)
At EOF:
   72:[end] end
" "Out-buffer must be 2 times bigger than in-buffer.
Main-body:
    2:[read-jump-cond-expr-const] read r0, if !(r0 < 128), jump to 22(+20)
    5:[branch] jump to array[r3] of length 4
        11 12 15 18 22
   11:[jump] jump to 2(-9)
   12:[set-register] r1 = r0
   13:[set-register] r0 = r4
   14:[jump] jump to 41(+27)
   15:[set-register] r1 = r0
   16:[set-short-const] r3 = 3
   17:[jump] jump to 2(-15)
   18:[set-register] r2 = r0
   19:[set-short-const] r3 = 2
   20:[set-register] r0 = r4
   21:[jump] jump to 41(+20)
   22:[jump-cond-expr-const] if !(r0 >= 248), jump to 26(+4)
   25:[jump] jump to 41(+16)
   26:[jump-cond-expr-const] if !(r0 < 240), jump to 39(+13)
   29:[set-register] r4 = r0
   30:[set-expr-const] r7 = r0 & 224
   32:[jump-cond-expr-const] if !(r7 == 192), jump to 37(+5)
   35:[set-short-const] r3 = 1
   36:[jump] jump to 38(+2)
   37:[set-short-const] r3 = 2
   38:[jump] jump to 2(-36)
   39:[set-short-const] r3 = 0
   40:[jump] jump to 2(-38)
   41:[set-expr-const] r7 = r0 & 240
   43:[jump-cond-expr-const] if !(r7 == 144), jump to 59(+16)
   46:[jump-cond-expr-const] if !(r2 == 0), jump to 52(+6)
   49:[set-assign-expr-const] r0 -= 16
   51:[jump] jump to 59(+8)
   52:[set-assign-expr-const] r0 &= 15
   54:[write-const-string] write char \".\"
   55:[write-register] write r0 (2 remaining)
   56:[write-register] write r1 (1 remaining)
   57:[write-register] write r2 (0 remaining)
   58:[jump] jump to 2(-56)
   59:[set-expr-const] r7 = r0 & 240
   61:[jump-cond-expr-const] if !(r7 == 128), jump to 71(+10)
   64:[set-assign-expr-const] r0 &= 15
   66:[write-const-string] write char \".\"
   67:[write-register] write r0 (2 remaining)
   68:[write-register] write r1 (1 remaining)
   69:[write-register] write r2 (0 remaining)
   70:[jump] jump to 2(-68)
   71:[jump] jump to 2(-69)
At EOF:
   72:[end] end
")
      :value nil :explanation
      (arrays-of-different-length 1843 1842 "Out-buffer must be 2 times bigger 
than in-buffer.
Main-body:
    2:[read-jump-cond-expr-const] read r0, if !(r0 < 128), jump to 22(+20)
    5:[branch] jump to array[r3] of length 4
        11 12 15 18 22 
   11:[jump] jump to 2(-9)
   12:[set-register] r1 = r0
   13:[set-register] r0 = r4
   14:[jump] jump to 41(+27)
   15:[set-register] r1 = r0
   16:[set-short-const] r3 = 3
   17:[jump] jump to 2(-15)
   18:[set-register] r2 = r0
   19:[set-short-const] r3 = 2
   20:[set-register] r0 = r4
   21:[jump] jump to 41(+20)
   22:[jump-cond-expr-const] if !(r0 >= 248), jump to 26(+4)
   25:[jump] jump to 41(+16)
   26:[jump-cond-expr-const] if !(r0 < 240), jump to 39(+13)
   29:[set-register] r4 = r0
   30:[set-expr-const] r7 = r0 & 224
   32:[jump-cond-expr-const] if !(r7 == 192), jump to 37(+5)
   35:[set-short-const] r3 = 1
   36:[jump] jump to 38(+2)
   37:[set-short-const] r3 = 2
   38:[jump] jump to 2(-36)
   39:[set-short-const] r3 = 0
   40:[jump] jump to 2(-38)
   41:[set-expr-const] r7 = r0 & 240
   43:[jump-cond-expr-const] if !(r7 == 144), jump to 59(+16)
   46:[jump-cond-expr-const] if !(r2 == 0), jump to 52(+6)
   49:[set-assign-expr-const] r0 -= 16
   51:[jump] jump to 59(+8)
   52:[set-assign-expr-const] r0 &= 15
   54:[write-const-string] write char \".\"
   55:[write-register] write r0 (2 remaining)
   56:[write-register] write r1 (1 remaining)
   57:[write-register] write r2 (0 remaining)
   58:[jump] jump to 2(-56)
   59:[set-expr-const] r7 = r0 & 240
   61:[jump-cond-expr-const] if !(r7 == 128), jump to 71(+10)
   64:[set-assign-expr-const] r0 &= 15
   66:[write-const-string] write char \".\"
   67:[write-register] write r0 (2 remaining)
   68:[write-register] write r1 (1 remaining)
   69:[write-register] write r2 (0 remaining)
   70:[jump] jump to 2(-68)
   71:[jump] jump to 2(-69)
At EOF:
   72:[end] end
" "Out-buffer must be 2 times bigger than in-buffer.
Main-body:
    2:[read-jump-cond-expr-const] read r0, if !(r0 < 128), jump to 22(+20)
    5:[branch] jump to array[r3] of length 4
        11 12 15 18 22
   11:[jump] jump to 2(-9)
   12:[set-register] r1 = r0
   13:[set-register] r0 = r4
   14:[jump] jump to 41(+27)
   15:[set-register] r1 = r0
   16:[set-short-const] r3 = 3
   17:[jump] jump to 2(-15)
   18:[set-register] r2 = r0
   19:[set-short-const] r3 = 2
   20:[set-register] r0 = r4
   21:[jump] jump to 41(+20)
   22:[jump-cond-expr-const] if !(r0 >= 248), jump to 26(+4)
   25:[jump] jump to 41(+16)
   26:[jump-cond-expr-const] if !(r0 < 240), jump to 39(+13)
   29:[set-register] r4 = r0
   30:[set-expr-const] r7 = r0 & 224
   32:[jump-cond-expr-const] if !(r7 == 192), jump to 37(+5)
   35:[set-short-const] r3 = 1
   36:[jump] jump to 38(+2)
   37:[set-short-const] r3 = 2
   38:[jump] jump to 2(-36)
   39:[set-short-const] r3 = 0
   40:[jump] jump to 2(-38)
   41:[set-expr-const] r7 = r0 & 240
   43:[jump-cond-expr-const] if !(r7 == 144), jump to 59(+16)
   46:[jump-cond-expr-const] if !(r2 == 0), jump to 52(+6)
   49:[set-assign-expr-const] r0 -= 16
   51:[jump] jump to 59(+8)
   52:[set-assign-expr-const] r0 &= 15
   54:[write-const-string] write char \".\"
   55:[write-register] write r0 (2 remaining)
   56:[write-register] write r1 (1 remaining)
   57:[write-register] write r2 (0 remaining)
   58:[jump] jump to 2(-56)
   59:[set-expr-const] r7 = r0 & 240
   61:[jump-cond-expr-const] if !(r7 == 128), jump to 71(+10)
   64:[set-assign-expr-const] r0 &= 15
   66:[write-const-string] write char \".\"
   67:[write-register] write r0 (2 remaining)
   68:[write-register] write r1 (1 remaining)
   69:[write-register] write r2 (0 remaining)
   70:[jump] jump to 2(-68)
   71:[jump] jump to 2(-69)
At EOF:
   72:[end] end
" first-mismatch-at 196)))
   FAILED  3/7  ccl-dump-midi (0.001107 sec)
   passed  4/7  ccl-dump-pgg (0.000431 sec)
   passed  5/7  pgg-parse-crc24 (0.009028 sec)
   passed  6/7  pgg-parse-crc24-dump (0.000449 sec)
   passed  7/7  shift (0.000209 sec)

Ran 7 tests, 6 results as expected, 1 unexpected (2018-08-04 10:37:28-0600, 
0.093933 sec)

1 unexpected results:
   FAILED  ccl-dump-midi




reply via email to

[Prev in Thread] Current Thread [Next in Thread]