tarsa@elijah.UUCP (Greg Tarsa) (01/11/90)
Can anyone enlighten me as to what is going wrong here? I am trying to compile X11R4 on a SUN 3/160 under SUNOS 3.2 using GCC 1.35. I have the following error: gcc -DNOSTDHDRS -fstrength-reduce -fpcc-struct-return -c -m68881 \ -I../../../. -I. -I../mfb -I../mi -I../../include \ -I../../.././X11 -DXDMCP -DSUN_WINDOWS -DSHAPE -DMITSHM \ -DMULTIBUFFER -DMITMISC cfbtegblt.c All the pertinent information I could determine follows. Any help would be appreciated. Greg ------ Extra data: mit/server/ddx/cfb/cfbtegblt.c problems: cfbtegblt.c: In function cfbTEGlyphBlt: cfbtegblt.c:177: inconsistent operand constraints in an `asm' cfbtegblt.c:177: inconsistent operand constraints in an `asm' *** Error code 1 The code looks like this: { int tmpDst = tmpDst1 | tmpDst2; unsigned int *pdsttmp = pdst + (x >> PWSH); 177 --> putbits(tmpDst,tmpx,w,pdsttmp,pGC->planemask); } The macro producing the asm looks like this (for gcc): #define FASTPUTBITS(src, x, w, pdst) \ asm ("bfins %3,%0{%1:%2}" \ : "=o" (*(char *)(pdst)) \ : "di" (x), "di" (w), "d" (src), "0" (*(char *) (pdst))) The previous code fragment expands to the following (formatted a bit for aesthetic purposes): { int tmpDst = tmpDst1 | tmpDst2; unsigned int *pdsttmp = pdst + (x >> 2); { if (pGC->planemask != 0xFF) { unsigned long _m, _pm; asm("bfextu %3{%1:%2},%0" : "=d"(_m) : "di"((tmpx) * 8), "di"((w) * 8), "o" (*(char *) (pdsttmp))); { _pm = (pGC->planemask) & 0xFF; _pm |= (_pm << 8); _pm |= (_pm << 2 * 8); }; _m &= (~_pm); _m |= (((tmpDst) >> ((4 - (w)) * 8)) & _pm); asm("bfins %3,%0{%1:%2}" : "=o"(*(char *) (pdsttmp)) : "di"((tmpx) * 8), "di"((w) * 8), "d"(_m), prob oper--> "0"(*(char *) (pdsttmp))); } else { asm("bfins %3,%0{%1:%2}" : "=o"(*(char *) (pdsttmp)) : "di"((tmpx) * 8), "di"((w) * 8), "d"(((tmpDst) >> ((4 - (w)) * 8))), prob oper--> "0"(*(char *) (pdsttmp))); } }; }