🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.programming.contests
Article #5

Re: Random Numbers

#5
From: Olly Betts
Date: Thu, 02 Nov 1995 14:34
11 lines
921 bytes
In article <DHD1w9.JC4@rivm.nl>, A. van Kessel <imaavk> wrote:
>int iter_cmp(ITER *l, ITER *r)
>{ if (l->val == r->val) return 0;
>else return l->val - r->val; /* or the other way around */
>}

Spot the optimisation.  GCC 2.6.3 on a SPARC doesn't.

Olly
-- 
cool wet grass  cool wet grass  cool wet grass  cool wet grass  cool wet grass
Technical Details
Message-ID: <19951102142859.olly@mantis.co.uk>
Path: arc1-ca.pugleaf.net!dish.news.pipex.net!pipex!mantis!mantis!not-for-mail
References: <46qte7$hbv@btmpjg.god.bel.alcatel.be> <4745p3$62h@umbc9.umbc.edu> <chrisw.282.0017FC83@leland.stanford.edu> <DHD1w9.JC4@rivm.nl>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!dish.news.pipex.net!pipex!mantis!mantis!not-for-mail
From: olly@mantis.co.uk (Olly Betts)
Newsgroups: comp.programming.contests,comp.lang.c
Subject: Re: Random Numbers
Date: 2 Nov 1995 14:34:50 -0000
Organization: techn-ol-ogy
Message-ID: <19951102142859.olly@mantis.co.uk>
References: <46qte7$hbv@btmpjg.god.bel.alcatel.be> <4745p3$62h@umbc9.umbc.edu> <chrisw.282.0017FC83@leland.stanford.edu> <DHD1w9.JC4@rivm.nl>
NNTP-Posting-Host: sunforest.mantis.co.uk
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit