Path: utzoo!attcan!uunet!mcsun!cernvax!rbt From: rbt@cernvax.UUCP (roberto divia) Newsgroups: comp.os.os9 Subject: Re: Passing parameters by registers is bad use?!?!? Keywords: C compiler, parameter passing Message-ID: <2823@cernvax.UUCP> Date: 30 Sep 90 13:57:43 GMT References: <2820@cernvax.UUCP> <3117@mcrware.UUCP> <3552@rwthinf.UUCP> Organization: CERN, European Laboratory for Particle Physics Lines: 16 In article <3552@rwthinf.UUCP> krischan@truth.UUCP (Christian Engel) writes: >In article <2820@cernvax.UUCP> rbt@cernvax.UUCP (roberto divia) writes: >>2) bigger is the data area used by the code is and easier is to have a >> cache miss (this in case of processors with data caches). >Now, that's too high for me. Why should the chance of cache miss increase >in passing parameters via stack? Simply because they will HAVE to be store in the data cache (this is done during the PUSH), removing other lines from the cache itself, lines that will have to be reloaded in case of new references. The data cache works normally as function of the "region" of the data used by the program. Stack references will exit from this region, increasing the number of cache misses...-- | Roberto Divia` | Love at first sight is one of the greatest | | ============= | labor-saving devices the world has ever seen | | CERN : European Laboratory for Particle Physics, 1211 Geneva 23 | | Switzerland (CH) |