Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!batcomputer!cornell!uw-beaver!zephyr.ens.tek.com!tektronix!reed!intelhf!ichips!ichips!glew From: glew@pdx007.intel.com (Andy Glew) Newsgroups: comp.arch Subject: Re: Bitfield and loop instructions--a good idea? Message-ID: Date: 18 Apr 91 21:33:37 GMT References: <1991Apr15.193425.3436@waikato.ac.nz> <2302@spim.mips.COM> <6444@acorn.co.uk> Sender: news@omews63.intel.com (News Account) Organization: Intel Corp., Hillsboro, Oregon Lines: 21 In-Reply-To: john@acorn.co.uk's message of 17 Apr 91 12:32:19 GMT >The only way in which I can see a general bit extract helping is >if an instruction of the form:- > > extract 32 bits from this register *PAIR* > >exists; then the above can be reduced to two instructions. The i386(tm) architecture's SHLD and SHRD (shift left double and shift right double) allow 32 bits to be extracted from a register pair. They overwrite one of their source operands, though, so a MOV is required in the general case (although usually you can set things up so as not to need one of the operands afterwards). -- Andy Glew, glew@ichips.intel.com Intel Corp., M/S JF1-19, 5200 NE Elam Young Parkway, Hillsboro, Oregon 97124-6497 This is a private posting; it does not indicate opinions or positions of Intel Corp.