delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/10/25/21:37:56

From: alaric AT abwillms DOT demon DOT co DOT uk (Alaric B. Williams)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: allegro and djgpp v2.01
Date: Mon, 21 Oct 1996 18:05:19 GMT
Lines: 50
Message-ID: <845921035.28340.1@abwillms.demon.co.uk>
References: <2830DE6DE8 AT axe3 DOT acadiau DOT ca>
NNTP-Posting-Host: abwillms.demon.co.uk
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

"Rocky Burt" <025668B AT axe DOT acadiau DOT ca> wrote:

>> movw	$0,%eax
>           ^        ^
>> 16bit	   32bit

>I'm sorry, I undstand the size stuff ok, but I really have no idea 
>about assembly.  Is there a quick fix to this like replacing the 
>operand or whatever, or will I have to wait for Shawn Hargreaves to 
>tackle the problem?  Sorry I don't understand more, but I really like 
>the allegro library and I'd really like to compile it, any solutions, 
>other then reinstalling djgpp v2.0 and compiling with that?  Thanks 
>in advance.

Well in the above case, the prefix should be an l, not a w. So if you
go to each such error, and look at the registers involved:

%e?? = 32 bit
%?l or %?h = 8 bit
otherwise %?? = 16 bit

Then change the last letter of the instruction to:

l for 32 bit
w for 16 bit
b for 8 bit

EG, above, we see the %eax, so we know it's 32 bit; we stick an l on
the end, instead of the w, to make

"movl $0,%eax"

(I am assuming, of course, that Shawn meant what he means in the
register names, not the prefixes!)

With any luck, you won't hit any exceptions to this somewhat general
rule :-)


ABW
---

COMPUTER: We are in position over the Rebel homeworld.
VADAR: Engage the Death Star primary weapon, let those rebel worms die!
COMPUTER: Sorry, your evaluation version of Battle Computer 3.0 has expired. 
          Please send 2.6 billion dollars to the address in REGISTER.TXT

Alaric B. Williams Internet : alaric AT abwillms DOT demon DOT co DOT uk
<A HREF="http://www.abwillms.demon.co.uk/">Hello :-)</A>

- Raw text -


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