Article View: comp.arch
Article #1035Re: hardware reassociation (was: reassociation and undefined behaviour)
From: MitchAlsup
Date: Thu, 03 Dec 2026 02:10
Date: Thu, 03 Dec 2026 02:10
34 lines
2239 bytes
2239 bytes
anton@mips.complang.tuwien.ac.at (Anton Ertl) posted: > MitchAlsup <user5857@newsgrouper.org.invalid> writes: > >anton@mips.complang.tuwien.ac.at (Anton Ertl) posted: > >> In any case, the best association depends on the latencies of how the > >> operands are computed. If I don't know that, I would go for > >> (a+b)+(c+d), where the latencies are the same for all operands. > > > >This is an argument that HW (not SW) should be the one to reassociate. > > Yes. But how to do it? Micro-fault > One problem with register machines is that you usually don't know if a > register actually lives after the register has been read. So if the > hardware sees > > t1=a+b > t2=c+d > t3=t1+t2 > > ... it does not know that t1 and t2 are dead and the whole thing can > be reassociated. But if we limit the reassociation to sequences of > > t = a+b > t += c > t += d Do them like this: and if there is no Overflow: its golden. If there is OF then backup and do them the slow way. HW can do this, SW cannot. --------- > > - anton
Technical Details
Message-ID:
<1796263840-5857@newsgrouper.org>Path:
mbox-mo1.pugleaf.net!srl.newsdeef.eu.MISMATCH!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!newsgrouper.org!.POSTED!not-for-mailReferences:
<11cpqih$acf5$1@dont-email.me> <86o6b6kaqf.fsf@linuxsc.com> <11ejr5e$nk8$1@reader2.panix.com> <11ejtoe$eoj7$1@dont-email.me> <11el2c1$q43$1@reader2.panix.com> <11emcgn$1k681$1@dont-email.me> <11emvbp$1sc68$3@dont-email.me> <2026Dec2.084013@mips.complang.tuwien.ac.at> <1796233819-5857@newsgrouper.org> <2026Dec2.190958@mips.complang.tuwien.ac.at>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srl.newsdeef.eu.MISMATCH!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!newsgrouper.org!.POSTED!not-for-mail From: MitchAlsup <user5857@newsgrouper.org.invalid> Newsgroups: comp.arch Subject: Re: hardware reassociation (was: reassociation and undefined behaviour) References: <11cpqih$acf5$1@dont-email.me> <86o6b6kaqf.fsf@linuxsc.com> <11ejr5e$nk8$1@reader2.panix.com> <11ejtoe$eoj7$1@dont-email.me> <11el2c1$q43$1@reader2.panix.com> <11emcgn$1k681$1@dont-email.me> <11emvbp$1sc68$3@dont-email.me> <2026Dec2.084013@mips.complang.tuwien.ac.at> <1796233819-5857@newsgrouper.org> <2026Dec2.190958@mips.complang.tuwien.ac.at> Date: Thu, 03 Dec 2026 02:10:40 GMT Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Message-ID: <1796263840-5857@newsgrouper.org> Injection-Info: newsgrouper.org; mail-complaints-to="newsgrouper@yahoo.com"; posting-account=user5857 Injection-Date: Thu, 03 Dec 2026 02:10:40 GMT User-Agent: Newsgrouper/0.9.0