vscosta / yap-6.3

YAP Development release
Other
13 stars 5 forks source link

numbervars/3 tests crash yap #52

Open pmoura opened 4 years ago

pmoura commented 4 years ago

Using the numbervars/3 predicate tests in the latest Logtalk git version:

?- {tester}.
Unknown message: style_check(singleton([A=_241619,B=_241629,C=_241639]),18,/Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/.lgt_tmp/tests_90788162_lgt.yap,($tests#0.test#3(commons_numbervars_3_06,[],true,_241597):-_241603=a(_241604,_241605,_241606),numbervars(_241603,0,_241614),$lgt_obj_super_call_($tests#0._super,assertion(_241604==_241619),_241597),$lgt_obj_super_call_($tests#0._super,assertion(_241605==_241629),_241597),$lgt_obj_super_call_($tests#0._super,assertion(_241606==_241639),_241597)))
% 
% tests started at 2020/1/6, 15:31:37
% 
% running tests from object tests
% file: /Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/tests.lgt
% 
% commons_numbervars_3_01: success
% commons_numbervars_3_02: success
% commons_numbervars_3_03: success
% commons_numbervars_3_04: success
!     commons_numbervars_3_05: failure 
!       test assertion failed: 3==6
!       in file /Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/tests.lgt between lines 51-56
% Fatal YAP Error:  exiting....

   Exiting ....
Execution stack:
       0   libYap.6.5.dylib                    0x000000010b84091e error_exit_yap + 94
       1   libYap.6.5.dylib                    0x000000010b82c7d2 Yap_Error__ + 834
       2   libYap.6.5.dylib                    0x000000010ba0bb73 SearchForTrailFault + 195
       3   libYap.6.5.dylib                    0x000000010ba09d9c HandleSIGSEGV + 188
       4   libsystem_platform.dylib            0x00007fff59b8fb5d _sigtramp + 29
       5   ???                                 0x0000000000000000 0x0 + 0
       6   libYap.6.5.dylib                    0x000000010b96f549 Yap_NumberVars + 441
       7   libYap.6.5.dylib                    0x000000010b97387f p_numbervars + 831
       8   libYap.6.5.dylib                    0x000000010b707e9d Yap_absmi + 132893
       9   libYap.6.5.dylib                    0x000000010b85253f exec_absmi + 1455
       10  libYap.6.5.dylib                    0x000000010b852d6e do_goal + 94
       11  libYap.6.5.dylib                    0x000000010b8540f0 Yap_RunTopGoal + 1184
       12  libYap.6.5.dylib                    0x000000010b9a7619 YAP_RunGoalOnce + 217
       13  yap                                 0x000000010b6dbe15 do_top_goal + 21
       14  yap                                 0x000000010b6dbdc3 exec_top_level + 147
       15  yap                                 0x000000010b6dbc32 main + 322
       16  libdyld.dylib                       0x00007fff599a43d5 start + 1
       17  ???                                 0x0000000000000003 0x0 + 3
vscosta commented 4 years ago

Obrigado Paulo

I am trying to track a bug in numbervars for a while, that will be really useful.

Also, thanks for all your work with the testing framework. Usually YAP was between 409 and 500 failures. This release is worse than usual, but I felt I couldn keep procrastinating until the perfect release :)

Thanks again

Vitor

On Mon, Jan 6, 2020 at 3:34 PM Paulo Moura notifications@github.com wrote:

Using the numbervars/3 predicate tests in the latest Logtalk git version:

?- {tester}. Unknown message: style_check(singleton([A=_241619,B=_241629,C=_241639]),18,/Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/.lgt_tmp/tests_90788162_lgt.yap,($tests#0.test#3(commons_numbervars_3_06,[],true,_241597):-_241603=a(_241604,_241605,_241606),numbervars(_241603,0,_241614),$lgt_obj_supercall($tests#0._super,assertion(_241604==_241619),_241597),$lgt_obj_supercall($tests#0._super,assertion(_241605==_241629),_241597),$lgt_obj_supercall($tests#0._super,assertion(_241606==_241639),_241597)))% % tests started at 2020/1/6, 15:31:37% % running tests from object tests% file: /Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/tests.lgt% % commons_numbervars_3_01: success% commons_numbervars_3_02: success% commons_numbervars_3_03: success% commons_numbervars_3_04: success ! commons_numbervars_3_05: failure ! test assertion failed: 3==6 ! in file /Users/pmoura/Documents/Logtalk/logtalk3/tests/prolog/predicates/numbervars_3/tests.lgt between lines 51-56% Fatal YAP Error: exiting....

Exiting ....Execution stack: 0 libYap.6.5.dylib 0x000000010b84091e error_exit_yap + 94 1 libYap.6.5.dylib 0x000000010b82c7d2 Yap_Error__ + 834 2 libYap.6.5.dylib 0x000000010ba0bb73 SearchForTrailFault + 195 3 libYap.6.5.dylib 0x000000010ba09d9c HandleSIGSEGV + 188 4 libsystem_platform.dylib 0x00007fff59b8fb5d _sigtramp + 29 5 ??? 0x0000000000000000 0x0 + 0 6 libYap.6.5.dylib 0x000000010b96f549 Yap_NumberVars + 441 7 libYap.6.5.dylib 0x000000010b97387f p_numbervars + 831 8 libYap.6.5.dylib 0x000000010b707e9d Yap_absmi + 132893 9 libYap.6.5.dylib 0x000000010b85253f exec_absmi + 1455 10 libYap.6.5.dylib 0x000000010b852d6e do_goal + 94 11 libYap.6.5.dylib 0x000000010b8540f0 Yap_RunTopGoal + 1184 12 libYap.6.5.dylib 0x000000010b9a7619 YAP_RunGoalOnce + 217 13 yap 0x000000010b6dbe15 do_top_goal + 21 14 yap 0x000000010b6dbdc3 exec_top_level + 147 15 yap 0x000000010b6dbc32 main + 322 16 libdyld.dylib 0x00007fff599a43d5 start + 1 17 ??? 0x0000000000000003 0x0 + 3

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vscosta/yap-6.3/issues/52?email_source=notifications&email_token=ABULRFVSDHYKAZFHRC6NAHDQ4NFO3A5CNFSM4KDF52ZKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4IEICMWQ, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABULRFVCGCDZEN3RRCBTVD3Q4NFO3ANCNFSM4KDF52ZA .

pmoura commented 4 years ago

This numbervars/3 bugs are causing a large number of tests to fail due to its use in the implementation of the lgtunit predicate variant/2.

Earlier today I pushed a fix to the YAP adapter file for Logtalk that changed a predicate used for module qualification of meta-arguments. The previous version of this predicate used term-expansion to find the module where Logtalk was loaded. There seems to be a recent change or bug in the implementation of YAP's term-expansion, however, that broke it. If you update to the latest Logtalk git version, you will find the number of failed tests to be again what you currently expect.

pmoura commented 4 years ago

For reference, the crash reproduces with YAP 6.5.0-3298a680 and Logtalk git version 395c4f6f472fb0ebf7c0cb4cb7bc2635cd552d41.