Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alexandria test #885

Closed
kpoeck opened this issue Dec 5, 2019 · 10 comments
Closed

Alexandria test #885

kpoeck opened this issue Dec 5, 2019 · 10 comments

Comments

@kpoeck
Copy link
Contributor

kpoeck commented Dec 5, 2019

clasp --eval "(require :asdf)" --load "~/quicklisp/setup.lisp"

Starting cclasp-boehm-0.4.2-1662-g8d0a04160-cst ... loading image...
Top level in: #<PROCESS TOP-LEVEL @0x113013279>.
COMMON-LISP-USER> (ql:quickload "alexandria-tests" :verbose t)
To load "alexandria-tests":
  Load 1 ASDF system:
    alexandria-tests
; Loading "alexandria-tests"

("alexandria-tests")
COMMON-LISP-USER> (alexandria-tests::run-tests :compiled t)

Doing 227 pending tests of 227 tests total.
 ALEXANDRIA-TESTS::COPY-ARRAY.1 ALEXANDRIA-TESTS::COPY-ARRAY.2
 ALEXANDRIA-TESTS::COPY-ARRAY.3 ALEXANDRIA-TESTS::COPY-ARRAY.4
 ALEXANDRIA-TESTS::ARRAY-INDEX.1 ALEXANDRIA-TESTS::UNWIND-PROTECT-CASE.1
 ALEXANDRIA-TESTS::UNWIND-PROTECT-CASE.2
 ALEXANDRIA-TESTS::UNWIND-PROTECT-CASE.3
 ALEXANDRIA-TESTS::UNWIND-PROTECT-CASE.4
 ALEXANDRIA-TESTS::UNWIND-PROTECT-CASE.5 ALEXANDRIA-TESTS::SWITCH.1
 ALEXANDRIA-TESTS::SWITCH.2 ALEXANDRIA-TESTS::ESWITCH.1
 ALEXANDRIA-TESTS::ESWITCH.2 ALEXANDRIA-TESTS::CSWITCH.1
 ALEXANDRIA-TESTS::CSWITCH.2 ALEXANDRIA-TESTS::MULTIPLE-VALUE-PROG2.1
 ALEXANDRIA-TESTS::NTH-VALUE-OR.1 ALEXANDRIA-TESTS::WHICHEVER.1
 ALEXANDRIA-TESTS::WHICHEVER.2 ALEXANDRIA-TESTS::XOR.1
 ALEXANDRIA-TESTS::XOR.2 ALEXANDRIA-TESTS::XOR.3
 ALEXANDRIA-TESTS::DEFINE-CONSTANT.1 ALEXANDRIA-TESTS::DEFINE-CONSTANT.2
 ALEXANDRIA-TESTS::REQUIRED-ARGUMENT.1
 ALEXANDRIA-TESTS::ENSURE-GETHASH.1 ALEXANDRIA-TESTS::ENSURE-GETHASH.2
 ALEXANDRIA-TESTS::COPY-HASH-TABLE.1 ALEXANDRIA-TESTS::COPY-HASH-TABLE.2
 ALEXANDRIA-TESTS::MAPHASH-KEYS.1 ALEXANDRIA-TESTS::MAPHASH-VALUES.1
 ALEXANDRIA-TESTS::HASH-TABLE-KEYS.1
 ALEXANDRIA-TESTS::HASH-TABLE-VALUES.1
 ALEXANDRIA-TESTS::HASH-TABLE-ALIST.1
 ALEXANDRIA-TESTS::HASH-TABLE-PLIST.1
 ALEXANDRIA-TESTS::ALIST-HASH-TABLE.1
 ALEXANDRIA-TESTS::ALIST-HASH-TABLE.DUPLICATE-KEYS
 ALEXANDRIA-TESTS::PLIST-HASH-TABLE.1
 ALEXANDRIA-TESTS::PLIST-HASH-TABLE.DUPLICATE-KEYS
 ALEXANDRIA-TESTS::DISJOIN.1 ALEXANDRIA-TESTS::DISJOIN.2
 ALEXANDRIA-TESTS::CONJOIN.1 ALEXANDRIA-TESTS::CONJOIN.2
 ALEXANDRIA-TESTS::COMPOSE.1 ALEXANDRIA-TESTS::COMPOSE.2
 ALEXANDRIA-TESTS::COMPOSE.3 ALEXANDRIA-TESTS::COMPOSE.4
 ALEXANDRIA-TESTS::MULTIPLE-VALUE-COMPOSE.1
 ALEXANDRIA-TESTS::MULTIPLE-VALUE-COMPOSE.2
 ALEXANDRIA-TESTS::MULTIPLE-VALUE-COMPOSE.3
 ALEXANDRIA-TESTS::MULTIPLE-VALUE-COMPOSE.4 ALEXANDRIA-TESTS::CURRY.1
 ALEXANDRIA-TESTS::CURRY.2 ALEXANDRIA-TESTS::CURRY.3
 ALEXANDRIA-TESTS::CURRY.4 ALEXANDRIA-TESTS::RCURRY.1
 ALEXANDRIA-TESTS::RCURRY.2 ALEXANDRIA-TESTS::NAMED-LAMBDA.1
 ALEXANDRIA-TESTS::NAMED-LAMBDA.2 ALEXANDRIA-TESTS::ALIST-PLIST.1
 ALEXANDRIA-TESTS::PLIST-ALIST.1 ALEXANDRIA-TESTS::UNIONF.1
 ALEXANDRIA-TESTS::NUNIONF.1 ALEXANDRIA-TESTS::APPENDF.1
 ALEXANDRIA-TESTS::NCONCF.1 ALEXANDRIA-TESTS::CIRCULAR-LIST.1
 ALEXANDRIA-TESTS::CIRCULAR-LIST-P.1 ALEXANDRIA-TESTS::CIRCULAR-LIST-P.2
 ALEXANDRIA-TESTS::CIRCULAR-TREE-P.1Illegal instruction: 4
@kpoeck
Copy link
Contributor Author

kpoeck commented Dec 5, 2019

With lldb seems to die in infinite recursion:

Process 30072 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=2, address=0x7ffee4aafff8)
    frame #0: 0x000000010bc7d014 clasp`core::HashTable_O::tableRef_no_read_lock(this=0x00000001677c91d8, key=(theObject = 0x0000000151dd3e63), under_write_lock=<unavailable>, index=20) at hashTable.cc:639:17 [opt]
   636 	    if (entry._Car.unboundp()) goto NOT_FOUND;
   637 	    if (!entry._Car.deletedp()) {
   638 	      DEBUG_HASH_TABLE({core::write_bf_stream(BF("%s:%d search-end !deletedp index = %ld\n") % __FILE__ % __LINE__ % cur );});
-> 639 	      if (this->keyTest(entry._Car, key)) {
   640 	        DEBUG_HASH_TABLE({core::write_bf_stream(BF("%s:%d search-end found key index = %ld entry._Car->%p\n .... %s\n  key->%p\n .... %s\n") % __FILE__ % __LINE__ % cur % (void*)entry._Car.raw_() % dbg_safe_repr((uintptr_t)(void*)entry._Car.raw_()).c_str() % (void*)key.raw_() % dbg_safe_repr((uintptr_t)(void*)key.raw_()).c_str() );});
   641 	        
   642 	        return gc::smart_ptr<Cons_O>((Cons_O*)&entry);
Target 0: (clasp) stopped.
(lldb) help bt
     Show the current thread's call stack.  Any numeric argument displays at most that many frames.  The argument 'all' displays all threads.  Expects 'raw' input (see 'help raw-input'.)

Syntax: bt [<digit> | all]

'bt' is an abbreviation for '_regexp-bt'
(lldb) bt 50
error: need to add support for DW_TAG_base_type 'int' encoded with DW_ATE = 0xd, bit_size = 64
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=2, address=0x7ffee4aafff8)
  * frame #0: 0x000000010bc7d014 clasp`core::HashTable_O::tableRef_no_read_lock(this=0x00000001677c91d8, key=(theObject = 0x0000000151dd3e63), under_write_lock=<unavailable>, index=20) at hashTable.cc:639:17 [opt]
    frame #1: 0x000000010bc7d4f1 clasp`core::HashTable_O::gethash(this=0x00000001677c91d8, key=(theObject = 0x0000000151dd3e63), default_value=<unavailable>) at hashTable.cc:689:32 [opt]
    frame #2: 0x000000010a813af2 clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:88:45
    frame #3: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #4: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #5: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #6: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #7: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #8: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #9: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #10: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #11: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #12: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #13: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #14: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #15: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #16: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #17: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #18: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #19: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #20: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23
    frame #21: 0x000000010a813b2f clasp`LAMBDA^COMMON-LISP^FN^^(nargs=<unavailable>, farg0=<unavailable>, farg1=<unavailable>, farg2=<unavailable>, farg3=<unavailable>) at reconstruct.lisp:90:23

@kpoeck
Copy link
Contributor Author

kpoeck commented Dec 5, 2019

the start of te recurions seem to be in add-atoms in reconstruct.lisp in line 90, t.m.
(traverse (first cst) new-inside-p)

@Bike
Copy link
Member

Bike commented Dec 6, 2019

https://github.com/keithj/alexandria/blob/0426bd2fae19ae0492d44407f17ac1005196c9c3/tests.lisp#L677

Maybe CST can't handle '#1=(#1#)? I'll check tomorrow.

@kpoeck
Copy link
Contributor Author

kpoeck commented Dec 7, 2019

Must be a bit more complex:

(in-package :cl-user)

(defun foo ()
  (identity '#1=(#1#))

(defun bar ()
  (funcall
   (compile nil
            `(lambda()
               (identity '#1=(#1#))))
   nil))

compile-file of that dies compiling bar, not foo.

In a repl, already(defun foo () (identity '#1=(#1#)))dies

@Bike
Copy link
Member

Bike commented Dec 9, 2019

`#1=(#1#) is sufficient to kill in a file, so that's probably the backquote compiler macro

ed: no of course it's something later as you already said

@Bike
Copy link
Member

Bike commented Dec 9, 2019

Nope, it's the reader macro. Don't know why you're seeing it crash in traverse, I'm getting an obvious infinite recursion in Eclector. I'll report that.

But hey, maybe more than one thing is crashing

eta: clasp's quasiquote macro also dies on this example

@Bike
Copy link
Member

Bike commented Dec 11, 2019

found another infinite loop, in CST/reconstruct.

@Bike
Copy link
Member

Bike commented Dec 15, 2019

@Bike
Copy link
Member

Bike commented Dec 17, 2019

If I apply that patch locally, I can load and run alexandria-tests without crashing.

@kpoeck
Copy link
Contributor Author

kpoeck commented Jan 10, 2020

With newest Concret-Sytax-Tree It works as Bike says
Will make a Pr to update Concret-Sytax-Tree in wscript

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants