public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "ibuclaw at gdcproject dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/94541] [8/9/10 Regression] -mx32 gcc produces wrong code passing structs by value
Date: Thu, 09 Apr 2020 16:57:41 +0000	[thread overview]
Message-ID: <bug-94541-4-VrHjlYfS3m@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-94541-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #4 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to Jakub Jelinek from comment #2)
> I don't have a -mx32 capable environment, so can't verify, but mmap/munmap
> shouldn't be inlined in any way, so can you reproduce if you replace
> mmap with foo and munmap with bar and define them like:
> static char c;
> __attribute__((noipa)) void *
> foo (void *addr, size_t length, int prot, int flags, int fd, off_t offset)
> {
>   return (void *) &c;
> }
> __attribute__((noipa)) int
> bar (void *addr, size_t length)
> {
>   if (addr != (void *) &c)
>     return -1;
>   return 0;
> }
> or so?  If yes, can you also drop errno from the testcase, and possibly drop
> unnecessary arguments to foo and/or bar as long as it reproduces?  Once
> minimized that way, please preprocess it.

Can't reduce it down so there is no munmap().  I suspect this is because going
across the syscall layer means there's some naked asm involved to call the real
munmap().

  parent reply	other threads:[~2020-04-09 16:57 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-09 13:48 [Bug target/94541] New: " ibuclaw at gdcproject dot org
2020-04-09 13:55 ` [Bug target/94541] " ibuclaw at gdcproject dot org
2020-04-09 14:40 ` jakub at gcc dot gnu.org
2020-04-09 15:29 ` [Bug target/94541] [8/9/10 Regression] " hjl.tools at gmail dot com
2020-04-09 16:57 ` ibuclaw at gdcproject dot org [this message]
2020-04-09 16:59 ` ibuclaw at gdcproject dot org
2020-04-09 20:31 ` hjl.tools at gmail dot com
2020-04-09 20:32 ` hjl.tools at gmail dot com
2020-04-09 20:42 ` [Bug middle-end/94541] " hjl.tools at gmail dot com
2020-04-09 20:53 ` pinskia at gcc dot gnu.org
2020-04-09 21:04 ` hjl.tools at gmail dot com
2020-04-09 21:07 ` hjl.tools at gmail dot com
2020-04-09 21:32 ` pinskia at gcc dot gnu.org
2020-04-09 22:28 ` hjl.tools at gmail dot com
2020-04-09 22:32 ` [Bug target/94541] " pinskia at gcc dot gnu.org
2020-04-09 23:24 ` hjl.tools at gmail dot com
2020-04-09 23:28 ` hjl.tools at gmail dot com
2020-04-10 10:57 ` hjl.tools at gmail dot com
2020-04-10 11:20 ` ibuclaw at gdcproject dot org

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=bug-94541-4-VrHjlYfS3m@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.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.
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).