public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/11386] New: GNU Emacs 21.3 failed to install using GCC 3.3, but GCC 3.2.3 works.
@ 2003-06-30 22:12 ishikawa at yk dot rim dot or dot jp
  2003-07-01  9:46 ` [Bug c/11386] " ebotcazou at gcc dot gnu dot org
                   ` (27 more replies)
  0 siblings, 28 replies; 30+ messages in thread
From: ishikawa at yk dot rim dot or dot jp @ 2003-06-30 22:12 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11386

           Summary: GNU Emacs 21.3 failed to install using GCC 3.3, but GCC
                    3.2.3 works.
           Product: gcc
           Version: 3.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: ishikawa at yk dot rim dot or dot jp
                CC: gcc-bugs at gcc dot gnu dot org
  GCC host triplet: sparc-sun-solaris28

(I am opening a new bug: I have posted a comment to bug 9816 before.)

Under UltraSparc Solaris 8,

 - gcc 3.2.3 could compile emacs 21.3 and the resulting binary could
   compile emacs lisp libraries and installs fine.

 - gcc 3.3 could compile emacs 21.3, but the resulting binary
   failed to compile emacs lisp libraries. During the compilation of
   one of the lisp files, the resulting binary seg-faulted!
   This is very similar to what is observed in the now invalid bug report
   of  bug 9816 .


So I had to downgrade to GCC 3.2.3.

Since the compiler binary is fetched from
   http://www.sunfreeware.com
I don't have exact details regarding the compile options.
(However, it seems to be a straight forward 
  configure
  make bootstrap 
   ...
)


Here is the detaild run log under gdb of the
resulting binary.

---
This is still insufficient information, but I am posting
the gdb log to solicit more input from Emacs user community who
may have experienced similar problems using the latest GCC 3.3 under
sparc solaris and other platforms.

Basically, after a binary compile of the emacs program,
the emacs installer tries to compile
so called emacs lisp programs into its own internal byte code.
During the byte compiling, emacs aborts.

The final gdb output is as follows:  (details below.)

|Program received signal SIGSEGV, Segmentation fault.
|0x41e90 in __do_global_dtors_aux ()
|(gdb) #0  0x41e90 in __do_global_dtors_aux ()
|#1  0x18931c in _fini ()
|#2  0xfee9bca4 in _exithandle () from /usr/lib/libc.so.1
|#3  0xfef1f87c in exit () from /usr/lib/libc.so.1
|#4  0xd2b20 in Fkill_emacs (arg=0) at emacs.c:1830
|#5  0x137d20 in Ffuncall (nargs=1, args=0xffbee31c) at eval.c:2659

This suggests that a part of emacs gets miscompiled by
by GCC 3.3 under ultra sparc solaris 8.
Emacs seems to have detected something funny and tries to quit calling
Fkill_emacs function, but
by that time, something (memory[code/stack] area?)
 was either broken from the beginning
or corrupted during the run, and during the exit processing
the program seems to have encountered a fatal segmentation error.

Using GCC 3.2.3 under the same OS, the byte compilation
succeeds and the installation succeeds.
The resulting Emacs is usable as far as I can tell.

Atttached is the problematic run, under gdb, of the Emacs binary that
gets compiled using gcc 3.3.

I run a particular byte compilation that triggered the abort by using
a shell script break.sh.  It runs the EMACS binary under gdb.

$ cat break.sh
LC_ALL=C
LANG=C

gcc -v
   
cd leim
 
EMACSLOADPATH=/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp 
export EMACSLOADPATH
# ../src/emacs -batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv \
  --eval '(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC; 

***** The above backslash was followed by CR (invisible) and
***** this caused the --eval not found error below, but
***** this has nothing to do with the compilation problem.

gdb ../src/emacs <<!EOF
run -batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv --eval
'(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC
where


quit
EOF

$ sh -vx break.sh
LC_ALL=C
LC_ALL=C
LANG=C
LANG=C

gcc -v
+ gcc -v 
Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/3.3/specs
Configured with: ../configure --disable-nls --with-as=/usr/ccs/bin/as
--with-ld=/usr/ccs/bin/ld
Thread model: posix
gcc version 3.3
   
cd leim
+ cd leim 
 
EMACSLOADPATH=/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp 
EMACSLOADPATH=/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp
export EMACSLOADPATH
+ export EMACSLOADPATH 
# ../src/emacs -batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv \
  --eval '(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC; 
+ --eval (batch-titdic-convert t) -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC 
break.sh: --eval: not found

**** The comment line that ends with "\" was actually
**** followed by CR (invisible) as I mentioned above and
**** so shell complained that --eval is an unknown command.
**** Now we invoke gdb.


gdb ../src/emacs <<!EOF
run -batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv --eval
'(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC
where


quit
EOF

+ gdb ../src/emacs 
run -batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv --eval
'(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC
where


quit
EOF

GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc-sun-solaris2.8"...
(gdb) Starting program: /home/ishikawa/PACKAGES/emacs-21.3/leim/../src/emacs
-batch --no-init-file --no-site-file --multibyte -l
/home/ishikawa/PACKAGES/emacs-21.3/leim/../lisp/international/titdic-cnv --eval
'(batch-titdic-convert t)' -dir quail
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC
Converting all tit files in the directory
/home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/4Corner.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/ARRAY30.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/CCDOSPY.tit to
quail-package...
Decoding with coding system euc-china...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/ECDICT.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/ETZY.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/PY-b5.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/Punct-b5.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/Punct.tit to
quail-package...
Decoding with coding system euc-china...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/QJ-b5.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/QJ.tit to
quail-package...
Decoding with coding system euc-china...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/SW.tit to
quail-package...
Decoding with coding system euc-china...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/TONEPY.tit to
quail-package...
Decoding with coding system euc-china...
Processing header part...
Formatting translation rules...
Converting /home/ishikawa/PACKAGES/emacs-21.3/leim/CXTERM-DIC/ZOZY.tit to
quail-package...
Decoding with coding system cn-big5...
Processing header part...
Formatting translation rules...
Byte-compile the created files by:
  % emacs -batch -f batch-byte-compile XXX.el

Program received signal SIGSEGV, Segmentation fault.
0x41e90 in __do_global_dtors_aux ()
(gdb) #0  0x41e90 in __do_global_dtors_aux ()
#1  0x18931c in _fini ()
#2  0xfee9bca4 in _exithandle () from /usr/lib/libc.so.1
#3  0xfef1f87c in exit () from /usr/lib/libc.so.1
#4  0xd2b20 in Fkill_emacs (arg=0) at emacs.c:1830
#5  0x137d20 in Ffuncall (nargs=1, args=0xffbee31c) at eval.c:2659
#6  0x166714 in Fbyte_code (bytestr=-4267240, vector=4899592, maxdepth=6)
    at bytecode.c:716
#7  0x138170 in funcall_lambda (fun=1078908320, nargs=1, arg_vector=0xffbee438)
---Type <return> to continue, or q <return> to quit---    at eval.c:2851
#8  0x138020 in apply_lambda (fun=1078908320, args=1, eval_flag=1)
    at eval.c:2770
#9  0x136c58 in Feval (form=1346736020) at eval.c:2071
#10 0x137d20 in Ffuncall (nargs=1, args=0xffbee66c) at eval.c:2659
#11 0x166714 in Fbyte_code (bytestr=-4266392, vector=2613852, maxdepth=11)
    at bytecode.c:716
#12 0x138170 in funcall_lambda (fun=1076354016, nargs=1, arg_vector=0xffbee834)
    at eval.c:2851
#13 0x137c0c in Ffuncall (nargs=1, args=0xffbee830) at eval.c:2716
#14 0x166714 in Fbyte_code (bytestr=-4265936, vector=2604088, maxdepth=5)
    at bytecode.c:716
#15 0x138170 in funcall_lambda (fun=1076344624, nargs=0, arg_vector=0xffbee9e4)
    at eval.c:2851
#16 0x137c0c in Ffuncall (nargs=0, args=0xffbee9e0) at eval.c:2716
#17 0x166714 in Fbyte_code (bytestr=-4265504, vector=2599040, maxdepth=5)
    at bytecode.c:716
#18 0x138170 in funcall_lambda (fun=1076340688, nargs=0, arg_vector=0xffbeeb00)
    at eval.c:2851
#19 0x138020 in apply_lambda (fun=1076340688, args=0, eval_flag=1)
    at eval.c:2770
#20 0x136c58 in Feval (form=1345428916) at eval.c:2071
#21 0x135a3c in internal_condition_case (bfun=0xd3da0 <top_level_2>, 
---Type <return> to continue, or q <return> to quit---    handlers=271329500,
hfun=0xd3a5c <cmd_error>) at eval.c:1267
#22 0xd3df0 in top_level_1 () at keyboard.c:1262
#23 0x135598 in internal_catch (tag=271281828, func=0xd3db8 <top_level_1>, 
    arg=271207428) at eval.c:1030
#24 0xd3d04 in command_loop () at keyboard.c:1223
#25 0xd37a8 in recursive_edit_1 () at keyboard.c:950
#26 0xd390c in Frecursive_edit () at keyboard.c:1006
#27 0xd2690 in main (argc=0, argv=0xffbef104, envp=0xffbef138) at emacs.c:1547
(gdb) (gdb) (gdb) $ 
$ exit


^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2003-07-15  1:31 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-30 22:12 [Bug c/11386] New: GNU Emacs 21.3 failed to install using GCC 3.3, but GCC 3.2.3 works ishikawa at yk dot rim dot or dot jp
2003-07-01  9:46 ` [Bug c/11386] " ebotcazou at gcc dot gnu dot org
2003-07-01  9:54 ` [Bug optimization/11386] " ebotcazou at gcc dot gnu dot org
2003-07-02  9:43 ` ishikawa at yk dot rim dot or dot jp
2003-07-03 16:57 ` simon dot marshall at misys dot com
2003-07-03 18:18 ` ishikawa at yk dot rim dot or dot jp
2003-07-03 19:20 ` ebotcazou at libertysurf dot fr
2003-07-04 17:11 ` ebotcazou at gcc dot gnu dot org
2003-07-04 20:59 ` ishikawa at yk dot rim dot or dot jp
2003-07-05 14:34   ` Christian Ehrhardt
2003-07-04 21:37 ` ebotcazou at libertysurf dot fr
2003-07-05 14:35 ` ehrhardt at mathematik dot uni-ulm dot de
2003-07-07  1:47 ` ishikawa at yk dot rim dot or dot jp
2003-07-07  9:30 ` simon dot marshall at misys dot com
2003-07-07 10:23 ` ebotcazou at gcc dot gnu dot org
2003-07-07 23:25 ` ishikawa at yk dot rim dot or dot jp
2003-07-08  6:43 ` ebotcazou at libertysurf dot fr
2003-07-08 13:00 ` simon dot marshall at misys dot com
2003-07-09  0:12 ` neroden at gcc dot gnu dot org
2003-07-09  2:19 ` neroden at gcc dot gnu dot org
2003-07-09  8:17 ` simon dot marshall at misys dot com
2003-07-11  9:46 ` ishikawa at yk dot rim dot or dot jp
2003-07-11 10:09 ` simon dot marshall at misys dot com
2003-07-11 10:38 ` ebotcazou at gcc dot gnu dot org
2003-07-11 12:09 ` ebotcazou at gcc dot gnu dot org
2003-07-11 12:10 ` ebotcazou at gcc dot gnu dot org
2003-07-11 17:48 ` ebotcazou at gcc dot gnu dot org
2003-07-14 19:45 ` ebotcazou at gcc dot gnu dot org
2003-07-14 23:32 ` ishikawa at yk dot rim dot or dot jp
2003-07-15  1:31 ` bangerth at dealii dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).