delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/06/18/06:14:22

Message-ID: <394CA0CC.BB64787@x-treme.gr>
Date: Sun, 18 Jun 2000 13:13:32 +0300
From: only4usa <only4usa AT x-treme DOT gr>
X-Mailer: Mozilla 4.61 [en] (Win95; I)
X-Accept-Language: el,en
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: Help compiling the GRX20 lib
Reply-To: djgpp AT delorie DOT com

I am trying to compile the GRX20lib and i have always the same problem
and the compilation stops always at this point:
>gcc -c -O6 -Wall -m486 -fomit-frame-pointer -I. -I./include -I../include -I../addons/print -I../addons/bmp utils/shiftscl.c -o >utils/shiftscl.o
>utils/shiftscl.c: In function '_GR_shift_scanline':
>utils/shiftscl.c:49: Invalid 'asm' statement:
>utils/shiftscl.c:49: fixed or forbidden register 2 (cx) was spilled for class CREG.
>utils/shiftscl.c:103: Invalid 'asm' statement:
>utils/shiftscl.c:103: fixed or forbidden register 2 (cx) was spilled for class CREG.
>make.exe[1]: *** [utils/shiftscl.o] Error 1
>make.exe[1]: Leaving directory 'f:/djgpp/src'
>make.exe: *** [libs] Error 2

And the code of the shiftscl.c is this one :
*************
#     if defined(__GNUC__) && defined(__i386__)
	int w = ws;
	/* sad but true: the x86 bytesex forces this inefficient code :( */
	asm volatile ("\n"
	  "   movb    (%3),%%ch    \n"
	  "   jmp     1f           \n"
	  "   .align  4,0x90       \n"
	  "1: decl    %3           \n"
	  "   movb    %%ch,%%al    \n"
	  "   movb    (%3),%%ah    \n"
	  "   movb    %%ah,%%ch    \n"
	  "   shrl    %%cl,%%eax   \n"
	  "   movb    %%al,(%4)    \n"
	  "   decl    %4           \n"
	  "   decl    %5           \n"
	  "   jne     1b           \n"
	  "   shrb    %%cl,%%ch    \n"
	  "   movb    %%ch,(%4)      "
	  : "=r" ((void *)s), "=r" ((void *)d), "=r" ((int)w)
	  : "0" ((void *)s), "1" ((void *)d), "2" ((int)w), "c" ((int)shift)
	  : "ax", "cx"
	);
*********
I am compiling with djgpp v2.
any help is appreciated.
Regards
Yorgos Ioannou

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019