# US 5,345,405 A · Circuit for detecting the position of an extreme "1" bit in a binary number

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

- Number: US 5,345,405 A
- Document ID: US5345405A
- Status: Granted
- Kind: A
- Application number: 07/978,005
- Filed: 1992-11-18
- Granted: 1994-09-06
- Earliest claimed: 1991-11-19
- Assignees: Texas Instruments Incorporated
- Inventors: Brendan Walsh; Richard Simpson; Laura Dudbridge; David Collins; Philip Moyse
- Web page: https://patentgrep.com/patent/US5345405A

## CPC

- G06F 7/74: Selecting or encoding within a word the position of one or more bits having a specified value, e.g. most or least significant one or zero detection, priority encoders {(with shifting G06F5/01)}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Apparatus for detecting the leftmost "1" bit or the rightmost "1" bit of an input number includes a binary tree (11) of two-inputs OR-gates (13, 14, 15, 16) or their logical equivalent to which the input number is applied in parallel and from which signals are derived and applied as inputs and to control a plurality of trees (MA, MB, MC) of two-input multiplexers (12) from the outputs (E0, E1, E2, E3) of which appear the bits of a number representing the position in the input number of the leftmost "1" or the rightmost "1" bit.

## Claims

### Claim 1

Apparatus for detecting the "1" bit of an input binary number of n-bits having an extreme position in that number and for producing an output representing that position, the apparatus including a binary tree of two-input OR-gate means having m stages, where 2.sup.m .gtoreq.n, with or without the final stage of the tree containing a single OR-gate means, and having a first stage with up to 2.sup.m-1 OR-gate means to the inputs of which the bits of the input number are respectively applied, and a multiplexer circuit having m-2 multiplexer trees selectively responsive to inputs to and outputs from the stages of the binary tree to produce respective output bits which in combination with an output from the penultimate stage of the binary tree form a binary number representing the position of the extreme "1" bit in the input number.

### Claim 2 (depends on 1)

Apparatus according to claim 1 including the final stage of the OR-gate binary tree and having an output terminal connected to the output of the single OR-gate means of the final stage, that output indicating that at least one "1" bit appears in the input binary number.

### Claim 3 (depends on 1)

Apparatus according to claim 1 wherein the binary tree of OR-gate means comprises a plurality of OR-gates.

### Claim 4 (depends on 1)

Apparatus according to claim 1 wherein alternate stages of the binary tree of OR-gate means comprise NOR-gates and intervening stages of that tree comprise NAND-gates.

### Claim 5 (depends on 4)

Apparatus according to claim 4 wherein the alternate stages of the binary tree include one or more inverters for re-erecting the output signals of respective NOR-gates for application to the multiplexer circuit.

### Claim 6 (depends on 4)

Apparatus according to claim 4 wherein the output signals from the NOR-gates in the alternate stages of the binary tree are applied directly to the multiplexer circuit, the multiplexer circuit being so constructed to use inverted signals from the alternate stages and erect signals from the intervening stages of the binary tree.

### Claim 7 (depends on 1)

Apparatus according to claim 1 wherein the multiplexer trees are formed of one or more two-input multiplexers in one or more stages connected in cascade, the inputs to the multiplexers of the first stage of each tree are derived from input signals to OR-gate means in a stage of the binary tree respective to the particular multiplexer tree and control signals for the multiplexers of each tree are derived from the output signals of the OR-gate means in corresponding stages of the binary tree starting with the stage from whose input signals the input signals to the particular multiplexer tree are derived.

### Claim 8 (depends on 7)

Apparatus according to claim 7 wherein the input and control signals of each multiplexer tree are derived from the same-handed ones of the signals taken in pairs of the binary tree of OR-gate means, the handedness of the signals being dependent on whether the position of the leftmost "1" bit or of the rightmost "1" bit of the input signal is to be identified.

### Claim 9 (depends on 1)

Apparatus according to claim 1 wherein each multiplexer comprises two transmission gates connected from respective inputs to a common output, one of the transmission gates being capable of transmitting signals and the other not capable of transmitting signals, depending on a control signal.
