public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "clyon at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/107032] ARM: libgcc2.c:2174:1: error: r7 cannot be used in 'asm' here
Date: Mon, 26 Sep 2022 08:01:06 +0000	[thread overview]
Message-ID: <bug-107032-4-nFLXe1jujD@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-107032-4@http.gcc.gnu.org/bugzilla/>

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

Christophe Lyon <clyon at gcc dot gnu.org> changed:

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

--- Comment #1 from Christophe Lyon <clyon at gcc dot gnu.org> ---
At quick glance, I think this is caused by the definition of CLEAR_INSN_CACHE
in gcc/config/arm/uclinux-eabi.h:

/* Clear the instruction cache from `beg' to `end'.  This makes an
   inline system call to SYS_cacheflush.  */
#undef CLEAR_INSN_CACHE
#define CLEAR_INSN_CACHE(BEG, END)                                      \
{                                                                       \
  register unsigned long _beg __asm ("a1") = (unsigned long) (BEG);     \
  register unsigned long _end __asm ("a2") = (unsigned long) (END);     \
  register unsigned long _flg __asm ("a3") = 0;                         \
  register unsigned long _scno __asm ("r7") = 0xf0002;                  \
  __asm __volatile ("swi 0x0            @ sys_cacheflush"               \
                    : "=r" (_beg)                                       \
                    : "0" (_beg), "r" (_end), "r" (_flg), "r" (_scno)); \
}

which makes explicit use of r7.

This code has been like that since it was committed in 2007....
So I suspect nobody ever tried to build this configuration.

  reply	other threads:[~2022-09-26  8:01 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-25  9:50 [Bug target/107032] New: " thomas.petazzoni@free-electrons.com
2022-09-26  8:01 ` clyon at gcc dot gnu.org [this message]
2022-09-26  8:08 ` [Bug target/107032] " thomas.petazzoni@free-electrons.com
2022-09-26  8:13 ` clyon at gcc dot gnu.org
2022-09-26  8:42 ` thomas.petazzoni@free-electrons.com
2022-09-26 12:51 ` clyon at gcc dot gnu.org
2022-09-27 10:55 ` rearnsha at gcc dot gnu.org
2022-09-27 11:32 ` clyon at gcc dot gnu.org
2022-09-27 12:02 ` rearnsha at gcc dot gnu.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-107032-4-nFLXe1jujD@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).