CA1076708A - Parallel bidirectional shifter - Google Patents

Parallel bidirectional shifter

Info

Publication number
CA1076708A
CA1076708A CA280,669A CA280669A CA1076708A CA 1076708 A CA1076708 A CA 1076708A CA 280669 A CA280669 A CA 280669A CA 1076708 A CA1076708 A CA 1076708A
Authority
CA
Canada
Prior art keywords
word
shifting
input
network
output
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired
Application number
CA280,669A
Other languages
French (fr)
Inventor
Caesar Cesaratto
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nortel Networks Ltd
Original Assignee
Northern Telecom Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Northern Telecom Ltd filed Critical Northern Telecom Ltd
Priority to CA280,669A priority Critical patent/CA1076708A/en
Priority to GB15005/78A priority patent/GB1575158A/en
Priority to JP53065886A priority patent/JPS6036612B2/en
Priority to SE7806741A priority patent/SE438044B/en
Priority to FR7817997A priority patent/FR2394869A1/en
Application granted granted Critical
Publication of CA1076708A publication Critical patent/CA1076708A/en
Expired legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F5/00Methods or arrangements for data conversion without changing the order or content of the data handled
    • G06F5/01Methods or arrangements for data conversion without changing the order or content of the data handled for shifting, e.g. justifying, scaling, normalising
    • G06F5/015Methods or arrangements for data conversion without changing the order or content of the data handled for shifting, e.g. justifying, scaling, normalising having at least two separately controlled shifting levels, e.g. using shifting matrices

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Shift Register Type Memory (AREA)
  • Executing Machine-Instructions (AREA)
  • Use Of Switch Circuits For Exchanges And Methods Of Control Of Multiplex Exchanges (AREA)
  • Communication Control (AREA)
  • Time-Division Multiplex Systems (AREA)

Abstract

PARALLEL BIDIRECTIONAL SHIFTER
Abstract of the Disclosure A circuit for shifting a binary data word having N-bits any number up to N-1 positions left or right is described.
A shifting network having a plurality of levels for shifting a binary word a predetermined number of positions in only one predetermined direction is cross-connected to a register such that the register stores the mirror image of the binary word appearing at the output of the shifting network. The output of the register is connected back to the input of the shifting network. By passing an input data word twice through the device, it can be shifted left or right any number of positions.

- i -

Description

iO7~;';01~

The invention relates to a data processor generally and more particularly to a circuit for the bidirectional shifting and data handling of a binary word.
It is well known in the data processor art to provide a means for shifting the relative positions of bits in a binary word. It is equally well known to provide circuit means to mask a first portion of a binary word to isolate the second portion thereof for further processing.
In the case of a byte-by-byte processor, it is well known to provide the shifting function by using a pair of memories, a shifting circuit and logic circuitry for rearranging the relative positions of the bits as they are transferred from one memory to the other. Such a circuit is described in United States patent number 3,996,566 issued to J.C. Moran.
In the case of processors which operate on the full binary word, it is also well known to achieve the shifting function by means of a shifting network which shifts the data at a plurality of levels. For example, such a circuit is described in United States patent number 3,596,251 issued on July 27, 1971 to J.S. Buchan and F.P. Turpin and assigned to applicant's assignee. This patent describes a logical shifting device having a plurality of levels, each of which includes a left shift logical uni~, a no-shift logical unit and a right shift logical unit. These units are logically interconnected to permit an input binary word comprising N-bits to be shifted left or right by up to N-l positions. During shifting, a binary word to be shifted is allowed to propagate through one of the logical units at each level and the time taken for a shifting operation is constant for all magnitudes of shift. That device - 30 has been found to be completely adequate for its intended ~ purpose of shifting the relative position of bits in a binary 10~70~ .

word but it is not well adapted to perform other logical functions.
It is an object of this invention to provide a parallel bidirectional shifter and data handler which exhibits advantages over the prior art circuits. It is a feature of the invention that the circuit may be used to efficiently isolate a field of data within an input binary word whereby the field is right justified; that is, the output binary word contains only the isolated bits located at the least significant positions of the word. It is also a feature of the circuit of the invention that it may be realized using a minimum of components and of the type which are available commercially on an off-the-shelf basis.
It is a further feature of the invention that any functioh of the circuit may be completed in minimum real time and in which the time taken to complete any operation is constant.
In accordance with the invention, there is ; provided a circuit for shifting a binary word having N bits any number up to N-l positions left or right. A shifting network is used to shift an input binary word a predetermined number of positions in one predetermined direction. An accumulator register is logically connected to the shifting network to store the mirror image of the binary word appearing at the output of the shifting network. A shift control circuit under control of a processor enables the appropriate portions of the shifting network to obtain the desired shift quantity and the input binary word is circulated twice through the shifting network and the accumulator register for any one operation.
Because the circuit performs the shifting function using two microinstructions, the second one being performed on the mirror image data resulting from the first instruction, the data field isolation ~masking) function may be efficiently performed using the same circuit and in minimum real time.

.' .
,:
.

~07~70~

These and other aspects of the invention will become clearer upon consideration of the following example embodiment of the invention in conjunction with the drawings in which:
Figure 1 is a block diagram of a parallel bidirectional shifting circuit in accordance with the invention;
Figure 2 is a schematic block diagram of the circuit shown in figure l;
Figure 3 is a schematic diagram of one of the gates illustrated in figure 2 together with the associated truth table;
Figure 4 is a timing diagram depicting the operation of the circuit of figure 2; and Figures 5 - 7 illustrate binary words appearing at different points in the circuit of figure 2 for different functions.
The following example embodiment of the invention is a circuit adapted to operate on a binary word having sixteen bits (0 - 15). It should be realized that a bidirectional shifting and data handling circuit using the invention may be constructed to operate on binary words of any length.
Figure 1 shows a shifting network 20 having four levels identified as SH-l or SH-0, SH-2 or SH-0, SH-4 or ~H-0 and SH-8 or SH-0. These are logically interconnected as described below and each level is adapted to shift an input data word a predetermined number of positions or zero position. A shift control circuit 21 is responsive to clock signals and to a four-bit data field from a microprocessor data register (not shown) for providing the enabling signals (2d, 21, 22, 23) for the corresponding levels of the shifting network 20. An accumulator register 22 has a selective gating input for accepting data from : - 3 -iO7~;70~

an input data bus or from the shifting network 20. The accumulator register 22 is controlled by a select control signal from the microprocessor and clock signals. The parallel output leads 0 - 15 of the shifting network 20 are cross-connected to the sixteen inputs 15 - 0 of the register 22 such that the ?
register 22 stores the mirror image of the binary word appearing at the output of the shifting network 20. The outputs from the register 22 are connected to a bus 23 which serves as the output data bus for the device and as a circulating bus for feeding the output data from the register 22 back to the input of the shifting network 20.
Figure 2 is a schematic diagram of the circuit of figure 1. The shift control circuit 21 is not shown in any greater detail than it is in figure 1 since it may simply be a register controlled by the clock signals for providing the four enable signals Sl, S2, S4 and S8 corresponding to the four levels of shifting gates in the network 20.
Each shifting level in the network 20 comprises sixteen gates A0 - A15, B0 - B15, CO - C15 and D0 - D15. Each of these gates has a pair of inputs either of which may be -selected by a control signal (Sl, S2, S4, S8). Figure 3 illustrates one such gate together with a truth table showing the operation of the gate. When the select or enable lead is idle, the gate G allows the data on input lead ~ to appear on ~ ~
the output lead C and when the select lead is enabled, the gate G ~ -allows the data on input B to appear on the output lead C. This type of gate is available commercially as an off-the-shelf component and is commonly known as a dual-input data select gate.
The gates at each level of the shifting network are logically connected to the gates at the previous level for shifting the binary word a predetermined number of positions ..... .
. . ' ' , ,. . . .. .

10~70~

to the left. For example, each of the gates A0 - A15 at the first level is connected to two leads of the bus 23. If the lead Sl is not enabled the gates A0 - A15 have no effect on the data word appearing on the bus 23 other than allowing it to appear at their output; however, if the lead Sl is enabled, the gates A0 - A15 effectively shift the data appearing on the bus 23 one position to the left. Similarly, the gates B0 - B15 at the second level are adapted to not shift (lead S2 not enabled) or to shift (lead S2 enabled) the data appearing at the output of the first level gates A0 - A15, 2 positions to the left. The gates at the third and fourth levels are similarly adapted to not shift or to shift left 4 and 8 positions respectively.
Therefore, by allowing a binary word having N-bits to propagate through the four levels of the shifting network 20 and by selectively enabling the levels thereof, the binary word appearing at the output of the shifting network may reflect a shift-left of any number of positions up to N-l.
i The accumulator register 22 comprises sixteen flip-flops (RO - R15) each having two-input selective gates of the type previously described. These elements are also available commercially as off-the-shelf components. A first set of inputs ` to the elements R0 - R15 are respectively connected to the leads of an input data bus. A binary data word appearing on that bus may be loaded in register 22 on a clock signal and by enabling the select lead. This signal is normally generated in the microprocessor (not shown) of the system. A second set of inputs (RO - R15) to the elements R0 - R15 of the register 22 are cross-connected to the outputs D0 - D15 of the network 20.
These cross-connections are represented by the intersecting arrows 24. Effectively, output D0 is connected to input R15, Dl to R14, D2 to R13, D3 to R12, D4 to Rll........... and D15 107~i7V~

to R0. Therefore, register 22 stores the mirror image of the binary data word which appears at the output of the network 20.
The outputs of elements R0 - Rl5 in the register 22 are connected to a bus 23 which serves as the output data bus for the device and also serves to feed back to the input of the shifting network 20 the binary data word appearing at the output of register 22.
It should be understood that the input data bus ; is only connected to the input of the register 22 for convenience.
It could just as well be connected directly to the input of the shifting network 20.
Operation A greater understanding of the above described circuit may be obtained from the following description of operation in conjunction with the timing diagram of figure 4 and the examples illustrated in figures 5 to 7.
The binary word to be shifted is applied to leads 0 - 15 of the input data bus. At the same time, the select lead is enabled (one level), and the shift quantity data field is sent to the shift control circuit 21. On the occurrence of the next clock pulse (to, fig. 4) the appropriate levels of the shifting network 20 are enabled, the binary data word on the input data bus is loaded into register 22 and appears at the input of the network 20 via bus 23 and propagates therethrough.
At the next clock pulse (tl, fig. 4) this data is loaded into register 22 and the operation is repeated except that the select ', control lead is not enabled (zero level). Figures 5 to 7 illustrate the operation on a binary word to achieve various functions.
Figure 5 illustrates the operation on a binary word to achieve a shift-left of seven positions. On the first ' , 10'7670~

pass through the device, the binary word is shifted left seven positions (levels 1, 2 and 3 are enabled) however, the resultant word is mirror-imaged in the register 22 because of the cross-connections 24. On the second pass the shifting network is not enabled at any level and because of the cross-connections 24, the register 22 contains the desired binary data word which is available on the output data bus.
Figure 6 illustrates the operation on a binary word to achieve a shift-right of nine positions. On the first pass through the network none of the levels are enabled, but because of the cross-connections 24, the binary word in the register 22 is the mirror image of the input data bus binary , word. On the second pass through the network 20, the binary '~ data word now in register 22 is shifted left nine positions (levels 1 and 4 are enabled) and loaded again into the register 22 via the cross-connections 24. The binary data word now in the register 22 reflects a shift of nine positions to the ; right relative the original binary data word and is now available on the output data bus.
Figure 7 illustrates the operation on a binary data word to achieve the isolation of a data field within the word. It is desired to isolate the data field comprising bits 3 to 6 of the binary word and to locate it at the least , significant positions of the word. On the first pass through the network, the word is shifted left nine positions (levels 1 and 4 enabled) and because of the cross-connections 24, the resultant data word in register 22 contains the mirror-image of 'f the data field located at the least significant positions, with the bits 0, 1 and 2, adjacent thereto. These are removed from the word by passing it again through the shifting network with a left shift of twelve positions (levels 3 and 4 enabled). The 107~70t~

resultant binary word in register 22 contains the required data field located at the least significant positions of the word with the remainder of the bits in the word being zeros.
Generally,the operation of the circuit may be summarized as follows. For a left shift of Y bit positions of a binary word having N bits - the binary word is shifted Y
positions left on the first pass through the circuit and is shifted zero positions on the second pass. For a shift right of X bit positions - the binary word is shifted zero positions on the first pass through the circuit and is shifted X positions left on the second pass. If it is desired to isolate and right justify a data field W bits wide which is D bit positions from ;j the most significant edge of the word - the binary word is , shifted D positions on the first pass through the circuit and is shifted N-W positions on the second pass.
As is depicted in the above examples, each shifting function left or right, and each data field isolation or masking function requires two passes through the device.
' These correspond to two microinstructions of a microprocessor which with current technology can readily operate on about a fifty nanoseconds per instruction basis. Therefore, the invention provides a bidirectional parallel shifter and data handling circuit which performs all of its intended functions in constant time and ~n minimum real time. It has the added advantages that it is simple, economical, and may be realized using commercially available off-the-shelf components. These advantages are accrued partly because only the hardware necessary for shifting in one direction is required.
, The embodiment of the invention described above 30 uses a shifting network for shifting a binary data word to the left. It should be realized that the invention applies just as ~076708 well to a shifting device using a shift right network. It is only a matter of inverting and interchanging the shifting functions of the first and second passes through the device.
For example, let us consider the case of figure 5 where it is desired to obtain a shift of seven positions left using a right-shifting network. On the first pass through the network, none of the levels are enabled (no-shift) and the word in register 22 is the mirror image of the original word. On the second pass, the word in register 22 is shifted right seven positions and mirror-imaged due to the cross-connections 24. The resultant word in register 22 reflects a shift left of seven positions relative the original word. Of course, it should be realized that if a right-shifting network is used, the masking function results in the bits of the isolated field being left-justified;
that is, the field occupies the most significant positions of the word in the accgmulator register.

Claims (6)

THE EMBODIMENTS OF THE INVENTION IN WHICH AN
EXCLUSIVE PROPERTY OR PRIVILEGE IS CLAIMED ARE DEFINED AS FOLLOWS:
1. A parallel bidirectional shifter circuit for shifting a binary data word having N-bits any number up to N-1 positions left or right, comprising, a shifting network for shifting a binary data word any number up to N-1 positions in one predetermined direction, the shifting network having N
output leads; and a data register having N storage locations and N input leads, the output leads of the shifting network being cross-connected to the input leads of the register such that a binary word loaded therein from the shifting network is the mirror image of the binary word appearing at the output of the network, the output of the register being connected back to the input of the shifting network.
2. A parallel bidirectional shifter circuit for shifting a binary data word having N-bits any number up to N-1 positions left or right comprising, a shifting network having a plurality of shifting levels each comprising a plurality of gates; the gates at each level of the network being logically connected to the gates at the previous level for shifting a binary data word at the output thereof a predetermined number of positions in one predetermined direction, said gates at each level being also logically connected to the gates at the previous level for transmitting a binary data word at the output thereof without positional shift; means for receiving signals for controlling the operation of said gates at each level; and a data register having its input cross-connected to the output of the shifting network such that a binary word loaded in the register from the network is the mirror image of the binary data word appearing at the output thereof, the output of the register being connected back to the input of the shifting network.
3. A shifter circuit as defined in claim 2 wherein each of the gates at each level of the shifting network is a dual-input data select gate.
4. A shifter circuit as defined in claim 3 and further comprising, a plurality of input and output terminals for connection to input and output data buses respectively and wherein each storage element of the data register includes a dual-input data select gate having a first input connected to one of said input terminals, a second input cross-connected to the shifting network, and an output connected to the input of the storage element, the output of each storage element being also connected to a respective one of said output terminals, and means for receiving signals for controlling the operation of the data select gates.
5. A shifter circuit as defined in claim 4 and further comprising means for receiving signals for controlling the loading of an input data word into said data register and for circulating said word twice through the shifting network and data register.
6. A method of shifting an input binary data word having N-bits any desired number up to N-1 positions left or right using a shifting network adapted to shift a binary word any number up to N-1 positions in only one predetermined direction, comprising the steps of:
passing the input binary word through the shifting network a first time to impart to it a first positional shift in said one direction, interchanging the relative position of the bits in the binary word resulting from the first pass to form the mirror-image thereof, passing the mirror-image word through the switching network to impart to it a second positional shift in said one direction, and interchanging the relative position of the bits in the binary word resulting from the second pass through the network to form the mirror-image thereof whereby the second formed mirror-image word reflects the desired positional shift left or right of the original binary word.
CA280,669A 1977-06-16 1977-06-16 Parallel bidirectional shifter Expired CA1076708A (en)

Priority Applications (5)

Application Number Priority Date Filing Date Title
CA280,669A CA1076708A (en) 1977-06-16 1977-06-16 Parallel bidirectional shifter
GB15005/78A GB1575158A (en) 1977-06-16 1978-04-17 Parallel bidirectional shifter
JP53065886A JPS6036612B2 (en) 1977-06-16 1978-06-02 parallel bidirectional shifter
SE7806741A SE438044B (en) 1977-06-16 1978-06-09 SET FOR CHANGING A INCOMING BINED DATA WORD AND A PARALLEL DOUBLE-DIRECT SHIFT CIRCUM FOR IMPLEMENTATION OF THE SET
FR7817997A FR2394869A1 (en) 1977-06-16 1978-06-15 BIDIRECTIONAL PARALLEL SHIFT PROCESS AND CIRCUIT

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CA280,669A CA1076708A (en) 1977-06-16 1977-06-16 Parallel bidirectional shifter

Publications (1)

Publication Number Publication Date
CA1076708A true CA1076708A (en) 1980-04-29

Family

ID=4108895

Family Applications (1)

Application Number Title Priority Date Filing Date
CA280,669A Expired CA1076708A (en) 1977-06-16 1977-06-16 Parallel bidirectional shifter

Country Status (5)

Country Link
JP (1) JPS6036612B2 (en)
CA (1) CA1076708A (en)
FR (1) FR2394869A1 (en)
GB (1) GB1575158A (en)
SE (1) SE438044B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS56109156U (en) * 1980-01-18 1981-08-24
JPS58144947A (en) * 1982-02-23 1983-08-29 Toshiba Corp Data shifting system
JPS59161731A (en) * 1983-03-07 1984-09-12 Hitachi Ltd Barrel shifter
JPS60179839A (en) * 1984-02-28 1985-09-13 Fujitsu Ltd Data shift circuit for processing digital signal
JPH02145364A (en) * 1988-11-28 1990-06-04 Olympus Optical Co Ltd Recoding head
US5988974A (en) * 1997-03-21 1999-11-23 Zackovich; Stanley E. Vehicle lifting and towing apparatus

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US3781819A (en) * 1971-10-08 1973-12-25 Ibm Shift unit for variable data widths
US3768077A (en) * 1972-04-24 1973-10-23 Ibm Data processor with reflect capability for shift operations

Also Published As

Publication number Publication date
FR2394869A1 (en) 1979-01-12
SE438044B (en) 1985-03-25
FR2394869B1 (en) 1984-10-26
JPS546740A (en) 1979-01-19
JPS6036612B2 (en) 1985-08-21
GB1575158A (en) 1980-09-17
SE7806741L (en) 1978-12-17

Similar Documents

Publication Publication Date Title
US4122534A (en) Parallel bidirectional shifter
EP0100511B1 (en) Processor for fast multiplication
US3702988A (en) Digital processor
US4591981A (en) Multimicroprocessor system
US3924144A (en) Method for testing logic chips and logic chips adapted therefor
US4237534A (en) Bus arbiter
US4621318A (en) Multiprocessor system having mutual exclusion control function
US4674032A (en) High-performance pipelined stack with over-write protection
US3296426A (en) Computing device
US4383304A (en) Programmable bit shift circuit
US4835672A (en) Access lock apparatus for use with a high performance storage unit of a digital data processing system
NL8900608A (en) PROGRAMMABLE PROCESSING DEVICE FOR LARGE-SCALE INTEGRATION.
WO1996032724A1 (en) High performance method of and system for selecting one of a plurality of ic chips while requiring minimal select lines
US4149263A (en) Programmable multi-bit shifter
EP0128194A1 (en) Programmed logic array.
US5125011A (en) Apparatus for masking data bits
CA1076708A (en) Parallel bidirectional shifter
GB1567536A (en) Data processors
US3659274A (en) Flow-through shifter
US3454310A (en) Boolian connective system
US4387294A (en) Shift register-latch circuit driven by clocks with half cycle phase deviation and usable with a serial alu
US4641278A (en) Memory device with a register interchange function
US4009468A (en) Logic network for programmable data concentrator
US3702463A (en) Data processor with conditionally supplied clock signals
US3380033A (en) Computer apparatus

Legal Events

Date Code Title Description
MKEX Expiry