[go: up one dir, main page]

DE19601575A1 - Parallel cutting of binary integer numbers for image processor - Google Patents

Parallel cutting of binary integer numbers for image processor

Info

Publication number
DE19601575A1
DE19601575A1 DE19601575A DE19601575A DE19601575A1 DE 19601575 A1 DE19601575 A1 DE 19601575A1 DE 19601575 A DE19601575 A DE 19601575A DE 19601575 A DE19601575 A DE 19601575A DE 19601575 A1 DE19601575 A1 DE 19601575A1
Authority
DE
Germany
Prior art keywords
bit
input
mask
circuit
clipping
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.)
Withdrawn
Application number
DE19601575A
Other languages
German (de)
Inventor
Alan H Karp
Dennis Brzezinski
Rajiv Gupta
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.)
HP Inc
Original Assignee
Hewlett Packard Co
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 Hewlett Packard Co filed Critical Hewlett Packard Co
Publication of DE19601575A1 publication Critical patent/DE19601575A1/en
Withdrawn legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/76Arrangements for rearranging, permuting or selecting data according to predetermined rules, independently of the content of the data
    • G06F7/764Masking
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30003Arrangements for executing specific machine instructions
    • G06F9/30007Arrangements for executing specific machine instructions to perform operations on data operands
    • G06F9/3001Arithmetic instructions
    • G06F9/30014Arithmetic instructions with variable precision
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30003Arrangements for executing specific machine instructions
    • G06F9/30007Arrangements for executing specific machine instructions to perform operations on data operands
    • G06F9/30036Instructions to perform operations on packed data, e.g. vector, tile or matrix operations
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30003Arrangements for executing specific machine instructions
    • G06F9/30007Arrangements for executing specific machine instructions to perform operations on data operands
    • G06F9/30036Instructions to perform operations on packed data, e.g. vector, tile or matrix operations
    • G06F9/30038Instructions to perform operations on packed data, e.g. vector, tile or matrix operations using a mask

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • Executing Machine-Instructions (AREA)

Abstract

In a circuit (100) and method for clipping input integers to a specified range, a mask is provided in which a bit is set for each out-of-range bit and not set for in-range bits and the mask is applied to input integers so that any integer outside of the range is clipped to the quantity in the range closest to the integer, thereby producing output integers within a range specified by the mask. The input data are sub-divided into blocks which are clipped in parallel. The arrangement allows clipping from both signed and unsigned input data and to both signed and unsigned output data in any combination. A clip instruction includes a mask field. The data type may be encoded in the instruction opcode and/or in the mask.

Description

Die vorliegende Erfindung bezieht sich auf Datenverarbei­ tungssysteme und insbesondere auf ein Verfahren und eine Vorrichtung zum parallelen Abschneiden von Ganzzahlen.The present invention relates to data processing systems and in particular to a method and a Device for parallel truncation of integers.

Seit ihrer ersten Verwendung haben sich Computer dramatisch entwickelt. Die ersten Computer wurden hauptsächlich für nu­ merische Berechnungen verwendet. Sowie sich die Speiche­ rungs- und Wiedergewinnungs-Fähigkeiten von Computern ver­ besserten, wurden Computer häufig zur Datenverwaltung ver­ wendet. Während die Computerspeicherung in der Vergangenheit hauptsächlich zum Speichern von Text und numerischen Infor­ mationen verwendet wurde, weisen moderne Computer Speicher­ möglichkeiten auf, die ausreichend groß sind, um große Men­ gen von Bilddaten zu speichern.Since their first use, computers have changed dramatically developed. The first computers were mainly for nu meric calculations used. As well as the spoke Computer recovery and recovery capabilities improved, computers were often used for data management turns. While computer storage in the past mainly for storing text and numerical information mations has been used, modern computers have memory opportunities that are large enough to accommodate large menus image data.

Eine weitere dramatische Veränderung bei Computern ist die umfassende Verbesserung der Prozessorgeschwindigkeit. Eine erhöhte Prozessorgeschwindigkeit führte ebenfalls zu vielen neuen Anwendungen.Another dramatic change in computers is that comprehensive improvement in processor speed. A increased processor speed also led to many new applications.

Parallel zur Entwicklung von Computern fand ebenfalls die Entwicklung der Video- und Tontechnologie sowie der Kommuni­ kationstechnologie statt. Diese Technologien wurden zuneh­ mend computerisiert.In parallel to the development of computers, the Development of video and sound technology as well as communication cation technology instead. These technologies were increasing mend computerized.

Ein Ergebnis der parallelen Entwicklung dieser Technologien ist die Vermischung von Anwendungen, wobei beispielsweise ein Benutzer in die Lage versetzt wird, mit gespeicherten Bildern und Ton zu interagieren. Die Verschmelzung von Vi­ deo- und Audiotechnologien mit der Computertechnik wird oft "Multimedia" genannt. Multimedia baut auf den Fähigkeiten moderner Computer auf, sowohl große Datenmengen zu speichern als auch schnelle Berechnungen durchzuführen. A result of the parallel development of these technologies is the mixing of applications, for example a user is enabled with saved To interact with images and sound. The merger of Vi deo and audio technologies with computer technology is often Called "multimedia". Multimedia builds on skills modern computer to store both large amounts of data as well as perform quick calculations.  

Eine wichtige Funktionalität für Multimedia-Anwendungen ist die Fähigkeit, Bilder und Sequenzen von Bildern über exi­ stierende Kommunikationsnetze, z. B. Telefonnetze, von einem Computer zu einem anderen zu übertragen. Die Datenmenge, die übertragen werden muß, ist riesig. Ein Farbbild auf einem SVGA-Endgerät benötigt beispielsweise eine Datenmenge von 780 Kilobyte. Eine Bildsequenz, wie z. B. eine Filmaufnahme, kann Milliarden von Bytes enthalten. Ungünstigerweise ten­ diert die Bandbreite gegenwärtig existierender Netze dahin, sehr schmal zu sein. Um das Problem des Übertragens großer Mengen von Daten über Netze mit schmaler Bandbreite zu lö­ sen, wurden mehrere Industriestandard-Bildkompressionstech­ niken entworfen, wie z. B. MPEG, JPEG und H.261. Diese Tech­ niken werden durchgehend verändert. Obwohl es möglich ge­ wesen ist, Prozessoren zu entwerfen, um spezielle Kompres­ sionstechniken auszuführen, ist es daher sehr schwierig, ei­ nen Prozessor zu entwerfen, der programmiert werden kann, um beliebige der gegenwärtigen und zukünftigen Kompressions­ techniken handzuhaben.An important functionality for multimedia applications is the ability to view images and sequences of images via exi permanent communication networks, e.g. B. telephone networks from one Transfer computer to another. The amount of data that has to be transferred is huge. A color image on one SVGA terminal, for example, requires a data amount of 780 kilobytes. An image sequence, such as B. a film recording, can contain billions of bytes. Unfortunately the bandwidth of currently existing networks to be very narrow. To the problem of transferring large Solve amounts of data over narrow bandwidth networks several industry-standard image compression tech niken designed such. B. MPEG, JPEG and H.261. This tech Techniques are continuously changed. Although it is possible has been to design processors to make special compresses It is therefore very difficult to carry out sion techniques design a processor that can be programmed to any of the current and future compression to handle techniques.

MPEG, JPEG, H.261 und weitere Kompressionstechniken haben gemein, daß sie ganzzahlige arithmetische Operationen auf die numerische Darstellung der Bilder ausführen, die sie komprimieren. Diese Operationen können in numerischen Größen resultieren, die sich außerhalb des zulässigen Bereichs der Hardware befinden. Es wird beispielsweise der Fall betrach­ tet, daß bestimmte Standards nur acht Bits pro Pixel zu­ lassen. Es würde nicht ungewöhnlich für Kompressionsopera­ tionen sein, Pixelwerte mit 11 bis 12 wertigen Bits zu er­ zeugen. Wenn der Versuch unternommen wird, solche Werte auf einer Hardwareanzeige mit einer Grenze von acht Bit pro Pixel anzuzeigen, ist das Ergebnis nicht vorhersagbar. Daher ist es nötig, die Ergebnisse auf einen annehmbaren Bereich abzuschneiden.MPEG, JPEG, H.261 and other compression techniques common that they have integer arithmetic operations execute the numerical representation of the images they compress. These operations can be in numerical sizes result that are outside the permissible range of Hardware. For example, consider the case tends that certain standards only eight bits per pixel to let. It wouldn't be unusual for compression operas be pixel values with 11 to 12 significant bits testify. If the attempt is made such values a hardware display with a limit of eight bits per Displaying pixels, the result is unpredictable. Therefore it is necessary to keep the results within an acceptable range to cut off.

Im Stand der Technik wurde das Abschneiden (sog. "clipping") von Bytes für vorzeichenlose Ganzzahlwerte durch Verwendung der folgenden Sequenz erreicht:In the prior art, the clipping of bytes for unsigned integer values through use in the following sequence:

wenn (ix < 0) ix := 0;
wenn (ix < 255) ix := 255.
if (ix <0) ix: = 0;
if (ix <255) ix: = 255.

Ungünstigerweise resultiert diese einfache Sequenz, wenn sie in einen Maschinencode übersetzt wird, in einem Code mit zwei Vergleichsoperationen und zwei Verzweigungen. Ferner müßte die Sequenz, obwohl Mehrfach-Prozessoren verwendet werden, sequentiell auf alle Pixel in einem Bild ausgeführt werden. Da die Busbreite und die Registerbreite der meisten modernen Computer viel größer als 8 oder 16 Bit ist, nützt das Durchführen der Abschneideoperation bei einem Pixel zu einem Zeitpunkt die gesamte Leistungsfähigkeit des Computers nicht aus.Unfortunately, this simple sequence results when it is translated into a machine code, in a code with two comparison operations and two branches. Further would need the sequence even though multiple processors are used are executed sequentially on all pixels in an image will. Because the bus width and the register width of most modern computer is much larger than 8 or 16 bit performing the clipping operation on a pixel the entire performance of the computer at a time not from.

Bestimmte Architekturen, wie z. B. RISC (RISC = Reduced In­ struction Set Computer = Computer mit reduziertem Befehls­ satz) weisen nur eine begrenzte Anzahl von Operationscodes auf. Bei diesen Architekturen ist es daher wichtig, eine neue Funktionalität zu schaffen, ohne die Anzahl der Opera­ tionscodes, die in den Prozessoren verwendet werden, wesent­ lich zu erhöhen. Eine solche Funktionalität ist das Ab­ schneiden von Ganzzahlen auf spezifizierte Bereiche. Es ist daher wünschenswert, diese Computer oder Prozessoren mit der Fähigkeit des Abschneidens von Ganzzahlen auf einen spezifi­ zierten Bereich unter Verwendung von nur einem Maschinenbe­ fehl zu versehen.Certain architectures, such as B. RISC (RISC = Reduced In struction set computer = computer with reduced command set) have only a limited number of opcodes on. With these architectures it is therefore important to have one to create new functionality without the number of Opera tion codes used in the processors are essential Lich increase. Such functionality is the Ab intersect integers to specified ranges. It is therefore desirable to use these computers or processors with the Ability to truncate integers to a specific decorated area using only one machine name to fail.

Die Aufgabe der vorliegenden Erfindung besteht demnach da­ rin, ein Verfahren zum Betreiben eines digitalen Prozessors und eine Schaltung zum Abschneiden von Ganzzahlen zu schaf­ fen, um ein schnelles und flexibles Abschneiden von Ganzzah­ len auszuführen.The object of the present invention is there rin, a method of operating a digital processor and to create an integer truncation circuit fen to quickly and flexibly cut off integers len to perform.

Diese Aufgabe wird durch ein Verfahren gemäß Anspruch 1 und durch eine Schaltung gemäß Anspruch 18 gelöst.This object is achieved by a method according to claim 1 and solved by a circuit according to claim 18.

Es ist wünschenswert, einen Allzweckcomputer oder einen Bildprozessor mit der Fähigkeit des schnellen Abschneidens von Ganzzahlen zu versehen. Es ist ferner wünschenswert, einen Computer oder Prozessor mit der Fähigkeit des Ab­ schneidens von Ganzzahlen auf parallele Art und Weise zu versehen.It is desirable to have a general purpose computer or one  Image processor with the ability to cut quickly of integers. It is also desirable a computer or processor with the ability of Ab truncate integers in a parallel fashion Mistake.

Es besteht somit ein wesentlicher Bedarf nach einer verbes­ serten Technik zum schnellen Abschneiden von Ganzzahlen.There is therefore an essential need for a verb technology for the fast truncation of integers.

Allgemein gesprochen erlaubt die Erfindung das parallele Ab­ schneiden von ganzzahligen Werten. Eine Hardware, die die Erfindung aufnimmt, enthält eine Einrichtung zum Speichern von Eingabedaten, die abgeschnitten werden sollen. Die Ein­ gabedaten werden in einen oder mehrere Eingabeblöcke unter­ teilt, welche auf parallele Art und Weise abgeschnitten wer­ den. Die Hardware enthält ferner eine Einrichtung zum Spei­ chern einer Maske. Die Maske wird auf die Eingabedaten ange­ wendet, derart, daß Ganzzahlen, die größer als die größte Ganzzahl eines spezifizierten Ausgabebereichs sind, durch diese größte Ganzzahl ersetzt werden, wohingegen Ganzzahlen, die kleiner als die kleinste Ganzzahl des Ausgabebereiches sind, durch diese kleinste Zahl ersetzt werden. Bei dem be­ vorzugten Ausführungsbeispiel werden alle Bit des Eingabeda­ tenwortes parallel verarbeitet.Generally speaking, the invention allows parallel Ab intersect integer values. A hardware that the Invention incorporates means for storing of input data to be cut off. The one Data is saved in one or more input blocks divides which one is cut off in parallel the. The hardware also contains a device for storage a mask. The mask is displayed on the input data applies such that integers larger than the largest Integers of a specified output range are, by this largest integer will be replaced, whereas integers, which is smaller than the smallest integer of the output area are replaced by this smallest number. With the be preferred embodiment, all bits of the input data tenwortes processed in parallel.

Die Maske definiert den Bereich der Ausgabedaten. Die Not­ wendigkeit des Abschneidens einer Ganzzahl wird durch Ver­ gleichen der Maske mit entsprechenden Datenbits bestimmt. Wenn mindestens ein eingestelltes Maskenbit einem einge­ stellten Datenbit entspricht, ist allgemein das Abschneiden notwendig. Wenn das Abschneiden nicht notwendig ist, wird der Eingabedatenblock zu dem Ausgabedatenblock mit einer beliebigen benötigten Bewegung eines Vorzeichenbits weiter­ geleitet. Wenn das Abschneiden notwendig ist, wird ein Ab­ schneidesignal eingestellt, um der Hardware anzuzeigen, die benötigte kleinste oder größte Anzahl in den Ausgabeblock zu zwingen. The mask defines the area of the output data. The need Ease of truncating an integer is determined by Ver same the mask with corresponding data bits determined. If at least one mask bit is set to one truncated data bit, is generally the clipping necessary. If the cutting is not necessary, will the input data block to the output data block with a any required movement of a sign bit headed. If cutting is necessary, an ab cutting signal set to indicate the hardware that required the smallest or largest number in the output block to force.  

Die Erfindung erlaubt das Abschneiden sowohl vorzeichenbe­ hafteter als auch vorzeichenloser Eingabedaten zu sowohl vorzeichenbehafteten als auch vorzeichenlosen Ausgabedaten in einer beliebigen Kombination. Es wird jedoch allgemein nicht bevorzugt, eine vorzeichenlose Eingabe zu einer vor­ zeichenbehafteten Ausgabe abzuschneiden. Der Datentyp der Eingabe und der Ausgabe kann entweder in dem Abschneide-Ope­ rationscode, in der Maske oder in der Kombination des Opera­ tionscodes und der Maske codiert sein.The invention allows cutting both vorzeichenbe liable as well as unsigned input data for both signed as well as unsigned output data in any combination. However, it becomes general not preferred to unsigned input to one before to cut off character-bound output. The data type of the Input and output can either be in the clipping ope ration code, in the mask or in the combination of the Opera tion codes and the mask.

Ein Ziel der Erfindung besteht darin, ein paralleles Ab­ schneiden von Ganzzahlen zu ermöglichen.An object of the invention is a parallel Ab to enable integer intersection.

Ein weiteres Ziel der Erfindung besteht darin, für das pa­ rallele Ganzzahlen-Abschneiden zu sorgen und alternative Ausführungsbeispiele zu schaffen, welche die parallele Ab­ schneidefunktion mit der minimalen Anzahl von Operations­ codes, die in einem Prozessor verwendet werden, durchführen.Another object of the invention is for the pa parallel integer truncation and alternative To create embodiments that the parallel Ab cutting function with the minimum number of operations Execute codes that are used in a processor.

Bevorzugte Ausführungsbeispiele der vorliegenden Erfindung werden nachfolgend bezugnehmend auf die beiliegenden Zeich­ nungen näher erläutert. Es zeigen:Preferred embodiments of the present invention are referred to below with reference to the attached drawing nations explained in more detail. Show it:

Fig. 1 ein Blockdiagramm eines Prozessors mit einer Ganz­ zahlen-Abschneideschaltung gemäß einem bevorzugten Ausführungsbeispiel der Erfindung; Fig. 1 is a block diagram of a processor with an integer clipping circuit according to a preferred embodiment of the invention;

Fig. 2 ein Blockdiagramm, das die Baublöcke der Abschnei­ de-Schaltung gemäß einem bevorzugten Ausführungsbei­ spiel der Erfindung und die Daten-, Masken- und Aus­ gabe-Register zeigt; Fig. 2 is a block diagram showing the building blocks of the clipping circuit according to a preferred embodiment of the invention and the data, mask and output registers;

Fig. 3 ein Blockdiagramm, das eine Schaltungsanordnung zum Bestimmen des Wertes des Vorzeichenbits des Einga­ be-Speicherbereiches zeigt, der jedem Byte von Aus­ gabedaten entspricht; Fig. 3 is a block diagram showing a circuit arrangement for determining the value of the sign bit indicates the entranc be-storage area corresponding to display data of each byte off;

Fig. 4 ein Blockdiagramm, das Details der Halbwort- und Byte-Logikschaltungen der Abschneideschaltung von Fig. 2 zeigt; Fig. 4 is a block diagram showing details of the half-word and byte logic circuits of the clipping circuit of Fig. 2;

Fig. 5 ein Blockdiagramm, das das Größenauswahlgatter jeder Byte-Logikschaltung von Fig. 4 zeigt; Fig. 5 is a block diagram showing the size selection gate of each byte logic circuit of Fig. 4;

Fig. 6 ein Logikdiagramm der Bit-Logikschaltung der Byte- Logikschaltungen von Fig. 4. FIG. 6 is a logic diagram of the bit logic circuit of the byte logic circuits of FIG. 4.

Es ist beabsichtigt, die Erfindung in einem Allzweck-Compu­ terprozessor oder in einem beliebigen anderen programmierba­ ren Prozessor zu verwenden. Die Erfindung ermöglicht es, daß der Prozessor Ganzzahlen abschneidet, indem er einen einzi­ gen Assemblersprache-Befehl verwendet. Darüber hinaus er­ laubt die Erfindung bei Prozessoren mit einer Busbreite, die breiter als die Breite der nicht-abgeschnittenen Ganzzahlen ist, das parallele Abschneiden von mehreren Ganzzahlen.The invention is intended to be used in a general purpose compu processor or in any other programmable processor. The invention enables that the processor truncates integers by one gen assembly language command used. In addition, he the invention allows processors with a bus width that wider than the width of the untruncated integers is the parallel truncation of multiple integers.

Fig. 1 ist ein Blockdiagramm eines Mikroprozessors 100 mit einer Registerdatei 101, einem Addierer 103 und einer Ganz­ zahlen-Abschneideschaltungsanordnung 105. Der Addierer 103 und die Ganzzahlen-Abschneideschaltung 105 sind beide mitei­ nander verbunden, um von der Registerdatei 100 eine Eingabe zu empfangen und Ergebnisse zu der Registerdatei 101 zurück­ zugeben. Die Registerdatei 101 ist ferner mit einem Speicher 107 verbunden. Die Registerdatei 101 ist betreibbar, um se­ lektiv ihre Register von dem Speicher 107 zu laden, und um den Inhalt der Register zurück in den Speicher 107 zu spei­ chern. Fig. 1 is a block diagram of a microprocessor 100 having a register file 101, an adder 103 and an integer clipping circuit assembly 105. Adder 103 and integer clipping circuit 105 are both connected to receive input from register file 100 and return results to register file 101 . The register file 101 is also connected to a memory 107 . Register file 101 is operable to selectively load its registers from memory 107 and to store the contents of the registers back into memory 107 .

Der Mikroprozessor 100 umfaßt eine Steuerungseinheit 109, die mit einem Mikrocode-Speicher 111 verbunden ist. Die Steuerungseinheit ist über einen Signalweg 113 mit der Regi­ sterdatei 101, dem Addierer 102, der Abschneideschaltung 105 sowie mit weiteren nicht gezeigten Komponenten verbunden. Der Mikrocode-Speicher 111 enthält Befehle zum Steuern des Betriebs der verschiedenen Komponenten des Mikroprozessors 100. Die Steuerungseinheit ist betreibbar, um Befehle von einem Programmspeicher, beispielsweise von dem Speicher 107, zu empfangen. Die Steuerungseinheit decodiert diese Befehle und ruft ein entsprechendes Mikrocodeprogramm von dem Mikro­ code-Speicher 111 ab. Als Reaktion auf die Mikrocodebefehle, welche dieses Mikrocodeprogramm bilden, sendet die Steue­ rungseinheit 109 über den Signalweg 113 Signale zu den ver­ schiedenen Komponenten des Prozessors einschließlich der Re­ gisterdatei 101, des Addierers 103 und der Abschneideschal­ tungsanordnung 105.The microprocessor 100 comprises a control unit 109 which is connected to a microcode memory 111 . The control unit is connected via a signal path 113 to the register file 101 , the adder 102 , the clipping circuit 105 and to other components, not shown. Microcode memory 111 contains instructions for controlling the operation of the various components of microprocessor 100 . The control unit can be operated in order to receive commands from a program memory, for example from the memory 107 . The control unit decodes these commands and retrieves a corresponding microcode program from the microcode memory 111 . In response to the microcode commands forming this microcode program, the control unit 109 sends signals to the various components of the processor including the register file 101 , the adder 103 and the clipping circuitry 105 via the signal path 113 .

Für einen Fachmann ist es offensichtlich, daß der Mikropro­ zessor 100 über einen Bus mit weiteren Prozessoren und/oder Peripheriegeräten verbunden ist. Diese Komponenten sind Fachleuten bekannt und werden daher nicht gezeigt.It is obvious to a person skilled in the art that the microprocessor 100 is connected to further processors and / or peripheral devices via a bus. These components are known to those skilled in the art and are therefore not shown.

Bei dem bevorzugten Ausführungsbeispiel enthält der Speicher 107 adressierbare Positionen, von denen jede 64 Bit breit ist. Ferner sind die Register in der Registerdatei 100 min­ destens 64 Bit breit, wobei die Wege zwischen dem Speicher 107 und der Registerdatei 101, zwischen der Registerdatei 101 und dem Addierer 103 und zwischen der Registerdatei 101 und der Abschneideschaltung 105 mindestens 64 Bit breit sind.In the preferred embodiment, memory 107 contains addressable positions, each 64 bits wide. Furthermore, the registers in the register file 100 are at least 64 bits wide, the paths between the memory 107 and the register file 101 , between the register file 101 and the adder 103 and between the register file 101 and the clipping circuit 105 being at least 64 bits wide.

Bei einer Anwendung der Erfindung enthält der Speicher 107 digitalisierte Bilder. Es ist bekannt, daß bei der Bild­ verarbeitung arithmetische Operationen mit den Ganzzahlen durchgeführt werden, die die Daten darstellen, die einem gegebenen Bildelement (einem Pixel) zugeordnet sind. Diese Operationen erstrecken sich häufig über den dynamischen Be­ reich der Daten hinaus, der von der Grafikhardware unter­ stützt wird. Um ein unvorhersehbares Verhalten zu verhin­ dern, werden die Daten abgeschnitten, um in den Bereich zu fallen, der von der Anzeigehardware erwartet wird.In an application of the invention, memory 107 contains digitized images. It is known that in image processing arithmetic operations are performed on the integers representing the data associated with a given picture element (pixel). These operations often extend beyond the dynamic range of data that is supported by the graphics hardware. To prevent unpredictable behavior, the data is truncated to fall within the range expected from the display hardware.

Ein Gerät beispielsweise, das in der Lage ist, 256 Inten­ sitätswerte darzustellen, würde 8-Bit-(1-Byte-)Pixel auf­ weisen. Eine Modifikation des Bildes, wie z. B. eine Kanten­ verbesserung, die mit einer normalen 4-Byte-Ganzzahlarith­ metik durchgeführt wird, würde in einigen Werten resultie­ ren, die kleiner als 0 oder größer als 255 sind.For example, a device capable of 256 integers representing values would be 8-bit (1-byte) pixels point. A modification of the picture, such as. B. an edge  improvement with a normal 4-byte integer arithmetic metik performed would result in some values that are less than 0 or greater than 255.

Aus Darstellungsgründen werden die folgenden 64 Bit betrach­ tet:For reasons of illustration, the following 64 bits are considered tet:

Beispiel 1example 1

Diese 64 Bit stellen beispielhaft dar, was in einer Spei­ cherposition in dem Speicher 107 gespeichert werden kann. Bei diesem Beispiel enthält jedes Halbwort (16 Bit) den nu­ merischen Wert für die Lichtintensität, die durch ein Pixel angezeigt werden soll. Jeder Pixelwert wird in einem Byte gehalten, während das andere Byte Nullen enthält. Bestimmte arithmetische Operationen, beispielsweise die, die Bildkom­ pressionsprotokollen, wie z. B. MPEG, zugeordnet sind, können bewirken, daß die Pixelwerte über die 8 Bit des niederstwer­ tigen Bytes seines Halbworts überlaufen. Eine arithmetische Operation (oder eine Serie von Operationen) kann beispiels­ weise das folgende Ergebnis bewirken:These 64 bits exemplify what can be stored in a storage position in memory 107 . In this example, each half-word (16 bits) contains the value for the light intensity to be displayed by a pixel. Each pixel value is held in one byte while the other byte contains zeros. Certain arithmetic operations, such as those that compression image protocols such. B. MPEG, can cause the pixel values to overflow the 8 bits of the least significant byte of its half-word. For example, an arithmetic operation (or a series of operations) can do the following:

Beispiel 2Example 2

Wenn der dynamische Bereich für Pixelwerte eines Geräts der Bereich von 0 bis 255 ist, werden die Werte in den Halbwor­ ten abgeschnitten, um mit dem annehmbaren Bereich überein­ zustimmen, um die unvorhersagbaren Ausgaben von diesen Halb­ worten, die kleiner als 0 und größer als 255 sind, zu ver­ hindern. Das Abschneiden wird derart durchgeführt, daß ne­ gative Werte durch 0 (00000000) und die, die größer als 255 sind, durch 255 (11111111) ersetzt werden.If the dynamic range for a device's pixel values is the Range is from 0 to 255, the values in the halfword clipped to match the acceptable range agree to the unpredictable spending of these half words that are less than 0 and greater than 255 must be ver prevent. The cutting is carried out such that ne negative values through 0 (00000000) and those greater than 255 are replaced by 255 (11111111).

Es existieren binäre Datenformate zum Darstellen vorzeichen­ behafteter und vorzeichenloser Ganzzahlen. Das Zweierkomple­ mentformat ist die gebräuchlichste Darstellung für vorzei­ chenbehaftete Ganzzahlen und wird in dieser Beschreibung der bevorzugten Ausführungsbeispiele der Erfindung verwendet. Dies ermöglicht drei verschiedene Arten des Abschneidens ab­ hängig von dem Eingabe- und dem Ausgabetyp, nämlich das Ab­ schneiden einer vorzeichenlosen Eingabe zu einer vorzeichen­ losen Ausgabe, das Abschneiden einer vorzeichenbehafteten Eingabe zu einer vorzeichenlosen Ausgabe und das Abschneiden einer vorzeichenbehafteten Eingabe zu einer vorzeichenbehaf­ teten Ausgabe. Eine vierte Möglichkeit besteht darin, eine vorzeichenlose Eingabe zu einer vorzeichenbehafteten Ausgabe abzuschneiden. Gemäß dem bevorzugten Ausführungsbeispiel ist ein solches Abschneiden jedoch nicht erlaubt, wobei ein Ver­ such, ein solches Abschneiden durchzuführen, im Zurückgeben der Eingabedaten als das Ergebnis resultiert. Natürlich könnten alternative Ausführungsbeispiele ebenfalls das Ab­ schneiden einer vorzeichenlosen Eingabe zu einer vorzeichen­ behafteten Ausgabe erlauben.Binary data formats exist for the sign  afflicted and unsigned integers. The complex of two mentformat is the most common representation for vorzei integers and is used in this description of the preferred embodiments of the invention used. This enables three different types of clipping dependent on the input and the output type, namely the Ab intersect an unsigned input to a sign loose edition, cutting off a signed Input to unsigned output and clipping a signed entry to a signed entry issue. A fourth option is one unsigned input for a signed output to cut off. According to the preferred embodiment such a clipping is not allowed, however, a ver seek to perform such a truncation in return of the input data results as the result. Naturally alternative embodiments could also the Ab intersect an unsigned input to a sign Allow afflicted output.

Ein Befehl CLIP (CLIP = Abschneiden) leitet den Prozessor 100 an, um Ganzzahlwerte, die in einem Register in der Re­ gisterdatei 101 gespeichert sind, abzuschneiden. Der Befehl CLIP besitzt das folgende Format:A CLIP command instructs processor 100 to cut integer values stored in a register in register file 101 . The CLIP command has the following format:

CLIP ,xyz Quelle, Maske, ZielCLIP, xyz source, mask, target

x gibt die Größe der Eingabedaten, d. h. D (D = Doppelwort) für 64 Bit, W (W = Wort) für 32 Bit, H (H = Halbwort) für 16 Bit und B (B = Byte) für 8 Bit an. y gibt an, ob die Eingabe vorzeichenlos (U; U = Unsigned) oder vorzeichenbehaftet (S; S = Signed) ist. Die Flag z gibt an, ob die Ausgabe zu einer vorzeichenlosen (U) oder zu einer vorzeichenbehafteten (S) Ganzzahl abgeschnitten werden soll. Die Maske erlaubt es, daß die Ganzzahlen, die in dem Quellenregister gespeichert sind, zu einem beliebigen Bereich abgeschnitten werden. Fer­ ner erlaubt die Maske das parallele Abschneiden aller Pixel­ werte, die in dem Register gespeichert sind. Bei einem Aus­ führungsbeispiel beträgt y = 0 für eine vorzeichenlose Ein­ gabe und y = 1 für eine vorzeichenbehaftete Eingabe. Auf ähnliche Weise beträgt z = 0 für eine vorzeichenlose Ausgabe und z = 1 für eine vorzeichenbehaftete Ausgabe.x gives the size of the input data, i. H. D (D = double word) for 64 bit, W (W = word) for 32 bit, H (H = half word) for 16 Bit and B (B = byte) for 8 bits. y indicates whether the input unsigned (U; U = Unsigned) or signed (S; S = Signed). The flag z indicates whether the output is at a unsigned (U) or signed (S) Integer to be truncated. The mask allows that the integers stored in the source register are cut off to any area. Fer The mask also allows all pixels to be cut off in parallel values that are stored in the register. With an out  example is y = 0 for an unsigned on and y = 1 for a signed entry. On similarly, z = 0 for unsigned output and z = 1 for signed output.

Die Maske enthält eine 1 für jedes Bit, das sich außerhalb des Bereichs befindet, und eine 0 für jedes Bit, das sich innerhalb des Bereichs befindet.The mask contains a 1 for each bit that is outside of the range, and a 0 for each bit that is located within the area.

Fig. 2 ist ein Blockdiagramm bestimmter Komponenten des Mi­ kroprozessors 100. Es zeigt die Baublöcke der Abschneide­ schaltung 100 und das Daten-, das Masken- und das Ausgabe­ register. Der Mikroprozessor 100 enthält ein Maskenregister 201, ein Datenregister 203 und ein Ausgaberegister 205. Je­ des Register 201 bis 205 ist in der Registerdatei 101 ent­ halten. Der Befehl CLIP zeigt dem Prozessor 100, welches Re­ gister in der Registerdatei er als Daten-, Masken- bzw. Aus­ gaberegister verwenden soll. Fig. 2 is a block diagram of certain components of the Mi kroprozessors 100th It shows the building blocks of the clipping circuit 100 and the data, mask and output registers. The microprocessor 100 contains a mask register 201 , a data register 203 and an output register 205 . Each of the registers 201 to 205 is contained in the register file 101 . The command CLIP shows the processor 100 which register in the register file it should use as a data, mask or output register.

Der Mikroprozessor 100 enthält ferner die Abschneidelogik 105. Die Abschneidelogik 105 ist mit jedem Register 201 bis 205 verbunden.Microprocessor 100 also includes clipping logic 105 . The cut-off logic 105 is connected to each tab 201 to 205.

Die Abschneidelogik 105 ist aus einem Satz wiederholter Schaltungsanordnungen aufgebaut. Die Abschneidelogik 105 enthält eine Doppelwort-Logikschaltung 207, zwei Wort-Logik­ schaltungen 209a-b, vier Halbwort-Logikschaltungen 211a-d, acht Byte-Logikschaltungen 213a-h und 64 Bit-Logikschaltun­ gen 215 (nicht einzeln benannt). Die Wort-Logikschaltungen 209 sind zueinander identisch, die Halbwort-Logikschaltungen 211 sind zueinander identisch, die Byte-Logikschaltungen 213 sind zueinander identisch und die Bit-Logikschaltungen 215 sind zueinander identisch. Was die verschiedenen wiederhol­ ten Schaltungen voneinander unterscheidet, besteht darin, wie sie mit anderen Schaltungskomponenten verbunden sind. Diese Verbindungen werden nachfolgend in Verbindung mit den Fig. 3-5 erörtert. Jedes Bit des Maskenregisters 201 und des Datenregisters 203 ist als Eingabe mit einer ent­ sprechenden Bit-Logik 215 verbunden. Auf ähnliche Weise ist jedes Bit des Ausgaberegisters als Ausgabe mit der entspre­ chenden Bit-Logik 215 verbunden.The clipping logic 105 is constructed from a set of repeated circuitry. The clipping logic 105 includes a double-word logic circuit 207 , two word logic circuits 209 a-b, four half-word logic circuits 211 a-d, eight byte logic circuits 213 a-h, and 64-bit logic circuits 215 (not individually named). The word logic circuits 209 are identical to one another, the half-word logic circuits 211 are identical to one another, the byte logic circuits 213 are identical to one another and the bit logic circuits 215 are identical to one another. What distinguishes the various repeated circuits is how they are connected to other circuit components. These connections are discussed below in connection with FIGS. 3-5. Each bit of the mask register 201 and the data register 203 is connected as input to a corresponding bit logic 215 . Similarly, each bit of the output register is connected as output to the corresponding bit logic 215 .

Die parallelen Ganzzahlen-Eingabedaten sind in einen oder mehrere Eingabeblöcke aufgeteilt. Jeder Eingabeblock könnte beispielsweise ein Halbwort sein, wobei in diesem Fall unter der Voraussetzung von 64-Bit-breiten Eingabedaten vier Ein­ gabeblöcke existieren würden, von denen jeder 16 Bit breit ist.The parallel integer input data is in one or split up several input blocks. Any input block could for example, a halfword, in which case under assuming four-bit input data is four on would exist, each 16 bits wide is.

Fig. 3 ist ein Blockdiagramm der Doppelwort-Logik 207. Die­ se Figur zeigt die Schaltungsanordnung zum Bestimmen des Werts des Vorzeichenbits des Eingabedatenblocks, das jedem Byte der Ausgabedaten entspricht. Das vorderste Bit jedes Bytes in dem Datenregister ist mit einem oder mehreren Mul­ tiplexern (MUX) 301a-301h verbunden. Das Bit 63 ist bei­ spielsweise mit allen Multiplexern verbunden, während das Bit 7 lediglich mit dem Multiplexer 301a verbunden ist. Je­ der Multiplexer wird ausgewählt, indem die BHWD-Steuerungs­ leitungen verwendet werden (BHWD = Byte Half-word Word Double-Word = Byte Halbwort Wort Doppelwort). Die BHWD- Steuerungsleitungen sind durch den Wert des Feldes X des Befehls CLIP eingestellt. Ausgaben DB0-DB7 sind Eingaben in die Logik 105 in Fig. 2 und insbesondere in einen Eingang VORZEICHEN in der Logik 215 in Fig. 6. Die Ausgaben DB0-DB7 steuern diese Vorzeicheneingaben auf B0 bis B7 in der Logik 213 in Fig. 2. Fig. 3 is a block diagram of the double-word logic 207th This figure shows the circuit arrangement for determining the value of the sign bit of the input data block, which corresponds to each byte of the output data. The foremost bit of each byte in the data register is connected to one or more multiplexers (MUX) 301 a- 301 h. Bit 63 is connected to all multiplexers, for example, while bit 7 is only connected to multiplexer 301 a. The multiplexer is selected using the BHWD control lines (BHWD = Byte Half-word Word Double-Word = Byte Halbwort Wort Doppelwort). The BHWD control lines are set by the value of field X of the CLIP command. Outputs DB0-DB7 are inputs to logic 105 in FIG. 2, and in particular to an input SIGN in logic 215 in FIG. 6. Outputs DB0-DB7 control these sign inputs to B0 to B7 in logic 213 in FIG. 2.

Die folgende Tabelle zeigt für jeden Multiplexer, von wel­ chem Bit des Datenregisters 203 die Ausgabe dieses Multi­ plexers abhängig von dem Wert der BHWD-Steuerungsleitungen genommen wird. The following table shows for each multiplexer from which bit of the data register 203 the output of this multiplexer is taken depending on the value of the BHWD control lines.

Tabelle 1 Table 1

Die folgende Tabelle enthält einen Pseudocode für jeden Typ einer Abschneideoperation. Der Pseudocode bezieht sich auf jedes Byte in dem Datenregister 203. The following table contains a pseudo code for each type of clipping operation. The pseudocode refers to each byte in the data register 203 .

Tabelle 2 Table 2

Bei diesem Ausführungsbeispiel, bei dem der Typ der Eingabe und der Ausgabe von dem Abschneidebefehl-Operationscode er­ halten wird, sind keine Datentypinformationen in der Maske codiert. Daher hängt die Maske nicht von dem Datentyp der Eingaben und Ausgaben ab. Die Maske, die verwendet wird, um beispielsweise entweder vorzeichenbehaftete oder vorzeichen­ lose Halbwort-(16-Bit-)Ganzzahleingaben zu entweder einer vorzeichenbehafteten oder vorzeichenlosen Byte-(8-Bit-) Ganzzahlausgabe abzuschneiden, ist nachfolgend gezeigt:In this embodiment, the type of input and the output from the cut command operation code  there is no data type information in the mask coded. Therefore, the mask does not depend on the data type of the Inputs and expenses. The mask that is used to for example either signed or signed loose half-word (16-bit) integer inputs to either one signed or unsigned byte (8-bit) Cutting off integer output is shown below:

Beispiel 3Example 3

Wenn die als das Bitmuster von Beispiel 3 gezeigte Maske auf das vorzeichenlose Eingabewort angewendet wird, das als Bit­ muster (2) gezeigt ist, wird das folgende vorzeichenlose Ganzzahlergebnis erhalten (die erste Zeile ist das Eingabe­ bitmuster von Beispiel 2, die zweite Zeile ist das Masken­ bitmuster von Beispiel 3, und die dritte Zeile ist das Er­ gebnis):When the mask shown as the bit pattern of Example 3 is on the unsigned input word is applied as a bit pattern (2) is shown, the following is unsigned Get integer result (the first line is the input bit pattern from example 2, the second line is the mask bit pattern of Example 3, and the third line is the Er result):

Beispiel 4Example 4

Wenn die als das Bitmuster von Beispiel 3 gezeigte Maske auf das vorzeichenbehaftete Eingabewort, das als Bitmuster (2) gezeigt ist, angewendet wird, wird das folgende vorzeichen­ behaftete Ganzzahlergebnis erhalten (die erste Zeile ist das Eingabebitmuster von Beispiel 2, die zweite Zeile ist das Maskenbitmuster von Beispiel 3 und die dritte Zeile ist das Ergebnis):When the mask shown as the bit pattern of Example 3 is on the signed input word, which as a bit pattern (2) is shown, the following sign is used Obtained integer result (the first line is that Input bit pattern from example 2, the second line is that Mask bit pattern from Example 3 and the third line is that Result):

Beispiel 5Example 5

Wenn die Maske, die als das Bitmuster von Beispiel 3 gezeigt ist, auf das vorzeichenbehaftete Eingabewort, das als Bitmu­ ster (2) gezeigt ist, angewendet wird, wird das folgende vorzeichenlose Ganzzahlergebnis erhalten (die erste Zeile ist das Eingabebitmuster von Beispiel 2, die zweite Zeile ist das Maskenbitmuster von Beispiel 3 und die dritte Zeile ist das Ergebnis):If the mask shown as the bit pattern of Example 3 is to the signed input word, which as Bitmu ster (2) is used, the following will be used Get unsigned integer result (the first line is the input bit pattern of Example 2, the second line is the mask bit pattern of Example 3 and the third line is the result):

Beispiel 6Example 6

Fig. 4 ist ein Schaltbild einer der Halbwort-Logikschal­ tungen, nämlich der Halbwort-Logikschaltung 211d. Die Halb­ wort-Logik 211d enthält die zwei Byte-Logikschaltungen 213g und 213h. Die Byte-Logikschaltung 213h entspricht den Bits 0 bis 7 des Daten-, des Masken- und des Ausgabeworts. Auf ähn­ liche Weise entspricht die Byte-Logikschaltung 213g den Bits 8 bis 15. Jede der Byte-Logikschaltungen 213 enthält Bit-Lo­ gikschaltungen 215 für jedes Bit, das ihr entspricht. Fig. 4 is a circuit diagram of one of the half-word logic circuits, namely the half-word logic circuit 211 d. The half word logic 211 d contains the two byte logic circuits 213 g and 213 h. The byte logic circuit 213h corresponds to bits 0 to 7 of the data, mask and output word. In similarity Liche, the byte logic circuit corresponds to 213 g bits 8 to 15 °. Each of the byte logic circuits 213 includes bit logic circuits 215 for each bit that corresponds to it.

Das Daten- und das Maskenregister sind mit der Abschneidelo­ gik derart verbunden, daß die Bit in dem Daten- und in dem Maskenregister, die einander entsprechen, in die Byte-Logik­ schaltungen 213 eingegeben werden, der diese Bit entspre­ chen. Die Byte-Logikschaltungen enthalten alle acht XOR-Gat­ ter 401 (XOR = EXKLUSIV-ODER-Verknüpfung), wobei jede einem Datenbit entspricht. Jedes der XOR-Gatter 401 weist zwei Eingaben auf, nämlich das Datenbit, dem es entspricht, und das Vorzeichenbit, welches für das entsprechende Byte be­ stimmt wird, wie es in Fig. 3 gezeigt ist.The data and mask registers are connected to the clipping logic such that the bits in the data and mask registers which correspond to one another are input to the byte logic circuits 213 to which these bits correspond. The byte logic circuits contain all eight XOR gates 401 (XOR = EXCLUSIVE-OR operation), each corresponding to a data bit. Each of the XOR gates 401 has two inputs, namely the data bit to which it corresponds and the sign bit which is determined for the corresponding byte, as shown in FIG. 3.

Die Ausgaben von den XOR-Gattern 401 werden bitweise mit ihren entsprechenden Maskenbit in AND-Gattern 403 (AND = UND-Verknüpfung) mittels der logischen UND-Verknüpfung ver­ knüpft. Die Ausgaben dieser UND-Verknüpfungsoperation werden zusammen mit der Ausgabe aus einem Größenauswahlgatter 407 mittels der ODER-Verknüpfung verknüpft (in einem Gatter 405). Die Ausgabe des OR-Gatters (OR = ODER-Verknüpfung) ist das Signal CLIP des Pseudocodes von Tabelle 2. Das Signal CLIP zeigt an, ob die Daten abgeschnitten werden müssen, oder ob sie zu den Ausgaberegistern 205 weitergeleitet wer­ den können. Das Signal CLIP wird in jede der Bit-Logikschal­ tungen 215 eingegeben.The outputs from the XOR gates 401 are linked bit by bit with their corresponding mask bit in AND gates 403 (AND = AND link) by means of the logical AND link. The outputs of this AND operation together with the output from a size selection gate 407 are ORed (in a gate 405 ). The output of the OR gate (OR = OR operation) is the signal CLIP of the pseudo code from table 2. The signal CLIP indicates whether the data must be cut off or whether it can be passed on to the output registers 205 . The CLIP signal is input to each of the bit logic circuits 215 .

Jede Byte-Logikschaltung 213 mit Ausnahme der vordersten Byte-Logikschaltung 213a weist ein Größenauswahlgatter 407 auf. Jedes Größenauswahlgatter 407 ist ein AND-Gatter. Eine Eingabe in jedes Größenauswahlgatter 407 ist der Wert des Signals CLIP für die nächste höhere Byte-Logikschaltung 213. Jedes Größenauswahlgatter 407 empfängt ferner als Eingabe ein Signal 409, das anzeigt, ob das nächste höhere Byte ein Teil derselben Eingabedaten wie das vorliegende Byte ist. Das Signal 409 hängt von der Größe des Eingabeblocks ab und wo das spezielle fragliche Byte in das Eingaberegister 203 paßt. Fig. 5 zeigt die Eingaben in die verschiedenen Größenauswahlgatter 407 für die acht Byte in einem 64-Bit- Register. Für jede der Byte-Logikschaltungen 213b, 213d, 213f und 213h weist das Signal 409 den Wert "H oder W oder D" auf, wobei H = 1 ist, wenn das Eingaberegister in Halb­ wort-Grenzen aufgeteilt ist, W = 1 ist, wenn das Eingabe­ register in Wort-Grenzen aufgeteilt ist, und D = 1 ist, wenn das Eingaberegister in Doppelwort-Grenzen aufgeteilt ist (d. h., daß das Register nur eine Eingabe aufweist). Wenn H, W und D alle 0 sind, ist das Eingaberegister in Byte-Grenzen aufgeteilt. Für jede der Byte-Logikschaltungen 213c, 213e und 213g ist das Signal 409 "W oder D".Each byte logic circuit 213 with the exception of the foremost byte logic circuit 213 a has a size selection gate 407 . Each size selection gate 407 is an AND gate. An input to each size selection gate 407 is the value of the CLIP signal for the next higher byte logic circuit 213 . Each size selection gate 407 also receives as input a signal 409 indicating whether the next higher byte is part of the same input data as the present byte. The signal 409 depends on the size of the input block and where the particular byte in question fits into the input register 203 . Figure 5 shows the inputs to the various size selection gates 407 for the eight bytes in a 64-bit register. For each of the byte logic circuits 213b , 213d , 213f and 213h , the signal 409 has the value "H or W or D", where H = 1 if the input register is divided into half-word boundaries, W = 1 if the input register is divided into word boundaries and D = 1 if the input register is divided into double word boundaries (ie the register has only one input). If H, W and D are all 0, the input register is divided into byte boundaries. For each of the byte logic circuits 213c , 213e and 213g , the signal 409 is "W or D".

Die nachfolgende Tabelle 3 ist eine Wahrheitstabelle für die Operation der Bit-Logikschaltungen 215 in Fig. 6. Tabelle 3 ist in drei Teiltabellen unterteilt, wobei Tabelle 3a den Fall vorzeichenbehaftete Eingabe/vorzeichenbehaftete Ausga­ be, Tabelle 3b den Fall vorzeichenbehaftete Eingabe/vorzei­ chenlose Ausgabe und Tabelle 3c den Fall vorzeichenlose Ein­ gabe/vorzeichenlose Ausgabe beschreibt.Table 3 below is a truth table for the operation of bit logic circuits 215 in Figure 6. Table 3 is divided into three sub-tables, Table 3a the signed input / output case, Table 3b the signed input / unsigned output case and Table 3c describes the case of unsigned input / unsigned output.

Tabelle 3a Table 3a

Wahrheitstabelle für die Bit-Logik 215 für den Fall vorzeichenbehaftete Eingabe/vorzeichenbe­ haftete Ausgabe Truth table for bit logic 215 for signed input / signed output

Tabelle 3b Table 3b

Wahrheitstabelle für die Bit-Logik 215 für den Fall vorzeichenbehaftete Eingabe/vorzeichenlose Ausgabe Truth table for bit logic 215 for signed / unsigned case

Tabelle 3c Table 3c

Wahrheitstabelle für die Bit-Logik 215 für den Fall vorzeichenlose Eingabe/vorzeichenlose Ausgabe Truth table for bit logic 215 for the unsigned input / unsigned case

Fig. 6 ist ein Schaltbild der Bit-Logikschaltungen 215, die den Wahrheitstabellen von Tabelle 3 entsprechen. Fig. 6 is a diagram of the bit logic circuits 215, which correspond to the truth table of Table 3.

Bei dem in Verbindung mit den Fig. 1 bis 6 erörterten Ausführungsbeispiel wird der Typ des Abschneidens durch den Befehl selbst mittels zweier Operationscode-Vervollständi­ gungsbit y und z angezeigt und zu der Abschneideschaltung als Signale EIN_TYP und AUS_TYP geleitet.In the embodiment discussed in connection with FIGS. 1 through 6, the type of clipping by the command itself is indicated by two opcode completion bits y and z and passed to the clipping circuit as signals ON_TYPE and OFF_TYPE.

Es existieren drei alternative Ausführungsbeispiele, die Bit in dem Maskenregister verwenden, um bestimmte oder alle An­ forderungen nach den Operationscode-Vervollständigungsbit y (vorzeichenbehaftete/vorzeichenlose Eingabe) und/oder z (vorzeichenbehaftete/vorzeichenlose Ausgabe) zu entfernen.There are three alternative embodiments, the bit in the mask register to use certain or all of the To requests for the opcode completion bit y (signed / unsigned entry) and / or z (signed / unsigned edition) to remove.

Die drei alternativen Ausführungsbeispiele sind in Tabelle 4 zusammengefaßt. The three alternative embodiments are in Table 4 summarized.  

Tabelle 4 Table 4

Verwendung der Masken- und Vervollständiger-Bits, um den Datentyp der Eingabe und Ausgabe bei al­ ternativen Ausführungsbeispielen anzuzeigen Using the mask and completion bits to indicate the data type of input and output in alternative embodiments

Bei dem zweiten Ausführungsbeispiel wird das höchstwertige Bit der Maske, d. h. Bit A, verwendet, um anzuzeigen, ob die Eingabedaten vorzeichenbehaftet oder vorzeichenlos sind (ein Operationscode-Vervollständiger z enthält die Ausgabedaten­ typ-Auswahl). Dies kann durchgeführt werden, da kein Grund besteht, eine vorzeichenbehaftete 16-Bit-Eingabe zu einer vorzeichenbehafteten 16-Bit-Ausgabe abzuschneiden, wobei bei vorzeichenbehafteten 16-Bit-Eingabedaten das sechzehnte Bit das Vorzeichenbit sein muß und daher niemals wegmaskiert werden würde. Bei dem nachfolgend beschriebenen Ausführungs­ beispiel beträgt A für vorzeichenbehaftete Eingabedaten 0 und für vorzeichenlose Eingabedaten 1.In the second embodiment, this becomes the most significant Bit of the mask, d. H. Bit A, used to indicate whether the Input data is signed or unsigned (a Opcode completioner z contains the output data type selection). This can be done as no reason there is a signed 16-bit input to one truncated signed 16-bit output, where at signed 16-bit input data is the sixteenth bit the sign bit must be and therefore never masked away would be. In the embodiment described below  For example, A is 0 for signed input data and for unsigned input data 1.

Bei dem dritten Ausführungsbeispiel wird das höchstwertige Bit in der Maske, d. h. Bit A, verwendet, um anzuzeigen, ob die Eingabedaten vorzeichenbehaftet oder vorzeichenlos sind. Wenn die Eingabedaten vorzeichenbehaftet sind, teilt das Maskenbit B der Hardware-Zustandsmaschine mit, ob die Aus­ gabe zu einem vorzeichenbehafteten oder vorzeichenlosen Wert abgeschnitten werden soll, wodurch der Bedarf nach dem Ope­ rationscode-Vervollständiger z entfällt wird. Wenn B gleich 0 ist, schneidet die Hardware die Ausgabe zu vorzeichenbe­ hafteten Ganzzahlen ab, und wenn B gleich 1 ist, schneidet die Hardware zu vorzeichenlosen Ganzzahlen ab. Es ist mög­ lich, das Bit B zu verwenden, um den Ausgabedatentyp zu co­ dieren, da, wenn auf eine vorzeichenbehaftete 15-Bit-Ausgabe abgeschnitten wird, das 15. Bit, welches das Bit ist, das sich unter der Steuerung des Maskenbits B befindet, das Vor­ zeichenbit ist und somit nicht abgeschnitten werden braucht.In the third embodiment, this becomes the most significant Bit in the mask, d. H. Bit A, used to indicate whether the input data is signed or unsigned. If the input data is signed, that divides Mask bit B of the hardware state machine with whether the off give a signed or unsigned value to be cut off, reducing the need for the ope ration code completion z is omitted. If B is the same 0, the hardware cuts the output to sign peeled off integers, and if B is 1 intersects the hardware to unsigned integers. It is possible to use bit B to co-ordinate the output data type if there is a signed 15 bit output is cut off the 15th bit, which is the bit that is under the control of mask bit B, the front is character bit and therefore does not need to be cut off.

Bei dem vierten Ausführungsbeispiel steuert das Operations­ code-Vervollständigungsbit y den Eingabedatentyp und das Maskenbit A steuert die Ausgabe. Wenn A gleich 0 ist, schneidet die Hardware zu einer vorzeichenbehafteten Ausgabe ab, und wenn A gleich 1 ist, schneidet die Hardware zu einer vorzeichenlosen Ausgabe ab. Die Verwendung des Operations­ code-Vervollständigers y bei der Eingabespezifikation lie­ fert der Hardware ein früheres Wissen über den Eingabetyp, um die Zeitgebung zu erleichtern.In the fourth embodiment, this controls operations code completion bit y the input data type and that Mask bit A controls the output. If A is 0, cuts the hardware to a signed output and if A is 1, the hardware cuts to one unsigned output. The use of the operation code completer y in the input specification lie provides the hardware with prior knowledge of the input type, to make the timing easier.

Tabelle 4a enthält Beispiele für das vierte Ausführungsbei­ spiel und den Fall, bei dem die Eingabe ein Halbwort ist, für den Fall einer vorzeichenbehafteten Ausgabe. Table 4a contains examples of the fourth embodiment game and the case where the input is a halfword, for the case of a signed edition.  

Tabelle 4a Table 4a

Beispiele des Abschneidens unter Verwendung ei­ nes Vervollständigungsbits und der vorzeichen­ behafteten Ausgabe Examples of truncation using a completion bit and signed output

Das Vorzeichenbit der Maske gibt an, ob die Eingabe als vor­ zeichenbehaftet oder vorzeichenlos behandelt wird. Der fol­ gende Pseudocode beschreibt die Abschneideoperation:The sign bit of the mask indicates whether the input is as before treated with signs or unsigned. The fol The pseudocode describes the clipping operation:

Tabelle 4b Table 4b

Pseudocode zum Abschneiden zu einer vorzeichen­ behafteten Ausgabe unter Verwendung eines Vervollständigungsbits Pseudo code to truncate to signed output using a completion bit

Das folgende Beispiel stellt das Abschneiden für den vorzei­ chenlosen Fall unter Verwendung eines Vervollständigungsbits dar:The following example shows the clipping for the front case without using a completion bit represents:

Tabelle 4c Table 4c

Abschneiden zu einem vorzeichenlosen Ergebnis unter Verwendung eines Vervollständigungsbits Truncating to an unsigned result using a completion bit

Der entsprechende Pseudocode ist nachfolgend gezeigt:The corresponding pseudocode is shown below:

Tabelle 4d Table 4d

Pseudocode zum Abschneiden zu einem vorzeichen­ losen Ergebnis unter Verwendung eines Vervoll­ ständigungsbits Pseudocode to truncate to an unsigned result using a completion bit

Das dritte Ausführungsbeispiel verwendet die Tatsache, daß das führende Bit der Maske für den vorzeichenlosen Fall im­ mer 1 ist. Dies ist aufgrund der Tatsache der Fall, daß das Abschneiden zu der vollen Breite der Eingabedaten nicht not­ wendig ist, z. B. für Halbworte wird das Abschneiden auf den vollen 16-Bit-Bereich niemals durchgeführt. Auf ähnliche Weise macht es für eine vorzeichenbehaftete Ausgabe keinen Sinn, zu einem vorzeichenbehafteten 15-Bit-Bereich abzu­ schneiden. Daher ist es möglich, die zwei führenden Bit der Maske zu verwenden, um die Fälle zu unterscheiden.The third embodiment uses the fact that the leading bit of the unsigned mask in is 1. This is due to the fact that the Truncation to the full width of the input data is not necessary is agile, e.g. B. for halfwords, the clipping on the full 16-bit area never performed. Similar ones It does not make any wise for signed output  It makes sense to move to a signed 15-bit area to cut. It is therefore possible to use the two leading bits of the Use mask to differentiate the cases.

Die folgenden Halbwort-Beispiele veranschaulichen das dritte Ausführungsbeispiel:The following halfword examples illustrate the third Design example:

Tabelle 5 Table 5

Beispiele des Abschneidens, wobei der Abschneide­ typ in den ersten beiden Bit der Maske codiert ist Examples of clipping, where the clipping type is encoded in the first two bits of the mask

Der folgende Pseudocode zeigt die Funktionsweise der Ab­ schneideoperation, wobei der Typ des Abschneidens in den ersten beiden Bit der Maske codiert ist: The following pseudocode shows how the Ab works cutting operation, the type of cutting in the the first two bits of the mask is coded:  

Tabelle 5b Table 5b

Pseudocode zum Abschneiden, bei dem der Typ des Abschneidens in den ersten beiden Bit der Maske codiert ist Clipping pseudo code in which the type of clipping is encoded in the first two bits of the mask

Die Abschneidelogik 105 ist betreibbar, um eines der drei alternativen Ausführungsbeispiele zu verwenden.The clipping logic 105 is operable to use one of the three alternative embodiments.

Ein alternatives Ausführungsbeispiel läßt Ganzzahlen mit variabler Breite zu. Bei dem alternativen Ausführungsbei­ spiel kann jede Ganzzahl, die abgeschnitten werden soll, eine andere Breite als jede andere Ganzzahl aufweisen, die in einem gemeinsamen Register gespeichert ist, wobei jede Ganzzahl zu einem anderen Bereich abgeschnitten werden kann.An alternative embodiment allows integers variable width too. In the alternative execution case any integer to be truncated have a different width than any other integer that  is stored in a common register, each Integer can be truncated to another range.

Als Beispiel enthält das folgende 64-Bit-Bitmuster sechs Eingabeelemente, von denen jedes 10 Bit breit ist:As an example, the following 64-bit bit pattern contains six Input elements, each 10 bits wide:

Beispiel 7Example 7

Die Zahlen 1 und 6 sind positive Zahlen, die in den Aus­ gabebereich passen. Die Zahlen 2 und 5 sind positive Zahlen, die nicht in den Ausgabebereich passen. Die Zahl 4 ist eine negative Zahl, die in den Ausgabebereich paßt und die Zahl 3 ist eine negative Zahl, die nicht in den vorzeichenbehafte­ ten Ausgabebereich paßt. Der Pseudocode des ersten Ausfüh­ rungsbeispiels wird zum Abschneiden verwendet. Das folgende Bitmuster wird verwendet, um sechs 10-Bit-Zahlen zu einem vorzeichenlosen 8-Bit-Bereich abzuschneiden:The numbers 1 and 6 are positive numbers in the out range. The numbers 2 and 5 are positive numbers, that don't fit in the output area. The number 4 is one negative number that fits in the output range and the number 3 is a negative number that is not in the signed th output area fits. The pseudocode of the first execution Example is used for clipping. The following Bit pattern is used to make six 10-bit numbers into one Truncate unsigned 8-bit range:

0000 1100000000 1100000000 1100000000 1100000000 1100000000 11000000000000 1100000000 1100000000 1100000000 1100000000 1100000000 1100000000

Beispiel 8Example 8

Der Pseudocode von Tabelle 1 wird verwendet, um die Ab­ schneideoperation durchzuführen. Das Anwenden des Bitmusters von Beispiel 8 auf das Bitmuster von Beispiel 7 unter Ver­ wendung des Verfahrens des Pseudocodes von Tabelle 1 resul­ tiert in der folgenden Ausgabe:The pseudocode of Table 1 is used to convert Ab perform cutting operation. Applying the bit pattern from Example 8 to the bit pattern from Example 7 under Ver application of the procedure of the pseudocode of Table 1 resul in the following edition:

0000 0000011010 0011111111 0000000000 0000000000 0011111111 00101010010000 0000011010 0011111111 0000000000 0000000000 0011111111 0010101001

Beispiel 9Example 9

Um eine Eingabe zu einem vorzeichenbehafteten 8-Bit-Bereich abzuschneiden, wird das folgende Masken-Bitmuster angewen­ det:An input to a signed 8-bit area the following mask bit pattern is used det:

0000 1110000000 1110000000 1110000000 1110000000 1110000000 11100000000000 1110000000 1110000000 1110000000 1110000000 1110000000 1110000000

Beispiel 10Example 10

Das Anwenden der Maske von Beispiel 10 auf die Eingabe von Beispiel 7 unter Verwendung des Pseudocodes von Tabelle 1 für eine vorzeichenbehaftete Ausgabe erzeugt das folgende Ergebnis:Applying the mask from Example 10 to the input of Example 7 using the pseudocode of Table 1 for signed output produces the following Result:

0000 0000011010 0001111111 1110111000 1110000000 0011111111 00101010010000 0000011010 0001111111 1110111000 1110000000 0011111111 0010101001

Der Abschneidebefehl für das vorzeichenlose und das vorzei­ chenbehaftete Abschneiden von Ganzzahlen des alternativen Ausführungsbeispiels lautet folgendermaßen:The clipping command for the unsigned and the unsigned truncated integer truncation of the alternative Exemplary embodiment reads as follows:

CLIP ,t Quelle, Maske, Ziel, wobei t entweder U für den vorzeichenlosen Fall oder S für den vorzeichenbehafteten Fall ist.CLIP, t source, mask, target, where t is either U for the unsigned case or S for the signed case.

Es wird angemerkt, daß der Befehl keine Angabe bezüglich der Eingabedatengröße enthält, oder ob eine parallele Ausführung verwendet werden soll. Die Hardware leitet diese Informati­ onen automatisch von der Maske ab. Es wird angenommen, daß die Daten in dem Register rechts ausgerichtet sind. Die er­ ste 1 in der Maske gibt die Position des Vorzeichenbits des ersten Datenelements an. Die erste 0 gibt die Position des vordersten Bits in dem Ausgabefeld an. Die nächste 1 gibt das Vorzeichen der nächsten Zahl an. Die nächste 0 gibt das vorderste Bit in dem nächsten Ausgabefeld an, usw., bis das Ende des Maskenworts erreicht ist.It is noted that the command does not specify the Contains input data size, or whether a parallel execution should be used. The hardware directs this information onen automatically from the mask. It is believed that the data in the register are aligned on the right. Which he Ste 1 in the mask gives the position of the sign bit of the first data element. The first 0 indicates the position of the foremost bits in the output field. The next 1 there the sign of the next number. The next 0 gives that first bit in the next output field, etc. until the The end of the mask word has been reached.

Claims (12)

1. Verfahren zum Betreiben eines digitalen Prozessors (100), um binäre Ganzzahlen unter Verwendung eines Be­ fehls zu einem spezifizierten Bereich abzuschneiden, mit folgenden Schritten:
  • (a) Definieren eines Abschneidebefehls, der ein Masken­ feld aufweist;
  • (b) Annehmen einer Maske von dem Maskenfeld, wobei für jedes Bit, das sich außerhalb des Bereichs befindet, ein Bit in der Maske eingestellt ist, und wobei für Bits, die sich innerhalb des Bereichs befinden, Bits in der Maske nicht eingestellt sind; und
  • (c) Anwenden der Maske auf die Eingabe-Ganzzahlen, der­ art, daß alle Ganzzahlen außerhalb des Bereichs auf die Größe in dem Bereich abgeschnitten werden, die der Ganzzahl am nächsten liegt, wodurch Ausgabe- Ganzzahlen innerhalb eines Bereichs erzeugt werden, der durch die Maske spezifiziert ist.
1. A method of operating a digital processor ( 100 ) to truncate binary integers using a command to a specified range, comprising the following steps:
  • (a) defining a clipping command having a mask field;
  • (b) accepting a mask from the mask field with one bit in the mask set for each bit that is out of the range and bits in the mask not set for bits that are within the range; and
  • (c) Applying the mask to the input integers such that all integers outside the range are trimmed to the size in the range closest to the integer, thereby producing output integers within a range defined by the Mask is specified.
2. Verfahren gemäß Anspruch 1, bei dem die Maskierungsope­ ration gemäß folgender Schritte durchgeführt wird:
Verwenden der Maske, um für jedes Byte zu bestimmen, ob ein Abschneiden notwendig ist;
wenn das Abschneiden notwendig ist, Verwenden der Maske, um zu definieren, wo die Ausgabe auf 0 eingestellt wird, und wo die Ausgabe auf 1 eingestellt wird.
2. The method according to claim 1, wherein the masking operation is carried out according to the following steps:
Using the mask to determine if clipping is necessary for each byte;
if clipping is necessary, use the mask to define where the output is set to 0 and where the output is set to 1.
3. Verfahren gemäß Anspruch 1 oder 2, bei dem der Abschneidebefehl bewirkt, daß der digitale Prozessor (100) Eingabe-Ganzzahlen, die einen ersten Datentyp aufweisen, zu Ausgabe-Ganzzahlen, die einen zweiten Datentyp aufweisen, abschneidet.3. The method of claim 1 or 2, wherein the truncation command causes the digital processor ( 100 ) to truncate input integers having a first data type to output integers having a second data type. 4. Verfahren gemäß Anspruch 3, bei dem der erste Datentyp und der zweite Datentyp aus der Gruppe gewählt werden, die die Elemente vorzeichen­ behaftete Daten und vorzeichenlose Daten enthält.4. The method according to claim 3, in which the first data type and the second data type the group that signs the elements contains data with data and unsigned data. 5. Verfahren gemäß einem beliebigen der Ansprüche 1, 3 oder 4,
bei dem der Abschneidebefehl Eingabedaten von sowohl vorzeichenbehafteten als auch vorzeichenlosen Ganzzahlen und abgeschnittene Ausgabedaten von sowohl vorzeichenbe­ hafteten als auch vorzeichenlosen Ganzzahlen anzeigen kann; und
bei dem Operationscode-Vervollständigungsbits des Be­ fehls die Datentypen von Ganzzahlen in den Eingabedaten und in den Ausgabedaten anzeigen.
5. The method according to any one of claims 1, 3 or 4,
wherein the clipping command can display input data from both signed and unsigned integers and truncated output data from both signed and unsigned integers; and
for the instruction's opcode completion bit, indicate the data types of integers in the input and output data.
6. Verfahren gemäß einem beliebigen der Ansprüche 1, 3 oder 4,
bei dem die Maske Codes zum Spezifizieren der Datentypen enthält.
6. The method according to any one of claims 1, 3 or 4,
in which the mask contains codes for specifying the data types.
7. Verfahren gemäß Anspruch 1, bei dem die Maskierungsope­ ration gemäß der folgenden Schritte durchgeführt wird: 7. The method according to claim 1, wherein the masking operation is carried out according to the following steps: 8. Schaltung (100) zum Abschneiden von Ganzzahlen, die in einer Eingabequelle (203) gespeichert sind, die in min­ destens einen Eingabedatenblock logisch aufgeteilt ist, wobei jeder Eingabedatenblock eine Größe aufweist, um ein abgeschnittenes Ergebnis zu erzeugen, das in einem Ausgabeziel (205) gespeichert wird, mit folgenden Merk­ malen:
einer Steuerungsschaltung (109), die betreibbar ist, um einen Abschneidebefehl als Eingabe anzunehmen, wobei der Abschneidebefehl die Größe des Eingabedatenblocks defi­ niert und jeder Eingabedatenblock eine Ganzzahl enthält;
einer Maskenquelle (201), die mit der Steuerungsschal­ tung zum Speichern einer Maske, die jedem Eingabedaten­ block entspricht, verbunden ist;
einer Abschneidebestimmungsschaltung (401, 403, 405, 407, 409), die betreibbar ist, um die Maske mit der Ein­ gabe, die in der Eingabequelle gespeichert ist, zu ver­ gleichen, wodurch bestimmt wird, ob das Abschneiden für jeden Ausgabeblock benötigt wird, und um ein Abschnei­ designal zu erzeugen, dessen Wert von der Abschneide­ bestimmung abhängt; und
mindestens eine Bitebene-Abschneideschaltung (215), die mit der Abschneide-Bestimmungsschaltung, mit der Einga­ bequelle (203), mit der Maskenquelle (201) und mit dem Ausgabeziel (205) verbunden ist, derart, daß jede Bit­ ebene-Abschneideschaltung (215) eine 1-zu-1-Abbildung zwischen der Eingabequelle (203) und dem Ausgabeziel (205) schafft; und
wobei alle Bitebene-Abschneideschaltungen (215), die einem Eingabedatenblock entsprechen, kollektiv selektiv als Reaktion auf das Abschneidesignal betreibbar sind, um die Maske auf die Eingabe anzuwenden, derart, daß die Bits, die Bits innerhalb des Bereichs entsprechen, in dem Ausgabeziel zu einem Bitmuster eingestellt werden, das eine Zahl, die sich in dem Bereich befindet, dar­ stellt, die bezüglich ihres Wertes dem Wert der Ganz­ zahl, die in dem Eingabedatenblock enthalten ist, am nächsten liegt.
8.Integer truncation circuitry ( 100 ) stored in an input source ( 203 ) logically divided into at least one input data block, each input data block being sized to produce a truncated result that can be used in an output destination ( 205 ) is saved, paint with the following characteristics:
a control circuit ( 109 ) operable to accept a truncation command as input, the truncation command defining the size of the input data block and each input data block containing an integer;
a mask source ( 201 ) connected to the control circuit for storing a mask corresponding to each input data block;
a clipping determination circuit ( 401 , 403 , 405 , 407 , 409 ) operable to compare the mask with the input stored in the input source, thereby determining whether clipping is needed for each output block, and to designally produce a clipping whose value depends on the clipping determination; and
at least one bit level clipping circuit ( 215 ) connected to the clipping determination circuit, the input convenient ( 203 ), the mask source ( 201 ) and the output destination ( 205 ) such that each bit level clipping circuit ( 215 ) creates a 1-to-1 mapping between the input source ( 203 ) and the output destination ( 205 ); and
wherein all bit level clipping circuits ( 215 ) corresponding to an input data block are collectively operable selectively in response to the clipping signal to apply the mask to the input such that the bits corresponding to bits within the range become one in the output destination Bit pattern can be set, which represents a number that is in the range, the value of which is closest to the value of the integer contained in the input data block.
9. Die Schaltung gemäß Anspruch 8,
bei der jeder Eingabeblock und jeder Ausgabeblock ein Byte ist, und
bei der die Abschneidebestimmungsschaltung (401, 403, 405, 407, 409) ein Abschneidesignal für jedes Byte in dem Ausgabeziel erzeugt.
9. The circuit according to claim 8,
where each input block and each output block is a byte, and
wherein the clipping determination circuit ( 401 , 403 , 405 , 407 , 409 ) generates a clipping signal for each byte in the output destination.
10. Die Schaltung gemäß Anspruch 9, wobei der Abschneidebe­ fehl spezifiziert, daß jeder Eingabedatenblock aus dem Satz Doppelwort, Wort, Halbwort und Byte gewählt wird und die Schaltung zum Abschneiden der Ganzzahlen, wobei jede Ganzzahl in der Eingabequelle gespeichert ist, ein Vorzeichenbit aufweist, wobei die Schaltung hierarchisch organisiert ist und ferner folgende Merkmale aufweist:
eine Bytevorzeichen-Auswahlschaltung;
mindestens eine Byteebene-Schaltung (213), die mit der vorzeichen-Auswahlschaltung verbunden ist, derart, daß die Vorzeichen-Auswahlschaltung den Wert des Vorzeichen bits der Ganzzahl, die der Byteebene-Schaltung ent­ spricht, zu der Byteebene-Schaltung liefert, wobei die Byteebene-Schaltung eine Mehrzahl der Bitebene-Schaltun­ gen (215) enthält.
10. The circuit of claim 9, wherein the truncation fails to specify that each input data block is selected from the set of double word, word, halfword, and byte, and the integer truncation circuit, each integer stored in the input source, has a sign bit. wherein the circuit is organized hierarchically and also has the following features:
a byte sign selection circuit;
at least one byte level circuit ( 213 ) connected to the sign selection circuit such that the sign selection circuit supplies the value of the sign bit of the integer corresponding to the byte level circuit to the byte level circuit, the Byte level circuit includes a plurality of the bit level circuits ( 215 ).
11. Die Schaltung gemäß Anspruch 10, bei der die Abschneidebestimmungsschaltung (401, 403, 405, 407, 409) über die Byteebene-Schaltungen aufgeteilt ist, derart, daß jede Byteebene-Schaltung (213) mit Aus­ nahme der vordersten Byteebene-Schaltung (213a) ein Größenauswahl-UND-Gatter aufweist, bei dem ein Eingang mit dem Abschneidesignal der nächsten höheren Byteebe­ ne-Schaltung (213) verbunden ist und ein zweiter Eingang mit einer Signalleitung verbunden ist, deren Wert von der Größe des Eingabedatenblocks und von der Position der Byteebene-Schaltung (213) bezüglich der anderen Byteebene-Schaltungen (213) abhängt.11. The circuit of claim 10, wherein the truncation determining circuit ( 401 , 403 , 405 , 407 , 409 ) is divided over the byte level circuits such that each byte level circuit ( 213 ) except the foremost byte level circuit ( 213 a) has a size selection AND gate, in which one input is connected to the cut-off signal of the next higher byte level circuit ( 213 ) and a second input is connected to a signal line, the value of which depends on the size of the input data block and on the Position of the byte level circuit ( 213 ) with respect to the other byte level circuits ( 213 ) depends. 12. Die Schaltung gemäß Anspruch 10,
bei der jede Bitebene-Schaltung (215) mit dem Byteebe­ ne-Abschneidesignal (c), mit der Bytevorzeichen-Auswahl­ schaltung (db), mit einem Maskenbit in der Maske, das der Bitebene-Schaltung (m) entspricht, mit einem Daten­ bit in der Eingabequelle, das der Bitebene-Schaltung (215) (d) entspricht, und mit einem Abschneidetypsignal verbunden ist; und
bei der die Bitebene-Schaltung eine Mehrzahl von Logik­ gattern aufweist, welche ein Ausgabebit (o) gemäß einer Wahrheitstabelle erzeugen.
12. The circuit according to claim 10,
in which each bit level circuit ( 215 ) with the byte level cut-off signal (c), with the byte sign selection circuit (db), with a mask bit in the mask which corresponds to the bit level circuit (m) with a data bit in the input source corresponding to the bit plane circuit ( 215 ) (d) and connected to a clipping type signal; and
in which the bit level circuit has a plurality of logic gates which generate an output bit (o) according to a truth table.
DE19601575A 1995-01-17 1996-01-17 Parallel cutting of binary integer numbers for image processor Withdrawn DE19601575A1 (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
US37373995A 1995-01-17 1995-01-17

Publications (1)

Publication Number Publication Date
DE19601575A1 true DE19601575A1 (en) 1996-07-18

Family

ID=23473674

Family Applications (1)

Application Number Title Priority Date Filing Date
DE19601575A Withdrawn DE19601575A1 (en) 1995-01-17 1996-01-17 Parallel cutting of binary integer numbers for image processor

Country Status (3)

Country Link
JP (1) JPH08272591A (en)
DE (1) DE19601575A1 (en)
GB (1) GB2300054A (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0845741B1 (en) * 1996-11-29 2003-04-16 Matsushita Electric Industrial Co., Ltd. Processor which can favorably execute a rounding process
JP2015143949A (en) * 2014-01-31 2015-08-06 富士通株式会社 Arithmetic program, arithmetic device, and arithmetic method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2269922A (en) * 1992-08-21 1994-02-23 Sony Corp Digital data rounding.
DE4304198A1 (en) * 1993-02-12 1994-08-18 Itt Ind Gmbh Deutsche Method of speeding up the data processing of a signal processor

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0540155A3 (en) * 1991-10-29 1993-07-21 Advanced Micro Devices, Inc. Digital limit checking system
ATE180907T1 (en) * 1991-10-29 1999-06-15 Advanced Micro Devices Inc ARITHMETIC LOGIC UNIT
US5448509A (en) * 1993-12-08 1995-09-05 Hewlett-Packard Company Efficient hardware handling of positive and negative overflow resulting from arithmetic operations
JP2591463B2 (en) * 1993-12-27 1997-03-19 日本電気株式会社 Limiter device
JP3105738B2 (en) * 1994-06-10 2000-11-06 日本電気株式会社 Information processing device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2269922A (en) * 1992-08-21 1994-02-23 Sony Corp Digital data rounding.
DE4304198A1 (en) * 1993-02-12 1994-08-18 Itt Ind Gmbh Deutsche Method of speeding up the data processing of a signal processor

Also Published As

Publication number Publication date
GB9600781D0 (en) 1996-03-20
JPH08272591A (en) 1996-10-18
GB2300054A (en) 1996-10-23

Similar Documents

Publication Publication Date Title
DE69622676T2 (en) Data processing arrangement with extension of the instruction set
DE3688824T2 (en) Data processing system.
DE69030128T2 (en) Signal processor
DE69233361T2 (en) Single-chip microcomputer
DE69428303T2 (en) Method and device for data processing with several status bit groups
DE69503046T2 (en) MULTIPLE COMMAND SET FIGURE
DE69900980T2 (en) METHOD AND DEVICE FOR EXECUTING SHIFT OPERATIONS WITH PACKED DATA
DE2935906C2 (en) microprocessor
DE69324730T2 (en) Multiplier accumulator
DE2230102A1 (en) CALCULATOR FOR VARIABLE WORD LENGTHS
DE19920214A1 (en) Conversion of a fixed point and floating point numbers
DE112004001648T5 (en) Method, apparatus and instructions for parallel data conversion
DE3709675C2 (en)
DE2718110A1 (en) DATA PROCESSING UNIT
DE3856139T2 (en) microprocessor
DE4403917A1 (en) Device to calculate an occupation count
DE69231237T2 (en) Data processing device
DE3620982A1 (en) ON COMMAND, MULTIPLE DATA CURRENT (SIMD) COMPUTER SYSTEM
DE19730727C2 (en) Method and circuit for truncating integers using a mask
DE69823302T2 (en) Method and device for moving data
DE3876887T2 (en) GENERATION OF LINES IN A DISPLAY SYSTEM.
DE2458286A1 (en) DATA PROCESSING SYSTEM FOR MOVING DATA FIELDS WITH DIFFERENT STRUCTURES
DE69315192T2 (en) Data processing system and method with an expandable register
DE3855066T2 (en) Surgical device for processing data of arbitrary length
DE10210663A1 (en) Device for indication of and/or precise operations on numerical values in binary system divides binary coded number by divisor, use results to look up display screen codes in static table

Legal Events

Date Code Title Description
OP8 Request for examination as to paragraph 44 patent law
8130 Withdrawal