From: Mikael Magnusson <mikachu@gmail.com>
To: zsh workers <zsh-workers@zsh.org>
Subject: crash/hang with gcc 5+ -O2 and --enable-zsh-mem
Date: Sat, 24 Feb 2018 20:01:28 +0100 [thread overview]
Message-ID: <CAHYJk3ScwwWYGBHVXDASaWDkxamUFYQjAgEzEWD=NhcbOTVsrA@mail.gmail.com> (raw)
I figured out this was because of -foptimize-strlen which somehow
causes calloc() to recurse infinitely and crash (with -O2 which also
enables -foptimize-sibling-calls it just hangs with no crash because
it doesn't consume extra stack, i presume). What I don't know is how
to fix it, or the causal relationship between strlen optimization and
calloc recursing infinitely. I've tried gcc 5.4, 6.2 and 6.4 with the
same result. Compiling only Src/mem.c with the problematic flag is
enough so it's something in there, but removing the one strlen() call
in the file has no effect.
--
Mikael Magnusson
next reply other threads:[~2018-02-24 19:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-24 19:01 Mikael Magnusson [this message]
2018-02-25 0:13 ` Joey Pabalinas
2018-02-25 7:06 ` Joey Pabalinas
2018-02-25 7:07 ` Joey Pabalinas
2018-02-26 20:24 ` Peter Stephenson
2018-02-27 1:13 ` Joey Pabalinas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAHYJk3ScwwWYGBHVXDASaWDkxamUFYQjAgEzEWD=NhcbOTVsrA@mail.gmail.com' \
--to=mikachu@gmail.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
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 NNTP newsgroup(s).