Date: Thu, 18 Dec 1997 17:19:57 -0800 (PST) Message-Id: <199712190119.RAA12129@adit.ap.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" To: Greg Moorer From: Nate Eldredge Subject: Re: movedata.h problems Cc: djgpp AT delorie DOT com, djgpp-workers AT delorie DOT com Precedence: bulk At 08:59 12/18/1997 -0600, Greg Moorer wrote: > >> + __DJ_size_t >> + #undef __DJ_size_t >> + #define __DJ_size_t > >I never woulda figured that out by myself. It was fairly simple, after looking at it some. I looked at preprocessor output to find that `size_t' didn't get defined, saw how that was done in djtypes.h, and looked at how string.h used the macro. >Do you know which way is the >proper way to call the _dosmemputl function? Should the parameters be >(*buffer, num_32bit_words_to_move, *dest_addr) like it is in the >prototype, or (*buffer, *dest_addr, num_...) like it is in all the >provided examples. The prototype is correct. (buffer, transfers, dest_addr) But as somebody pointed out, using `dosmemput' and nearptr is counterproductive. If you use nearptrs, then `memcpy' will work. >-Greg > >P.S. This would be a fast way to transfer a double buffer, would it not? Yup. >Is there an extended ASM macro to move 32 bits at a time? That's what `dosmemputl' does inside. The `rep movsl' instruction will move %ecx 32-bit longwords from %ds:%esi to %es:%edi. Nate Eldredge eldredge AT ap DOT net