This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug inline-asm/11103] [3.3/3.4 regression] asm-specifier conflicts with asm clobber list


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11103


dank@kegel.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dank@kegel.com


------- Additional Comments From dank@kegel.com  2003-06-08 09:39 -------
I get a similar error,
error: asm-specifier for variable `_a1' conflicts with asm clobber list
compiling glibc-2.3.2 with gcc-3.3 for arm-linux.
In the real world, you should be able to reproduce this like so:

wget http://www.kegel.com/crossgcc/crosstool-0.6.tar.gz
tar -xzvf crosstool-0.6.tar.gz
cd crosstool-0.6
eval `cat arm.dat` `cat gcc3.3-glibc2.3.2.dat` sh all.sh

Here's the problem boiled down as small as I can easily get it
(this is the output of 
$ cd build/arm-unknown-linux-gnu/gcc-3.3-glibc-2.3.2/glibc-2.3.2/signal
$ arm-unknown-linux-gnu-gcc -E ../linuxthreads/sysdeps/pthread/sigaction.c
cut down by hand and reformatted with indent):

-- snip --

cat > bug.c <<_EOF_
extern int *__errno_location (void) __attribute__ ((__const__));
struct kernel_sigaction {
    //__sighandler_t k_sa_handler;
    unsigned long sa_flags;
    void (*sa_restorer) (void);
    //sigset_t sa_mask;
};

int __libc_sigaction(sig, act, oact)
int sig;
const struct sigaction *act;
struct sigaction *oact;
{
    int result;
    struct kernel_sigaction kact, koact;

    result = ( {
            unsigned int _sys_result = ( {
                    unsigned int _sys_result; {
                        register int _a1 asm("a1");
                        register int _a4 asm("a4") = (int)(64 / 8);
                        register int _a3 asm("a3") = (int)(oact ? (&koact) :
((void *)0));
                        register int _a2 asm("a2") = (int)(act ? (&kact) :
((void *)0));
                        _a1 = (int) (sig);
              asm volatile ("swi    %1  @ syscall " "rt_sigaction": "=r" (_a1):
"i"(((0x900000 + 174))), "r"(_a1), "r"(_a2), "r"(_a3), "r"(_a4):"a1",
                            "memory");
                        _sys_result = _a1;
                    } (int) _sys_result;
                });
            if (__builtin_expect(((unsigned int) (_sys_result) >= 0xfffff001u),
0)) {
        ((*__errno_location()) = ((-(_sys_result))));
                _sys_result = (unsigned int) -1;} (int) _sys_result;});

    return result;
}
_EOF_
arm-unknown-linux-gnu-gcc bug.c

-- snip --


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]