Message-Id: Comments: Authenticated sender is From: "Salvador Eduardo Tropea (SET)" Organization: INTI To: Brad Fidler , djgpp AT delorie DOT com Date: Thu, 17 Apr 1997 15:48:46 +0000 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Subject: Re: Available Selectors Precedence: bulk Brad Fidler wrote: > If I want to load a custom selector (using NASM) > which registers are free for use? No one, all .... > Do interupts or other C functions that I may call > assume certain registers to be loaded with a > specific selector, therefore they are off limits. You must restore have DS, SS and ES before calling any libc function, these functions assumes that this registers have the rigth value. Don't modify ES and then call a function from string.h!!!!, restore the value before calling! Be carefull while using FS and GS some libc functions can clobber the values. So you can use FS and GS but you must reload the values after calling a libc funtion (or any other library) or check the code to be sure that this value will be preserved. SET ------------------------------------ 0 -------------------------------- Visit my home page: http://www.geocities.com/SiliconValley/Vista/6552 Salvador Eduardo Tropea (SET). (Electronics Engineer) Address: Curapaligue 2124, Caseros, 3 de Febrero Buenos Aires, (1678), ARGENTINA TE: +(541) 759 0013