From: Paul Eggert <eggert@cs.ucla.edu>
To: Eli Zaretskii <eliz@gnu.org>, John Mastro <john.b.mastro@gmail.com>
Cc: 29183@debbugs.gnu.org
Subject: bug#29183: 27.0.50; SIGSEGV on C-g on Windows
Date: Wed, 8 Nov 2017 14:46:53 -0800 [thread overview]
Message-ID: <571b940d-666b-c650-429d-5fc7bfc0d078@cs.ucla.edu> (raw)
In-Reply-To: <83wp30r48u.fsf@gnu.org>
On 11/08/2017 10:53 AM, Eli Zaretskii wrote:
> it sounds like our assumption that this attribute should be a no-op in
> this case is incorrect, or maybe it's a bug in GCC 7.2?
The GCC 7.2 documentation
<https://gcc.gnu.org/onlinedocs/gcc-7.2.0/gcc/Common-Variable-Attributes.html#index-aligned-variable-attribute>
says:
> When used on a struct, or struct member, the |aligned| attribute can
> only increase the alignment; in order to decrease it, the |packed|
> attribute must be specified as well.
so it appears to be a bug.
What is the difference in assembly-language output when you compile with
this:
static struct thread_state GCALIGNED main_thread;
versus this?
static struct thread_state main_thread;
What is the assembly-language output when compiling the following little program, when compiled the same way that you compile thread.c?
struct thread_state { int x; };
static struct thread_state __attribute__ ((aligned (8))) a;
static struct thread_state b;
struct thread_state *c[] = { &a, &b };
On my platform, compiling this with gcc -S yields the following, which looks properly aligned:
.file "t.c"
.local a
.comm a,4,8
.local b
.comm b,4,4
.globl c
.data
.align 16
.type c, @object
.size c, 16
c:
.quad a
.quad b
.ident "GCC: (GNU) 7.2.1 20170915 (Red Hat 7.2.1-2)"
.section .note.GNU-stack,"",@progbits
next prev parent reply other threads:[~2017-11-08 22:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-06 21:58 bug#29183: 27.0.50; SIGSEGV on C-g on Windows John Mastro
2017-11-07 3:36 ` Eli Zaretskii
2017-11-07 18:14 ` John Mastro
2017-11-07 19:41 ` Eli Zaretskii
2017-11-07 21:24 ` John Mastro
2017-11-08 3:43 ` Eli Zaretskii
2017-11-08 18:35 ` John Mastro
2017-11-08 18:53 ` Eli Zaretskii
2017-11-08 22:46 ` Paul Eggert [this message]
2017-11-08 23:41 ` John Mastro
2017-11-09 4:56 ` Paul Eggert
2017-11-09 17:59 ` John Mastro
2017-11-09 14:59 ` Davor Rotim
2017-11-09 17:04 ` Eli Zaretskii
2017-11-09 18:10 ` Davor Rotim
2017-12-01 10:00 ` Noam Postavsky
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=571b940d-666b-c650-429d-5fc7bfc0d078@cs.ucla.edu \
--to=eggert@cs.ucla.edu \
--cc=29183@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=john.b.mastro@gmail.com \
/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.savannah.gnu.org/cgit/emacs.git
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).