public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug preprocessor/64604] New: [5 Regression] r212194 causes zsh miscompilation
@ 2015-01-14 21:48 trippels at gcc dot gnu.org
  2015-01-15  8:13 ` [Bug preprocessor/64604] " trippels at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: trippels at gcc dot gnu.org @ 2015-01-14 21:48 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64604

            Bug ID: 64604
           Summary: [5 Regression] r212194 causes zsh miscompilation
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: preprocessor
          Assignee: unassigned at gcc dot gnu.org
          Reporter: trippels at gcc dot gnu.org
                CC: dodji at gcc dot gnu.org

Starting with r212194 zsh gets miscompiled on my machine (x86_64).
Symptoms include startup crashes and bizarre tab expansion failures like:

markus@x4 ~ % /va<tab>
_main_complete:trap:131: undefined signal: INT

I haven't looked deeper yet. Will hopefully be able to do so tomorrow.


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

* [Bug preprocessor/64604] [5 Regression] r212194 causes zsh miscompilation
  2015-01-14 21:48 [Bug preprocessor/64604] New: [5 Regression] r212194 causes zsh miscompilation trippels at gcc dot gnu.org
@ 2015-01-15  8:13 ` trippels at gcc dot gnu.org
  2015-01-15  8:15 ` jakub at gcc dot gnu.org
  2015-01-15  8:18 ` trippels at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: trippels at gcc dot gnu.org @ 2015-01-15  8:13 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64604

--- Comment #1 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Turned out that an awk script doesn't handle the new preprocessor comments:

markus@x4 Src % cat sigtmp.c
#include <signal.h>

XXNAMES XXSIGHUP SIGHUP
XXNAMES XXSIGINT SIGINT
XXNAMES XXSIGQUIT SIGQUIT
XXNAMES XXSIGILL SIGILL
XXNAMES XXSIGTRAP SIGTRAP
XXNAMES XXSIGABRT SIGABRT
XXNAMES XXSIGIOT SIGIOT
XXNAMES XXSIGBUS SIGBUS
XXNAMES XXSIGFPE SIGFPE
XXNAMES XXSIGKILL SIGKILL
XXNAMES XXSIGUSR1 SIGUSR1
XXNAMES XXSIGSEGV SIGSEGV
XXNAMES XXSIGUSR2 SIGUSR2
XXNAMES XXSIGPIPE SIGPIPE
XXNAMES XXSIGALRM SIGALRM
XXNAMES XXSIGTERM SIGTERM
XXNAMES XXSIGSTKFLT SIGSTKFLT
XXNAMES XXSIGCLD SIGCLD
XXNAMES XXSIGCHLD SIGCHLD
XXNAMES XXSIGCONT SIGCONT
XXNAMES XXSIGSTOP SIGSTOP
XXNAMES XXSIGTSTP SIGTSTP
XXNAMES XXSIGTTIN SIGTTIN
XXNAMES XXSIGTTOU SIGTTOU
XXNAMES XXSIGURG SIGURG
XXNAMES XXSIGXCPU SIGXCPU
XXNAMES XXSIGXFSZ SIGXFSZ
XXNAMES XXSIGVTALRM SIGVTALRM
XXNAMES XXSIGPROF SIGPROF
XXNAMES XXSIGWINCH SIGWINCH
XXNAMES XXSIGPOLL SIGPOLL
XXNAMES XXSIGIO SIGIO
XXNAMES XXSIGPWR SIGPWR
XXNAMES XXSIGSYS SIGSYS
XXNAMES XXSIGUNUSED SIGUNUSED
XXNAMES XXSIGRTMIN _SIGRTMIN

markus@x4 Src % gcc-4.9 -E sigtmp.c >|sigtmp.out
markus@x4 Src % gcc-5 -E sigtmp.c >|sigtmp_.out
markus@x4 Src % diff -u sigtmp.out sigtmp_.out
--- sigtmp.out  2015-01-15 09:09:41.899667049 +0100
+++ sigtmp_.out 2015-01-15 09:09:45.209590084 +0100
@@ -25,6 +25,8 @@

 # 1 "/usr/include/bits/sigset.h" 1 3 4
 # 22 "/usr/include/bits/sigset.h" 3 4
+
+# 22 "/usr/include/bits/sigset.h" 3 4
 typedef int __sig_atomic_t;


@@ -741,8 +743,8 @@



-# 1 "/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.2/include/stddef.h" 1 3 4
-# 212 "/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.2/include/stddef.h" 3 4
+# 1 "/usr/lib/gcc/x86_64-pc-linux-gnu/5.0.0/include/stddef.h" 1 3 4
+# 216 "/usr/lib/gcc/x86_64-pc-linux-gnu/5.0.0/include/stddef.h" 3 4
 typedef long unsigned int size_t;
 # 343 "/usr/include/signal.h" 2 3 4

@@ -1031,39 +1033,181 @@

 # 2 "sigtmp.c" 2

-XXNAMES XXSIGHUP 1
-XXNAMES XXSIGINT 2
-XXNAMES XXSIGQUIT 3
-XXNAMES XXSIGILL 4
-XXNAMES XXSIGTRAP 5
-XXNAMES XXSIGABRT 6
-XXNAMES XXSIGIOT 6
-XXNAMES XXSIGBUS 7
-XXNAMES XXSIGFPE 8
-XXNAMES XXSIGKILL 9
-XXNAMES XXSIGUSR1 10
-XXNAMES XXSIGSEGV 11
-XXNAMES XXSIGUSR2 12
-XXNAMES XXSIGPIPE 13
-XXNAMES XXSIGALRM 14
-XXNAMES XXSIGTERM 15
-XXNAMES XXSIGSTKFLT 16
-XXNAMES XXSIGCLD 17
-XXNAMES XXSIGCHLD 17
-XXNAMES XXSIGCONT 18
-XXNAMES XXSIGSTOP 19
-XXNAMES XXSIGTSTP 20
-XXNAMES XXSIGTTIN 21
-XXNAMES XXSIGTTOU 22
-XXNAMES XXSIGURG 23
-XXNAMES XXSIGXCPU 24
-XXNAMES XXSIGXFSZ 25
-XXNAMES XXSIGVTALRM 26
-XXNAMES XXSIGPROF 27
-XXNAMES XXSIGWINCH 28
-XXNAMES XXSIGPOLL 29
-XXNAMES XXSIGIO 29
-XXNAMES XXSIGPWR 30
-XXNAMES XXSIGSYS 31
-XXNAMES XXSIGUNUSED 31
+
+# 3 "sigtmp.c"
+XXNAMES XXSIGHUP 
+# 3 "sigtmp.c" 3 4
+                1
+
+# 4 "sigtmp.c"
+XXNAMES XXSIGINT 
+# 4 "sigtmp.c" 3 4
+                2
...

And then the awk scrip generates a bogus signames.c file:

 % gawk -f ./signames2.awk sigtmp.out >| signames.c


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

* [Bug preprocessor/64604] [5 Regression] r212194 causes zsh miscompilation
  2015-01-14 21:48 [Bug preprocessor/64604] New: [5 Regression] r212194 causes zsh miscompilation trippels at gcc dot gnu.org
  2015-01-15  8:13 ` [Bug preprocessor/64604] " trippels at gcc dot gnu.org
@ 2015-01-15  8:15 ` jakub at gcc dot gnu.org
  2015-01-15  8:18 ` trippels at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-01-15  8:15 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64604

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
zsh should learn about the magic -P option ;)


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

* [Bug preprocessor/64604] [5 Regression] r212194 causes zsh miscompilation
  2015-01-14 21:48 [Bug preprocessor/64604] New: [5 Regression] r212194 causes zsh miscompilation trippels at gcc dot gnu.org
  2015-01-15  8:13 ` [Bug preprocessor/64604] " trippels at gcc dot gnu.org
  2015-01-15  8:15 ` jakub at gcc dot gnu.org
@ 2015-01-15  8:18 ` trippels at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: trippels at gcc dot gnu.org @ 2015-01-15  8:18 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64604

Markus Trippelsdorf <trippels at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #3 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #2)
> zsh should learn about the magic -P option ;)

Yeah. I will suggest that to them.


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

end of thread, other threads:[~2015-01-15  8:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-14 21:48 [Bug preprocessor/64604] New: [5 Regression] r212194 causes zsh miscompilation trippels at gcc dot gnu.org
2015-01-15  8:13 ` [Bug preprocessor/64604] " trippels at gcc dot gnu.org
2015-01-15  8:15 ` jakub at gcc dot gnu.org
2015-01-15  8:18 ` trippels at gcc dot gnu.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).