From: Ludvig Larsson Newsgroups: comp.os.msdos.djgpp Subject: Re: Fastest Method of Virtual Buffer->Video Memory? Date: Sat, 24 Oct 1998 04:11:43 +0200 Organization: Faas-Goldhart Lines: 21 Message-ID: <3631375F.2328@club-internet.fr> References: <3631349E DOT B70621ED AT geocities DOT com> NNTP-Posting-Host: toulouse-camichel8-72.club-internet.fr Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: front4.grolier.fr 909196719 5138 195.36.147.72 (24 Oct 1998 02:38:39 GMT) NNTP-Posting-Date: 24 Oct 1998 02:38:39 GMT X-Mailer: Mozilla 3.01C-CLUB (Win95; I) To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Consider using movedata or _movedatal, AFAIK, with optimisations turned on(-O2) they will be translated to a REP STOSL wich moves 4 bytes a time(if you want to move a number of bytes not dividable by 4, use movedata, it will arrange things). Also, copy from aligned a mempos, malloc returns aligned memory(adress dividable by 4 I think), so don't do this: buff=malloc(..... move(buf+1,nr_of_bytes... It will slow things down. Otherwise, the transferspeed is due to memory speed and video-memory speed, as a normal screen-buffer won't enter the cache(and won't be there when you start to transfer probably anyway), the processorspeed is not that important. Hth Ludvig Larsson