From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ken Brown Newsgroups: gmane.emacs.bugs Subject: bug#18438: 24.4.50; assertion failed in bidi.c Date: Fri, 10 Oct 2014 09:54:18 -0400 Message-ID: <5437E50A.20108@cornell.edu> References: <4745242cd3e424a6c4d5db0e8d3e33d0@amuri.net> <83h9zrlzc8.fsf@gnu.org> <54297FDB.6090606@cornell.edu> <837g0mmkf3.fsf@gnu.org> <6b19fab333f3d362ae61b30b299d7206@amuri.net> <83iok5ku74.fsf@gnu.org> <88ccbe34bf58322ae4b2a5657390c041@amuri.net> <83ppe1itu9.fsf@gnu.org> <837g08bdcy.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1412949337 20993 80.91.229.3 (10 Oct 2014 13:55:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 10 Oct 2014 13:55:37 +0000 (UTC) Cc: 18438@debbugs.gnu.org To: Eli Zaretskii , aidalgol@amuri.net Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 10 15:55:29 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XcafD-00022u-DT for geb-bug-gnu-emacs@m.gmane.org; Fri, 10 Oct 2014 15:55:23 +0200 Original-Received: from localhost ([::1]:48348 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XcafD-0003Cd-3z for geb-bug-gnu-emacs@m.gmane.org; Fri, 10 Oct 2014 09:55:23 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57829) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xcaf1-00035o-57 for bug-gnu-emacs@gnu.org; Fri, 10 Oct 2014 09:55:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xcaet-0004ou-Hq for bug-gnu-emacs@gnu.org; Fri, 10 Oct 2014 09:55:11 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:48239) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xcaet-0004o1-BP for bug-gnu-emacs@gnu.org; Fri, 10 Oct 2014 09:55:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Xcaes-00021I-M8 for bug-gnu-emacs@gnu.org; Fri, 10 Oct 2014 09:55:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ken Brown Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 10 Oct 2014 13:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18438 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 18438-submit@debbugs.gnu.org id=B18438.14129492787709 (code B ref 18438); Fri, 10 Oct 2014 13:55:02 +0000 Original-Received: (at 18438) by debbugs.gnu.org; 10 Oct 2014 13:54:38 +0000 Original-Received: from localhost ([127.0.0.1]:39800 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XcaeT-00020H-Go for submit@debbugs.gnu.org; Fri, 10 Oct 2014 09:54:37 -0400 Original-Received: from limerock02.mail.cornell.edu ([128.84.13.242]:54328) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XcaeQ-000205-I9 for 18438@debbugs.gnu.org; Fri, 10 Oct 2014 09:54:35 -0400 X-CornellRouted: This message has been Routed already. Original-Received: from authusersmtp.mail.cornell.edu (granite4.serverfarm.cornell.edu [10.16.197.9]) by limerock02.mail.cornell.edu (8.14.4/8.14.4_cu) with ESMTP id s9ADsLNN007381; Fri, 10 Oct 2014 09:54:21 -0400 Original-Received: from [192.168.1.4] (cpe-67-249-176-226.twcny.res.rr.com [67.249.176.226]) (authenticated bits=0) by authusersmtp.mail.cornell.edu (8.14.4/8.12.10) with ESMTP id s9ADsJbH000352 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Fri, 10 Oct 2014 09:54:20 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.1.2 In-Reply-To: <837g08bdcy.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:94384 On 10/10/2014 3:19 AM, Eli Zaretskii wrote: > === modified file 'src/bidi.c' > --- src/bidi.c 2014-04-06 15:56:01 +0000 > +++ src/bidi.c 2014-10-10 07:12:01 +0000 > @@ -326,7 +326,14 @@ bidi_get_type (int ch, bidi_dir_t overri > static void > bidi_check_type (bidi_type_t type) > { > - eassert (UNKNOWN_BT <= type && type <= NEUTRAL_ON); > + volatile ptrdiff_t qtype = type; > + > + if (!(suppress_checking || (UNKNOWN_BT <= qtype && qtype <= NEUTRAL_ON))) > + { > + fprintf (stderr, "\r\n%s:%d: bidi type %d is not in [%d..%d]\r\n", > + __FILE__, __LINE__, type, UNKNOWN_BT, NEUTRAL_ON); > + emacs_abort (); > + } > } > > /* Given a bidi TYPE of a character, return its category. */ It works: Dump of assembler code for function bidi_check_type: 0x00000001004fc423 <+0>: push %rbp 0x00000001004fc424 <+1>: mov %rsp,%rbp 0x00000001004fc427 <+4>: sub $0x50,%rsp 0x00000001004fc42b <+8>: mov %ecx,0x10(%rbp) 0x00000001004fc42e <+11>: mov 0x10(%rbp),%eax 0x00000001004fc431 <+14>: mov %rax,-0x8(%rbp) 0x00000001004fc435 <+18>: mov 0x56bfb4(%rip),%rax # 0x100a683f0 <.refptr.suppress_checking> 0x00000001004fc43c <+25>: movzbl (%rax),%eax 0x00000001004fc43f <+28>: xor $0x1,%eax 0x00000001004fc442 <+31>: test %al,%al 0x00000001004fc444 <+33>: je 0x1004fc49b 0x00000001004fc446 <+35>: mov -0x8(%rbp),%rax 0x00000001004fc44a <+39>: test %rax,%rax <<<<<<<<<<<<<<<<<<<<<<<<<<<<< 0x00000001004fc44d <+42>: js 0x1004fc459 0x00000001004fc44f <+44>: mov -0x8(%rbp),%rax 0x00000001004fc453 <+48>: cmp $0x17,%rax <<<<<<<<<<<<<<<<<<<<<<<<<<<<< 0x00000001004fc457 <+52>: jle 0x1004fc49b 0x00000001004fc459 <+54>: callq 0x1006c6a50 <__getreent> 0x00000001004fc45e <+59>: mov 0x18(%rax),%rax 0x00000001004fc462 <+63>: movl $0x17,0x30(%rsp) 0x00000001004fc46a <+71>: movl $0x0,0x28(%rsp) 0x00000001004fc472 <+79>: mov 0x10(%rbp),%edx 0x00000001004fc475 <+82>: mov %edx,0x20(%rsp) 0x00000001004fc479 <+86>: mov $0x14d,%r9d 0x00000001004fc47f <+92>: lea 0x53b16a(%rip),%r8 # 0x100a375f0 0x00000001004fc486 <+99>: lea 0x53b16b(%rip),%rdx # 0x100a375f8 0x00000001004fc48d <+106>: mov %rax,%rcx 0x00000001004fc490 <+109>: callq 0x1006c6d70 0x00000001004fc495 <+114>: callq 0x100672ebc 0x00000001004fc49a <+119>: nop 0x00000001004fc49b <+120>: add $0x50,%rsp 0x00000001004fc49f <+124>: pop %rbp 0x00000001004fc4a0 <+125>: retq End of assembler dump. Do you have a new theory that this is testing? Ken