Date: Mon, 26 May 1997 18:25:20 +0300 (IDT) From: Eli Zaretskii To: Mark Slagell cc: djgpp AT delorie DOT com Subject: Re: setting segment register for string instructions In-Reply-To: <33895D98.1322@geocities.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Mon, 26 May 1997, Mark Slagell wrote: > Using string instructions, I'm getting me some intermittent crashes. > I'm guessing my problem is that I need to set %ds explicitly, but to > what? The memory being addressed is an ordinary C array, so I'm not > trying to access conventional DOS memory or anything like that. AFAIK, in a DJGPP program DS is already set to the data segment, so you shouldn't need to change it. Unless, of course, you are in an interrupt handler. Are you? > I've noticed the compiler never seems to generate string instructions. AFAIK, it should generate string instructions if you e.g. use `memcpy' library function and compile with -O3. But I didn't test this lately.