www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/11/13/12:10:48

Date: Wed, 12 Nov 1997 12:45:20 +0000 ( )
From: "Gurunandan R. Bhat" <grbhat AT unigoa DOT ernet DOT in>
To: Johan Levin <johan AT technologist DOT com>
Cc: djgpp AT delorie DOT com
Subject: Re: GAS segment override
In-Reply-To: <3468BBBC.1220@technologist.com>
Message-Id: <Pine.LNX.3.91.971112124236.8690A-100000@aditya.unigoa.ernet.in>
Mime-Version: 1.0


On Tue, 11 Nov 1997, Johan Levin wrote:

> Hi!
> 
> I'm making a simple ISR that will hook IRQ 0.
> To set the ds to the correct value I read
> ___djgpp_ds_alias. This variable is relative to
> the cs-segment.
> 
> How do I do something like:
> 	mov	ax, cs:[___djgpp_ds_alias]
> I've tried:
> 	cs:
> 	movw	___djgpp_ds_alias, %ax

Sorry I had to abort the earlier mail...
If you include the semicolon at the end, you are declaring  label called 
cs, not really overriding the segment. Your segment continues to be the 
default data segment which is invalid for some other reason....To 
override the segment use cs without the semicolon. 

 

- Raw text -


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