www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/11/27/13:00:02

From: Glen Miner <gminer AT ca DOT newbridge DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Optimization
Date: Wed, 27 Nov 1996 09:59:15 -0500 (EST)
Organization: Newbridge Networks Corporation
Lines: 32
Message-ID: <Pine.SUN.3.90.961127095705.25056B-100000@coop10>
References: <57hg9b$or5 AT kannews DOT ca DOT newbridge DOT com> <329C4CD4 DOT 7474 AT cornell DOT edu>
NNTP-Posting-Host: 138.120.136.238
Mime-Version: 1.0
In-Reply-To: <329C4CD4.7474@cornell.edu>
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

> > djgpp? I mean, right now I have a 9x9 array of bytes, and try to index 
> > all
> 
> you might be better off just using ints (32 bits) instead of 8, or
> worse, 16 bit quantities. 

What makes you say that? I can't see how this would make it faster... 
more cache misses, and an extra shift to index non-byte sized quantities. 
Not to mention the fact that there are more byte sized registers.

> > Since this code _is_ a port, I have noticed some data conversion too. > An
> > int is no longer 16 bits long. Since I don't really need a 32 bit int > in
> > the core code would it help at all for me to change things to "short
> > unsigned int"s?
> 
> most probably changing things from 32 bit quantities to 16 bit
> quantities will make your program run slower because of the extra
> indexing required.

Extra indexing?! You'll have to justify that statement, cause' I'm not 
buying it.

> did you actually profile your code to see where the bottlenecks are?

Yes. I know exactly where I need to improve.

Peace
===[ Gabo / [ABC] : gaminer AT undergrad DOT math DOT uwaterloo DOT ca ]===================
Latest ABC Shogi: http://www.undergrad.math.uwaterloo.ca/~gaminer/shogi.html
"What Greenpeace spends in a year General Motors spends in four hours" -Moby

- Raw text -


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