From: cbramix AT libero DOT it (Carlo) Newsgroups: comp.os.msdos.djgpp Subject: Optimizing 8 bit variables? Date: 26 Aug 2003 05:27:43 -0700 Organization: http://groups.google.com/ Lines: 19 Message-ID: NNTP-Posting-Host: 151.25.158.86 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1061900865 22396 127.0.0.1 (26 Aug 2003 12:27:45 GMT) X-Complaints-To: groups-abuse AT google DOT com NNTP-Posting-Date: 26 Aug 2003 12:27:45 GMT To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Hello everyone! I have this little problem: GCC doesn't seem to optimize very well a piece of code I wrote with 8 bit variables. So, I was thinking to use a local register variable. On the documentation I read that GCC can do that: register int *foo asm ("ebx"); But what should I do if I need to use BH or BL registers? I tried to use BH or BL instead of ebx: register unsigned char myvar asm ("bl"); GCC doesn't give me error messages, but it generates the same code I got without the 'asm' keyword. Thanks in advance. Carlo.