cvs.gedasymbols.org/archives/browse.cgi   search  
Mail Archives: djgpp/1997/11/14/14:11:08

Message-Id: <m0xWLTY-000S2CC@inti.gov.ar>
Comments: Authenticated sender is <salvador AT natacha DOT inti DOT gov DOT ar>
From: "Salvador Eduardo Tropea (SET)" <salvador AT inti DOT edu DOT ar>
Organization: INTI
To: broadview AT earthlink DOT net, djgpp AT delorie DOT com
Date: Fri, 14 Nov 1997 16:24:25 +0000
MIME-Version: 1.0
Subject: Re: does anyone have anyideas on how to optimize this code

"STEVEN S. FALLS" <ELN/broadview AT earthlink DOT net> wrote:

> Hi, my name is Ardy and I have a pixelplotting ruteen that needs to be
> optmized. This is what I got, please help!
>             thanks,
>                     -Ardy
> 
> This was writen in NASM:
> 
> BITS 32
> GLOBAL _SetPix__Fiic
> GLOBAL _SetPixRam__Fiic
> GLOBAL _GetPix__Fii
> GLOBAL _GetPixRam__Fii
> GLOBAL _ClearPg__Fv
> GLOBAL _ClearPgRam__Fv
> GLOBAL _CopyPg__Fv
> GLOBAL _Line__Fiiiic
> EXTERN __go32_info_block
> EXTERN _YTbl
> EXTERN _RamPg
> 
> SECTION .text
> _SetPix__Fiic:
>         push ebp
>         mov edx,[_YTbl]
>         mov ebx,[esp+12]
>         mov ebx,[edx+ebx*4]
>         add ebx,[esp+8]
>         mov al,[esp+16]
>         mov fs,[__go32_info_block+26]
>         add ebx,0A0000h
>         mov [fs:ebx],al
>         pop ebp
>         ret
> _SetPixRam__Fiic:

Why are you using Assembler for it?  I think you'll get this code or better 
using C (try O3 and omit-frame-pointer for the routine). Even more, for loops 
you can use an inline version, it will be much more faster.

SET
------------------------------------ 0 --------------------------------
Visit my home page: http://www.geocities.com/SiliconValley/Vista/6552/
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Alternative e-mail: set-sot AT usa DOT net - ICQ: 2951574
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013

- Raw text -


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