Subject: advice on some inline assembler code
To: None <port-pc532@netbsd.org>
From: Jon Buller <jonb@metronet.com>
List: port-pc532
Date: 09/26/1998 20:00:29
I have the following code that seems to work with PostgreSQL 6.4

    static __inline__ int
    tas(volatile slock_t *lock)
    {
      register _res;
      __asm__("sbitb 0, %0
            sprb us, %1
            andd 32, %1"
            : "=m"(*lock)
            : "r"(_res));
      return (int) _res;
    }

(checked out of their CVS tree a few days ago)  The only problem
with it is that I detest the warning gcc spits out about _res
probably being uninitialized.  Is egcs smart enough not to do
that, or is there some statement or comment that I can add to
make gcc shut up?

Jon Buller