# US 2005/0240646 A1 · Reconfigurable matrix multiplier architecture and extended borrow parallel counter and small-multiplier circuits

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2005/0240646 A1
- Document ID: US20050240646A1
- Status: Published application
- Kind: A1
- Application number: 10/830,766
- Filed: 2004-04-23
- Published: 2005-10-27
- Earliest claimed: 2004-04-23
- Assignees: The Research Foundation of State University of New York
- Inventors: Rong Lin
- Web page: https://patentgrep.com/patent/US20050240646A1

## CPC

- G06F 7/607: {number-of-ones counters, i.e. devices for counting the number of input lines set to ONE among a plurality of input lines, also called bit counters or parallel counters (for applications thereof, see the relevant places, e.g. G06F7/49, G06F7/5013, G06F7/509, H03M1/00, H03M7/20)}
- G06F 17/16: Matrix or vector computation {, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization (matrix transposition G06F7/78)}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A dynamically or run-time reconfigurable matrix multiplier architecture with a reconfiguration mechanism for computing the product of matrices Xp×r and Yr×q for any integers p, q, r and any item precision b, i.e., bitwidth, ranging from 4 to 64 bits is described. The reconfigurable matrix multiplier uses borrow parallel counters with new circuits, 6—0, and 6—1 and the improved small multiplier library. The reconfigurable matrix multiplier architecture is based on a novel scheme of trading data bitwidth for processing array or matrix size. The matrix multiplier achieves an extra compact, low power, high speed design through the use of a borrow parallel counters and a library of small borrow parallel multiplier circuits. The matrix multiplying processor using area comparable with a single 64×64-b multiplier constructed of very large-scale integrated (VLSI) circuits, can be reconfigured to produce the product of two matrices X(4×4) and Y(4×4) of 8, 16, and 32-bit data items in every 1, 4, and 16 pipeline cycles, respectively, or the product of two 64-b numbers in every pipeline cycle.

## Claims

### Claim 1

A matrix multiplier circuit receiving items having bitwidth ranging from 4 to 64 bits in a plurality of pipeline cycles, the circuit comprising:
a duplicating circuit for duplicating and distributing said received items;
a plurality of matrix multipliers for generating a product of at least two matrices;
at least one adder for adding partial products to create a plurality of results;
a plurality of accumulators for accumulating the plurality of results; and
a reconfiguration mechanism including reconfiguration switches, wherein said switches are set to states enabling said circuit to perform an operation selected from said adding and accumulating.

### Claim 2 (depends on 1)

The matrix multiplier circuit of claim 1, wherein the at least two matrices are X(p×r) and Y(r×q), where p, q, r are integers describing matrix dimensions.

### Claim 3 (depends on 1)

The matrix multiplier circuit of claim 1, wherein the plurality of accumulators is implemented using borrow parallel counter circuitry utilizing 1-hot out of four line signal encoding and borrow bits.

### Claim 4 (depends on 3)

The matrix multiplier circuit of claim 3, wherein said borrow parallel counter circuitry merges conversion and arithmetic operations into an embedded full adder circuit.

### Claim 5 (depends on 4)

The matrix multiplier circuit of claim 4, wherein a plurality of transistors being gated by 4-b 1-hot signals is provided, which results in a significant reduction in switching activity and hot data paths.

### Claim 6 (depends on 5)

The matrix multiplier circuit of claim 5, wherein an area used for the matrix multiplier circuit is similar in size to that used for a single 64×64-b matrix multiplier circuit constructed of very large-scale integrated (VLSI) circuits.

### Claim 7 (depends on 5)

The matrix multiplier circuit of claim 5, wherein an area on said circuit taken by said plurality of matrix multipliers is 0.18 mm and an area taken by said parallel counter circuitry is 0.25 mm.

### Claim 8 (depends on 1)

The matrix multiplier circuit of claim 1, wherein said circuit is directly reconfigured to produce a product of two matrices having sizes selected from at least one of:
(1×1) when 64 bits of input are provided in every pipeline cycle,
(2×2) when 32 bits of input are provided in every 2 pipeline cycles,
(4×4) when 16 bits of input are provided in every 4 pipeline cycles,
(8×8) when 8 bits of input are provided in every 8 pipeline cycles, and
(16×16) when 4 bits of input are provided in every 16 pipeline cycles,

### Claim 9 (depends on 8)

The matrix multiplier circuit of claim 8, wherein the circuit further being directly reconfigured to produce a product of selected from one of
four 16-item square matrix pairs of 8-bit data in every 4 pipeline cycles,
(4×4) when 16 bits of input are provided in every 4 pipeline cycles,
(4×4) when 32 bits of input are provided in every 16 pipeline cycles, and
a product of two 64-b numbers in every pipeline cycles.

### Claim 10 (depends on 9)

The matrix multiplier circuit of claim 9, wherein the reconfiguration mechanism performs dynamically and in real-time.

### Claim 11 (depends on 1)

The matrix multiplier circuit of claim 1, wherein the circuit is constructed of 64(8×8) small multipliers.

### Claim 12 (depends on 1)

The matrix multiplier circuit of claim 1, wherein the parallel counter circuitry is an arithmetic circuit including at least one borrow parallel counter and at least one 4-bit one-hot digital signal.

### Claim 13 (depends on 1)

The matrix multiplier circuit of claim 1, wherein said circuit is utilized for size-4 matrix operations critical to graphics processing.

### Claim 14 (depends on 1)

The matrix multiplier circuit of claim 1, wherein borrow parallel counter 5_1 and 5_1_1 circuits are provided, which results in increase of speed and testing ability of the circuit and in decrease of power consumption and area of implementation.

### Claim 15 (depends on 4)

The matrix multiplier circuit of claim 4, wherein said single embedded full adder circuit achieves high performance while expending low-power.

### Claim 16

A method of using a reconfigurable matrix multiplier circuit for generating a product of at least two matrices, said circuit comprising a plurality of matrix multipliers, an arithmetic circuit including at least one borrow parallel counter and at least one 4-bit one-hot digital signal, and a reconfiguration mechanism for computing the product of said two matrices, the method comprising the steps of:
receiving a plurality of input bit items;
duplicating said items and distributing said duplicated plurality of items to a plurality of base multipliers; and
setting states of reconfiguration switches to perform:
adding of partial products to create a plurality of results, and
accumulating the plurality of results.

### Claim 17 (depends on 16)

The method of claim 16, wherein matrices being multiplied are of a form X(h×h), and Y(h×h), bitwidth of said input items is b-bit, and said method is performed on combinations of h-b pairs selected from 4-8, 2-16 and 1-32.

### Claim 18 (depends on 17)

The method of claim 17, wherein the product of XY is produced when a column from the matrix X and a row from the matrix Y are operated upon in each pipeline step of the reconfigurable matrix multiplier circuit.

### Claim 19

A borrow parallel counter includes 6 input bits, the counter comprising:
a borrow parallel counter circuit selected from borrow parallel counter 5_1 or 5_1_1 circuits; and
a 3:2 shift switch parallel counter circuit.

### Claim 20 (depends on 19)

The borrow parallel counter of claim 19, wherein all 6 input bits of the borrow parallel counter are weighted 1, said counter being called a borrow parallel counter 6_0.

### Claim 21 (depends on 19)

The borrow parallel counter of claim 19, wherein 5 input bits of the borrow parallel counter are weighted 1 and 1 input bit is weighted 2, said counter being called a borrow parallel counter 6_1.

### Claim 22

A method of producing a reconfigurable matrix multiplier, the method comprising the following steps:
providing a partial product generator;
selecting a multiplier from a library, wherein said library comprises a plurality of small multipliers, each of said multipliers including at least one borrow parallel counter selected from one of borrow parallel counter 5_1, 5_1_1, 6_0, and 6_1 circuits and at least one shift switch parallel counter selected from one of 3:2 and 2:2 shift switch parallel counters for reducing partial products to two numbers; and
providing a one stage carry look-ahead adder with a carry propagate node.

### Claim 23 (depends on 22)

The method of claim 22, wherein said 3:2 shift switch parallel counter further includes 24 transistors and a double-rail output S, for generating S complement without the use of an inverter.

### Claim 24 (depends on 22)

The method of claim 22, wherein one or more of said small multipliers of said library process input ranging from 3 to 9 bits

### Claim 25

A reconfigurable matrix multiplier comprising:
a partial product generator;
a multiplier selected from a library of multipliers, wherein said library comprises a plurality of small multipliers, each of said multipliers including at least one borrow parallel counter selected from one of borrow parallel counter 5_1, 5_1_1, 6_0, and 6_1 circuits and at least one shift switch parallel counter selected from one of 3:2 and 2:2 shift switch parallel counters for reducing partial products to two numbers; and
a one stage carry look-ahead adder with a carry propagate node.

### Claim 26 (depends on 25)

The method of claim 25, wherein said 3:2 shift switch parallel counter further includes 24 transistors and a double-rail output S, for generating S complement without the use of an inverter.

### Claim 27 (depends on 25)

The method of claim 25, wherein one or more of said small multipliers of said library process input ranging from 3 to 9 bits.
