Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 (Tek) 9/26/83; site mako.UUCP Path: utzoo!linus!decvax!tektronix!orca!mako!jans From: jans@mako.UUCP (Jan Steinman) Newsgroups: net.arch Subject: Re: Re: Re: Arbitrary byte alignment Message-ID: <348@mako.UUCP> Date: Mon, 29-Oct-84 12:46:05 EST Article-I.D.: mako.348 Posted: Mon Oct 29 12:46:05 1984 Date-Received: Thu, 1-Nov-84 02:25:16 EST References: <470@houxl.UUCP> <420@intelca.UUCP> <1745@sun.uucp> Reply-To: jans@mako.UUCP (Jan Steinman) Organization: Tektronix, Wilsonville OR Lines: 38 Summary: In article wls@astrovax.UUCP (William L. Sebok) quotes, writes: >> ...68020 allows totally arbitrary alignment. The 68020 also takes a byte >> address as the base, and adds a 32-bit signed bit number; if you don't >> need the byte addressas e.g. an array base, you can still address up to >> 2Gbits or 256Mbytes with simple sequential bit numbers (easy for >> hardware since the word size is a power of 2). > >Since no one has mentioned it yet I think that I should say that the Vax >also has such bit string instructions that let one address a bit string of 1 >to 32 bits with arbitrary alignment with respect to word boundaries. A bit >address consists of a byte address base and a signed 32 bit offset from the >base. Please add to the list the NS32000 chips. National >almost< did it right... The general form is a base and a signed, 30 bit, bit offset from that base. (Offsets also come in signed 14 and 7 bit lengths for memory conservation.) A useful instruction (CVTP) generates the absolute address for such an item. (Kinda like an LEA for bits.) Why do I say "almost" did it right? The instruction set is not quite orthogonal when it comes to >bit fields<. While still capable of arbitrary alignment, the field may not span more than four bytes and may not have an immediate operand for offset! One use of bit fields is to break up imposed data structures, such as hardware registers, or comm strings. Such data structures seldom have dynamic alignment and a static, immediate operand offset to the beginning of the bit field would be useful. FLAME PROOF YOUR ARTICLE TODAY! Before you protest, note that the Extract Field Short (EXTSi) instruction is limited to a 3 bit, bit offset, which means you must have previously obtained the byte address of the target bit field. Useable in a pinch, but it sure smells like rubber cement! Incomplete orthogonality: you must use one of two instructions depending on the size of the target. -- :::::: Jan Steinman Box 1000, MS 61-161 (w)503/685-2843 :::::: :::::: tektronix!tekecs!jans Wilsonville, OR 97070 (h)503/657-7703 ::::::