DE10141917B4 - Microprocessor and method for determining a minimum and maximum value of a sequence of data words - Google Patents

Microprocessor and method for determining a minimum and maximum value of a sequence of data words Download PDF

Info

Publication number
DE10141917B4
DE10141917B4 DE2001141917 DE10141917A DE10141917B4 DE 10141917 B4 DE10141917 B4 DE 10141917B4 DE 2001141917 DE2001141917 DE 2001141917 DE 10141917 A DE10141917 A DE 10141917A DE 10141917 B4 DE10141917 B4 DE 10141917B4
Authority
DE
Germany
Prior art keywords
register
max
data
output
address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
DE2001141917
Other languages
German (de)
Other versions
DE10141917A1 (en
Inventor
Richard Dr.-Ing. Hoffer
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.)
Sci Worx GmbH
Original Assignee
Sci Worx GmbH
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 Sci Worx GmbH filed Critical Sci Worx GmbH
Priority to DE2001141917 priority Critical patent/DE10141917B4/en
Publication of DE10141917A1 publication Critical patent/DE10141917A1/en
Application granted granted Critical
Publication of DE10141917B4 publication Critical patent/DE10141917B4/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/22Arrangements for sorting or merging computer data on continuous record carriers, e.g. tape, drum, disc
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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/30021Compare instructions, e.g. Greater-Than, Equal-To, MINMAX

Landscapes

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

Abstract

Mikroprozessor (1) zur Ausführung von Programmbefehlen mit einer Ablaufsteuerung (2) zur Ausführung der Programmbefehle, mit einer arithmetischen Logikeinheit (ALU), mit einem Datenbus (6), und mit mindestens einem Registerspeicher (5), der an den Datenbus (6) und die arithmetische Logikeinheit (ALU) geklemmt ist, wobei ein Programmbefehl genau eine erste Quellenadresse (src 1) für einen ersten Eingangswert (OP1), eine zweite Quellenadresse (src2) für einen zweiten Eingangswert (OP2) und eine Zieladresse (dest) für das Berechnungsergebnis (RES) für den Zugriff auf den mindestens einen Registerspeicher enthält und eine zusätzliche Extremwert-Ermittlungseinheit (13) zur Ermittlung des minimalen Wertes (MIN) und des maximalen Wertes (MAX) einer Folge von Datenworten (x[i]) durch schrittweises Einlesen einzelner Datenworte (x(i)) aus dem Registerspeicher (5) in die Extremwert-Ermittlungseinheit (13), dadurch gekennzeichnet, dass die Extremwert-Ermittlungseinheit (13)
– eine erste Vergleichseinheit (15) mit zwei Eingängen und einem Ausgang (MIN-out) zum Ausgeben des minimalen Wertes der an den beiden Eingängen anliegenden Datenworte an den Ausgang...
Microprocessor (1) for executing program commands with a sequence control (2) for executing the program commands, with an arithmetic logic unit (ALU), with a data bus (6), and with at least one register memory (5) which is connected to the data bus (6) and the arithmetic logic unit (ALU) is clamped, wherein a program instruction exactly one first source address (src 1) for a first input value (OP1), a second source address (src2) for a second input value (OP2) and a target address (dest) for the Contains calculation result (RES) for access to the at least one register memory and an additional extreme value determination unit (13) for determining the minimum value (MIN) and the maximum value (MAX) of a sequence of data words (x [i]) by step-by-step reading individual data words (x (i)) from the register memory (5) into the extreme value determination unit (13), characterized in that the extreme value determination unit (13)
- A first comparison unit (15) with two inputs and one output (MIN-out) for outputting the minimum value of the data words present at the two inputs to the output ...

Figure 00000001
Figure 00000001

Description

Die Erfindung betrifft einen Mikroprozessor zur Ausführung von Programmbefehlen mit einer Ablaufsteuerung zur Ausführung der Programmbefehle mit einer arithmetischen Logikeinheit, mit einem Datenbus, und mit mindestens einem Registerspeicher, der an den Datenbus und die arithmetische Logikeinheit geklemmt ist, wobei ein Programmbefehl als Parameter genau eine erste Quellenadresse für einen ersten Eingangswert, eine zweite Quellenadresse für einen zweiten Eingangswert und eine Zieladresse für das Berechnungsergebnis für den Zugriff auf den mindestens einen Registerspeicher enthält.The The invention relates to a microprocessor for executing program instructions with a sequence control for executing the program commands with an arithmetic logic unit, with a data bus, and with at least a register memory connected to the data bus and the arithmetic Logic unit is clamped, with a program command as a parameter exactly one first source address for a first input value, a second source address for a second input value and a target address for the calculation result for the Contains access to the at least one register memory.

Die Erfindung betrifft ferner ein Verfahren zur Ermittlung eines minimalen Wertes und eines maximalen Wertes einer Folge von Datenworten mit einem wie oben beschrieben ausgebildeten Mikroprozessor.The The invention further relates to a method for determining a minimum Value and a maximum value of a sequence of data words with a microprocessor designed as described above.

Derartige Mikroprozessoren sind hinreichend bekannt und z. B. in R. Scholze: "Einführung in die Mikrocomputertechnik", Teubner-Verlag Stuttgart, 1985, S. 46 ff. ausführlich beschrieben. Kern eines Mikroprozessor ist die arithmetische Logikeinheit (ALU), mit der die eigentliche Verarbeitung von Datenwörtern (Operanden) erfolgt. Die arithmetische Logikeinheit ist eine kombinatorische Schaltung, die jeweils zwei Datenwörter an ihren beiden Eingängen miteinander verknüpft. Das Verknüpfungsergebnis erscheint an dem Ausgang der arithmetischen Logikeinheit. Die Art und Weise der Verknüpfung wird durch eine Ablaufsteuerung vorgegeben. So sind z. B. arithmetische Operationen, wie z.B. a plus b, a minus b und a plus 1, sowie logische Operationen, wie z.B. a UND b, a ODER b etc., ausführbar. Mehrschrittige arithmetische Abläufe, wie Multiplikation und Division, werden der arithmetischen Logikeinheit als Folge von Additions- bzw. Subtraktionsschritten einzeln vorgegeben.such Microprocessors are well known and z. B. in R. Scholze: "Introduction to microcomputer technology ", Teubner-Verlag Stuttgart, 1985, p. 46 ff. Described in detail. Core of one The microprocessor is the arithmetic logic unit (ALU) with which the actual processing of data words (operands) takes place. The arithmetic logic unit is a combinatorial circuit, the two data words each at their two entrances linked together. The link result appears at the output of the arithmetic logic unit. The Art and way of linking is specified by a sequence control. So z. B. arithmetic Operations such as a plus b, a minus b and a plus 1, as well as logical Operations such as a AND b, a OR b etc., executable. Step-by arithmetic processes, like multiplication and division, are the arithmetic logic unit individually specified as a result of addition or subtraction steps.

Vor die Eingänge der arithmetischen Logikeinheit ist ein Registerspeicher geklemmt, der üblicherweise als „Register-File" bezeichnet wird. Der Registerspeicher beinhaltet mehrere, z. B. 16 Register R0 bis R7 und mehrere z. B. 4 Adressregister A0 bis A3. Der Registerspeicher hat mehrere Ports, über die (gleichzeitig in einem Takt) Daten gelesen und geschrieben werden können. Der Registerspeicher wird über einen Datenbus mit Daten versorgt. Der Ausgang der arithmetischen Logikeinheit ist hierbei an den Datenbus geklemmt, so dass Ergebnisse einer Operation der arithmetischen Logikeinheit über den internen Datenbus auf den Registerspeicher zurückgeschrieben werden können.In front the entrances a register memory is clamped to the arithmetic logic unit, which is commonly referred to as a "register file". The register memory contains several, e.g. B. 16 registers R0 to R7 and several z. B. 4 address registers A0 to A3. The register memory has multiple ports over the data is read and written (simultaneously in one cycle) can. The register memory is over a data bus supplied with data. The output of the arithmetic Logic unit is clamped to the data bus, so that results an operation of the arithmetic logic unit via the internal data bus the register memory was written back can be.

Die Referenzierung der Register des Registerspeichers erfolgt über Registeradressen.The The registers in the register memory are referenced using register addresses.

Die Ablaufsteuerung dient zum Erzeugen von Steuersignalen für den Mikroprozessor, insbesondere für die arithmetische Logikeinheit. Sie wird mit definierten Programmbefehlen angesprochen. Hierbei verfügen die Programmbefehle über genau drei Parameter, nämlich eine erste Quellenadresse für einen ersten Eingangswert, eine zweite Quellenadresse für einen zweiten Eingangswert und eine Zieladresse für das Berechnungsergebnis für den Zugriff auf den mindestens einen Registerspeicher. Somit gibt der Programmbefehl selbst die Art der Verknüpfungsoperation in der arithmetischen Logikeinheit an, die erste und zweite Quellenadresse steuern den Zugriff auf die beiden zu verknüpfenden Eingangswerte, die in den Registerspeichern abgelegt sind, und die Zieladresse gibt die Registeradresse zum Schreiben des Verknüpfungsergebnisses in den zugehörigen Registerspeicher an. Somit ist die Generierung der Adressen für die einzelnen Ports des Registerspeichers sowie der Schreibkommandos (für die Schreibports) Aufgabe der Ablaufsteuerung des Mikroprozessors.The Sequence control is used to generate control signals for the microprocessor, especially for the arithmetic logic unit. It comes with defined program commands addressed. Here, the Program commands via exactly three parameters, namely a first source address for a first input value, a second source address for a second input value and a destination address for the calculation result for the access to the at least one register memory. So the program command itself the type of join operation in the arithmetic logic unit, the first and second source addresses control access to the two input values to be linked, the are stored in the register memories, and the destination address there the register address for writing the result of the link in the associated register memory on. This is the generation of the addresses for the individual ports of the register memory as well as the write commands (for the write ports) task of the sequential control of the microprocessor.

Der Mikroprozessor hat somit folgende Eigenschaften:

  • – er ist eine 3-Adress-Maschine mit einer ersten Quellenadresse, einer zweiten Quellenadresse und einer Zieladresse,
  • – die Rechenoperationen finden auf Registern von Registerspeichern statt,
  • – die Registerspeicher haben Datenregister r0... rx-1 und Adressregister a0...ay-1,
  • – die Register der Registerspeicher werden durch die drei Adressen, nämlich die erste und zweite Quellenadresse und die Zieladresse referenziert.
The microprocessor therefore has the following properties:
  • - it is a 3-address machine with a first source address, a second source address and a destination address,
  • - the arithmetic operations take place on registers of register memories,
  • - the register memories have data registers r0 ... r x -1 and address registers a 0 ... a y -1,
  • - The registers of the register memories are referenced by the three addresses, namely the first and second source address and the destination address.

Insbesondere für die Video-Signalverarbeitung nach dem MPEG4-Codierstandard ist eine Filterung des decodierten Bildes zur Verbesserung der subjektiven Bildqualität vorgeschlagen. Die hierfür vorgesehenen Filteralgorithmen berechnen ein Aktivitätsmaß für Teilbereich des decodierten Bildes, welches die Differenz aus maximalen und minimalem Pixelwert einer Folge von Bildpunkten darstellt.In particular for the Video signal processing according to the MPEG4 coding standard is one Filtering the decoded picture to improve the subjective picture quality proposed. The one for this The provided filter algorithms calculate an activity measure for partial areas of the decoded picture, which is the difference between maximum and represents the minimum pixel value of a sequence of pixels.

Bei der Berechnung beispielsweise solcher Filteralgorithmen auf einem herkömmlichen programmierbaren Prozessor muss ein Programm zur Ermittlung des Maximums und des Minimums einer Folge von Datenworten erstellt und ausgeführt werden. Hierzu sind zwei verschiedene Strategien bekannt. Eine erste Strategie basiert auf einem fortlaufenden Vergleichen von Datenworten. Hierzu sind mindestens 1,5 Vergleiche pro Datenwort erforderlich. Eine vollkommen andere Strategie basiert auf einer Histogramm-Evaluierung, für das über die Gesamtheit des diskreten Wertebereichs pro Datenwort eine indizierte Speicherung erforderlich ist. Anschließend wird das Histogramm mittels linearer Suche ausgewertet. Diese Strategie ist daher nur bei Auswertung einer großen Anzahl von Datenworten vorteilhaft.at the calculation of such filter algorithms on a usual Programmable processor must have a program to determine the Maximum and minimum of a sequence of data words created and accomplished become. Two different strategies are known for this. A first one Strategy is based on a continuous comparison of data words. This requires at least 1.5 comparisons per data word. A completely different strategy is based on a histogram evaluation, for that about the All of the discrete range of values one indexed data word Storage is required. Then the histogram is displayed using linear search evaluated. This strategy is therefore only for evaluation a big one Number of data words advantageous.

Diese beiden bekannten Strategien benötigen bei der Ausführung oder Implementierung auf herkömmlichen Mikroprozessoren nachteilig mehrere Taktzyklen pro Datenwort.This need two known strategies in execution or implementation on conventional Microprocessors disadvantageously several clock cycles per data word.

In TriCore Architecture Overview Handbook, User's Manual, V 1.3.0, August 1999 ist ein superskalarer digitaler Signalprozessor beschrieben, mit dem pro Takt drei Befehle gleichzeitig ausgeführt warden können. Es sind Programmbefehle u.a. zur Berechnung des Minimums sowie des Maximums zweier Werte vorgesehen. Dabei handelt es sich um zwei voneinander unabhängige Befehle, sodass das Minimum einer Folge von Datenwerten getrennt von dem Maximum bestimmt werden muss. Die erforderliche Anzahl von Taktraten ist daher relativ hoch.In TriCore Architecture Overview Handbook, User's Manual, V 1.3.0, August 1999 is a superscalar digital signal processor described with the pro Three commands can be executed simultaneously. It are program commands to calculate the minimum and the Maximum of two values provided. These are two independent of each other Commands so that the minimum of a sequence of data values is separated must be determined from the maximum. The required number of Clock rates are therefore relatively high.

In dem US-Patent 5,345,410 A ist ein erweiterter Mikroprozessor mit Standard-ALU und hierzu parallel geschalteten Einheiten für spezielle Berechnungen beschrieben. Mit einem Three-Input-Komparator wird jedoch lediglich die Information weitergegeben, welche von drei Eingangswerten der größte/kleinste Wert ist. Die Ausgabe erfolgt entsprechend als binärer einstelliger Wert. Um nun den kleinsten und größten Wert einer Folge von Datenworten zu ermitteln, muss auf Basis dieser binären Informationen ein relativ komplexer Programmablauf definiert werden, der aufgrund der voneinander getrennten Vergleichs- und Speichervorgänge mehrere Taktraten pro Vergleich erfordert.In U.S. Patent 5,345,410 A is an expanded microprocessor Standard ALU and units connected in parallel for special calculations. With a three-input comparator, however, only the information passed on, which of the three input values is the largest / smallest Is worth. The output is accordingly a binary single-digit Value. Now the smallest and largest value of a sequence of data words To determine based on this binary information must be a relative complex program flow can be defined based on each other separate comparison and storage processes several clock rates per comparison requires.

Aufgabe der Erfindung war es daher, einen verbesserten Mikroprozessor zu schaffen, mit dem die Ermittlung des minimalen und maximalen Wertes einer Folge von Datenworten mit einer reduzierten Taktanzahl durchgeführt werden kann.task the invention was therefore to provide an improved microprocessor create with which the determination of the minimum and maximum value a sequence of data words with a reduced number of clock cycles can.

Die Aufgabe wird erfindungsgemäß durch den Mikroprozessor gemäß Anspruch 1 und das Verfahren gemäß Anspruch 2 gelöst.The The object is achieved by the microprocessor according to claim 1 and the method according to claim 2 solved.

Es wird somit vorgeschlagen, einen herkömmlichen Mikroprozessor um eine zusätzliche Extremwert-Ermittlungseinheit zu erweitern. Diese Extemwert-Ermittlungseinheit hat eine erste und zweite Vergleichseinheit, so dass in einem Schritt zwei Vergleiche zur Ermittlung eines minimalen und eines maximalen Wertes von je zwei Eingangswert-Paaren durchgeführt werden. Dabei liegt ein jeweiliger Vergleichswert als zweiter Eingangswert in einem Minimum-Zwischenregister und einem Maximum-Zwischenregister für den Vergleich bereit. Die Werte in dem Minimum- und Maximum-Zwischenregister können insbesondere zur Initialisierung der Minimum-Maximum-Berechnung aus dem Registerspeicher in das jeweilige Zwischenregister geladen werden. Es ist aber auch möglich, den ermittelten Extremwert am Ausgang der jeweiligen Vergleichseinheit in das entsprechende Zwischenregister zu laden. Die letztgenannte Option führt dazu, dass als Vergleichswert immer der aktuell ermittelte Extremwert verwendet wird.It is thus proposed to use a conventional microprocessor an additional Extend extreme value determination unit. This extreme value determination unit has a first and second comparison unit, so in one step two comparisons to determine a minimum and a maximum Value of two input value pairs each. There is one respective comparison value as second input value in a minimum intermediate register and a maximum intermediate register for the comparison. The In particular, values in the minimum and maximum intermediate register can for initializing the minimum-maximum calculation from the register memory be loaded into the respective intermediate register. It is also possible, the extreme value determined at the output of the respective comparison unit to load into the corresponding intermediate register. The latter Option leads to the fact that the currently determined extreme value is always used as a comparison value is used.

Damit der Programmbefehl mit den drei verfügbaren Parametern, nämlich die erste und zweite Quellenadresse und die Zieladresse, auskommt, sind die erste und zweite Vergleichseinheit jeweils an eine erste definierte Registeradresse und eine zweite definierte Registeradresse fest gekoppelt.In order to the program command with the three available parameters, namely the first and second source address and the destination address that comes out are the first and second comparison unit each defined to a first Register address and a second defined register address coupled.

Es ist besonders vorteilhaft, wenn ein dritter Multiplexer an den Ausgängen der ersten und zweiten Vergleichseinheit und der arithmetischen Logikeinheit vorgesehen ist, um Datenworte von genau einem ausgewählten Ausgang an eine eingegebene Registeradresse der Registerspeicher zu schreiben. Auf diese Weise wird das Ergebnis des Minimum- oder Maximum-Vergleichs in den Registerspeicher überführt und kann weiterverarbeitet werden.It is particularly advantageous if a third multiplexer at the outputs of the first and second comparison unit and the arithmetic logic unit is provided to data words from exactly one selected output to write the register memory to an entered register address. In this way the result of the minimum or maximum comparison transferred to the register memory and can be processed further.

Die Erfindung wird durch das Verfahren zur Ermittlung eines minimalen Wertes und eines maximalen Wertes einer Folge von Datenworten deutlicher, das auf dem Mikroprozessor ausgeführt wird.The Invention is determined by the method of determining a minimum Value and a maximum value of a sequence of data words more clearly, that runs on the microprocessor.

Das Verfahren basiert auf einer Strategie des Vergleichens. Eine Nachbearbeitung, wie bei der linearen Suche im Histogramm, ist nicht erforderlich.The The method is based on a strategy of comparison. Post-processing, as with the linear search in the histogram, is not required.

Pro Datenwort und Takt sind zwei Vergleiche implementiert, so dass das Verfahren unabhängig von der Anzahl der Datenworte (gerade oder ungerade Anzahl) ist. Das Verfahren stellt somit eine Modifikation der bekannten Vergleichsstrategie dar.Per Data word and clock are two comparisons implemented, so that Procedure independent of the number of data words (even or odd number). The method thus represents a modification of the known comparison strategy represents.

Zur Initialisierung erfolgt in einem ersten Schritt a) das Laden eines ersten Datenwortes der Folge von Datenworten in einen Registerspeicher an einer definierten Registeradresse.to Initialization takes place in a first step a) loading a first data word of the sequence of data words in a register memory at a defined register address.

In einem zweiten Schritt b) wird das erste Datenwort aus dem Registerspeicher in das Minimum-Zwischenregister und das Maximum-Zwischenregister geladen.In a second step b) the first data word from the register memory into the minimum intermediate register and the maximum intermediate register loaded.

Das erste Datenwort liegt somit als Vergleichswert an der ersten und zweiten Vergleichseinheit an.The The first data word is therefore a comparison value on the first and second comparison unit.

Nunmehr wird für die Folge der verbleibenden Datenworte eine entsprechende Folge von MIN-MAX-Programmbefehlen ausgeführt. Für eine Folge von 8 Datenworten sind somit 7 MIN-MAX-Programmbefehle erforderlich. Jeder MIN-MAX-Programmbefehl, hat wie oben bereits erwähnt, drei Parameter. Für den Parameter einer der beiden Quellenadressen ist jeweils die Registeradresse des folgenden Datenwortes im Registerspeicher angegeben. Dies führt dazu, dass beim ersten Aufruf des MIN-MAX-Programmbefehls nach dem Initialisieren das zweite Datenwort an den jeweils freien Eingang der ersten und zweiten Vergleichseinheit gelegt wird. Dann erfolgt automatisch ein Vergleich des Datenwortes mit dem im Zwischenregister befindlichen Datenwort. Nach der Initialisierung wird somit in beiden Vergleichseinheiten das erste mit dem zweiten Datenwort verglichen.Now is for the sequence of the remaining data words a corresponding sequence executed by MIN-MAX program instructions. For a sequence of 8 data words 7 MIN MAX program commands are therefore required. Every MIN-MAX program command, as mentioned above, three parameters. For the parameter of one of the two source addresses is the register address of the following data word in the register memory. This leads to, that the first time the MIN-MAX program command is called after initialization the second data word to the free input of the first and second comparison unit is placed. Then it happens automatically a comparison of the data word with that in the intermediate register Data word. After the initialization is thus in both comparison units compared the first with the second data word.

Der MIN-MAX-Programmbefehl sorgt auch dafür, dass der jeweils ermittelte Extremwert, d. h. der minimale Wert und der maximale Wert, in das zugehörige Zwischenregister zurückgeschrieben wird. Es findet daher immer ein Vergleich mit dem in der Folge bestimmten extremsten Wert statt. Der Inhalt des jeweiligen Zwischenregisters ist somit das jeweilige relative Minimum bzw. Maximum.The MIN MAX program command also ensures that the determined one Extreme value, d. H. the minimum value and the maximum value in which associated Intermediate register written back becomes. There is therefore always a comparison with that determined below most extreme value instead. The content of the respective intermediate register is the relative minimum or maximum.

Um nach Abschluss der Ermittlung des minimalen und maximalen Wertes die Ergebnisse in den Registerspeicher ausladen zu können, ist der MIN-MAX-Programmbefehl so definiert, dass für den Parameter der anderen Quellenadresse ein Steuerbefehlswort zum wahlweisen Leiten des minimalen Wertes am Ausgang der ersten Vergleichseinheit oder des maximalen Wertes am Ausgang der zweiten Vergleichseinheit oder des Ausgangs der arithmetischen Logikeinheit an den Datenbus vorgesehen ist. Damit kann wahlweise der in einem Vergleichsschritt ermittelte minimale oder maximale Wert an den Datenbus gelegt werden. Alternativ kann während der Auswertung des MIN-MAX-Programmbefehls auch das Ergebnis der arithmetischen Logikeinheit in einem Registerspeicher abgespeichert werden, da das Auslesen der ermittelten Extremwerte während des Vergleichs einer Folge von Datenworten nicht erforderlich ist. Die jeweils ermittelten Extremwerte werden nämlich in das entsprechende Zwischenregister zurückgekoppelt.Around after the determination of the minimum and maximum value to be able to load the results into the register memory the MIN-MAX program command so defined that for a control command word for the parameters of the other source address optional routing of the minimum value at the output of the first comparison unit or the maximum value at the output of the second comparison unit or the output of the arithmetic logic unit on the data bus is provided. This can be used in a comparison step determined minimum or maximum value can be applied to the data bus. Alternatively, during the evaluation of the MIN-MAX program command also the result of the arithmetic logic unit in a register memory can be saved because reading the determined extreme values while the comparison of a sequence of data words is not necessary. The extreme values determined in each case are namely in the corresponding Intermediate register fed back.

Die Ausführung der Folge von MIN-MAX-Programmbefehlen erfolgt vorzugsweise jeweils durch Laden eines im nächsten Schritt zu vergleichenden Datenwortes in einen Registerspeicher und Auslesen des im vorhergehenden Schritt geladenen Datenwortes aus dem Registerspeicher zum Vergleichen in der ersten Vergleichseinheit mit dem im vorhergehenden Schritt bestimmten minimalen Wert und zum Vergleichen in der zweiten Vergleichseinheit mit dem im vorhergehenden Schritt bestimmten maximalen Wert. Der ermittelte minimale Wert wird hierbei in den Minimum-Zwischenspeicher und der ermittelte maximale Wert in den Maximum-Zwischenspeicher geschrieben.The execution the sequence of MIN-MAX program commands is preferably carried out in each case by loading one in the next Step to be compared data word in a register memory and reading out the data word loaded in the previous step from the register memory for comparison in the first comparison unit with the minimum value determined in the previous step and for comparison in the second comparison unit with that in the previous Step determined maximum value. The determined minimum value is stored in the minimum buffer and the determined maximum value written in the maximum buffer.

Nachdem die Folge von MIN-MAX-Programmbefehlen für die Folge von Datenworten ausgeführt ist, wird mit dem letzten MIN-MAX-Programmbefehl der minimale Wert am Ausgang der ersten Vergleichseinheit an eine erste Registeradresse geschrieben. Ein weiterer MIN-MAX-Programmbefehl wird ausgeführt, um den maximalen Wert am Ausgang der zweiten Vergleichseinheit an eine zweite Registeradresse zu schreiben.After this the sequence of MIN-MAX program instructions for the sequence of data words accomplished is the minimum value with the last MIN-MAX program command at the output of the first comparison unit to a first register address written. Another MIN MAX program command is executed to the maximum value at the output of the second comparison unit to a write second register address.

Das Laden des im nächsten Schritt zu vergleichenden Datenwortes und Auslesen des im vorhergehenden Schritt geladenen Datenwortes wird vorzugsweise gleichzeitig durchgeführt, um die Taktzeiten zu reduzieren. Es ist jedoch auch möglich, diese Schritte jeweils nacheinander auszuführen.The Loading the next Step to compare the data word and read out the previous one The loaded data word is preferably carried out simultaneously to reduce the cycle times. However, it is also possible to do this Perform steps one after the other.

Da das Ergebnis des Ladebefehls erst im nächsten Takt zur Verfügung steht, verarbeitet erst der vorletzte MIN-MAX-Programmbefehl den letzten in das zugehörige Register geladenen Wert und gibt gleichzeitig das Minimum als Ergebnis zurück. Es ist dann der weitere MIN-MAX-Programmbefehl notwendig, um auch den maximalen Wert am Ausgang der zweiten Vergleichseinheit als Ergebnis auszugeben.Since the result of the load command is only available in the next cycle, the penultimate MIN-MAX program command processes the last value loaded into the associated register and outputs at the same time the minimum as a result. The further MIN-MAX program command is then necessary in order to also output the maximum value at the output of the second comparison unit as a result.

Die Erfindung wird nachfolgend anhand der beigefügten Zeichnungen näher erläutert. Es zeigenThe The invention is explained in more detail below with reference to the accompanying drawings. It demonstrate

1 – Blockdiagramm eines Mikroprozessors mit zusätzlicher Extremwert-Ermittlungseinheit; 1 - Block diagram of a microprocessor with an additional extreme value determination unit;

2 – Detail-Blockschaltbild der zusätzlichen Extremwert-Ermittlungseinheit. 2 - Detailed block diagram of the additional extreme value determination unit.

Die 1 lässt einen Mikroprozessor 1 zur Ausführung von Programmbefehlen als Blockdiagramm erkennen. Er besteht im wesentlichen aus einer arithmetischen Logikeinheit (ALU) zur Verknüpfung von zwei Eingangs-Datenworten sowie aus einer Ablaufsteuerung 2 zur Erzeugung von Steuersignalen, die definierte Abläufe in dem Mikroprozessor 1 auslösen. Die Ablaufsteuerung 2 hat einen Befehlsdecoder 3, um Programmbefehle mit zugehörigen Parametern für eine nachgeordnete Steuereinheit 4 umzusetzen. An den beiden Eingängen der arithmetischen Logikeinheit (ALU) ist ein Registerspeicher mit beispielsweise 16 Registern R0 bis R7 und 4 Adressregistern A0 bis A3 vorgesehen, die über Registeradressen angesteuert werden. Der Registerspeicher 7 hat mehrere Ports, über die vorzugsweise gleichzeitig in einem Takt Daten gelesen und geschrieben werden können. Im vorliegenden Fall sind drei Lese- und drei Schreibports vorgesehen. Der Daten- und Adresstransport erfolgt über einen internen Datenbus 6, der an die Eingänge des Registerspeicher 5 eines Registerspeichers 7 und der Ablaufsteuerung 2 sowie an den Ausgang der arithmetischen Logikeinheit ALU gekoppelt ist. Die Adressen für die einzelnen Ports des Registerspeichers 5 sowie der Schreibkommandos für die Schreibports ist Aufgabe der Ablaufsteuerung 2 des Mikroprozessors 1.The 1 leaves a microprocessor 1 Recognize as a block diagram for executing program instructions. It essentially consists of an arithmetic logic unit (ALU) for linking two input data words and a sequence control 2 for generating control signals, the defined processes in the microprocessor 1 trigger. The sequence control 2 has a command decoder 3 to program commands with associated parameters for a subordinate control unit 4 implement. At the two inputs of the arithmetic logic unit (ALU) there is a register memory, for example 16 Registers R0 to R7 and 4 address registers A0 to A3 are provided, which are controlled via register addresses. The register memory 7 has several ports, which can be used to read and write data at the same time, preferably in one cycle. In the present case, three read and three write ports are provided. The data and address are transported via an internal data bus 6 connected to the inputs of the register memory 5 a register memory 7 and the sequence control 2 and is coupled to the output of the arithmetic logic unit ALU. The addresses for the individual ports of the register memory 5 and the write commands for the write ports is the task of the sequential control system 2 of the microprocessor 1 ,

Über einen Datenpuffer 8 ist der interne Datenbus 6 an einen externen Datenbus 9 des Mikroprozessors 1 geschaltet. Der interne Datenbus 6 ist ferner über ein Leitwerk 10 an einen externen Adressenbus 11 des Mikroprozessors 1 geklemmt. Die Ablaufsteuerung 2 ist zudem mit einem externen Steuerbus 12 des Mikroprozessors 1 verbunden. Der externe Daten-, Adress- und Steuerbus 9, 11, 12 des Mikroprozessors 1 bildet zusammen den Systembus, mit dem der Mikroprozessor 1 an eine externe Recheneinheit geschaltet ist.Via a data buffer 8th is the internal data bus 6 to an external data bus 9 of the microprocessor 1 connected. The internal data bus 6 is also about an empennage 10 to an external address bus 11 of the microprocessor 1 clamped. The sequence control 2 is also with an external control bus 12 of the microprocessor 1 connected. The external data, address and control bus 9 . 11 . 12 of the microprocessor 1 together forms the system bus with which the microprocessor 1 is connected to an external computing unit.

Die Ansteuerung des Mikroprozessors 1 erfolgt somit über den Systembus.The control of the microprocessor 1 thus takes place via the system bus.

Es ist zusätzlich eine Extremwert-Ermittlungseinheit 13 vorgesehen, um einen minimalen und einen maximalen Wert einer Folge von Datenworten zu ermitteln. Diese Extremwert-Ermittlungseinheit 13 ist parallel zu der arithmetischen Logikeinheit ALU an den Registerspeicher 5 der arithmetischen Logikeinheit ALU geschaltet. Der Ausgang der Extremwert-Ermittlungseinheit 13 ist ebenfalls an den internen Datenbus 6 gekoppelt, so dass die Berechnungsergebnisse wieder in den Registerspeicher 5 der arithmetischen Logikeinheit ALU geschrieben werden können. Ein optionaler lokaler Daten-Speicher 14 beinhaltet ggf. die Folgen von zu verknüpfenden Datenwerten, die von dem lokalen Speicher 14 in den Registerspeicher 5 geladen werden.It is also an extreme value determination unit 13 provided to determine a minimum and a maximum value of a sequence of data words. This extreme value determination unit 13 is parallel to the arithmetic logic unit ALU to the register memory 5 the arithmetic logic unit ALU switched. The output of the extreme value determination unit 13 is also connected to the internal data bus 6 coupled so that the calculation results back into the register memory 5 the arithmetic logic unit ALU can be written. An optional local data store 14 possibly includes the sequences of data values to be linked, from the local memory 14 in the register memory 5 Loading.

Die Extremwert-Ermittlungseinheit 13 wird, wie auch die arithmetische Logikeinheit ALU, von der Ablaufsteuerung 2 kontrolliert.The extreme value determination unit 13 is, like the arithmetic logic unit ALU, by the sequencer 2 controlled.

Zur Ablaufsteuerung ist in bekannter Weise der Befehlsdecoder 3 vorgesehen, um Programmbefehle zu decodieren und eine entsprechende Operation mit Hilfe der Steuereinheit 4 der Ablaufsteuerung 2 auszuführen.The command decoder is used for sequence control in a known manner 3 provided to decode program instructions and perform an appropriate operation using the control unit 4 the sequence control 2 perform.

Der Befehlsdecoder 3 und die Steuereinheit 4 sind so erweitert, dass ein weiterer MIN-MAX-Programmbefehl implementiert ist.The command decoder 3 and the control unit 4 are expanded so that another MIN-MAX program command is implemented.

Die Programmbefehle haben genau drei Parameter, nämlich eine erste Quellenadresse src1, für einen ersten Eingangswert OP1, eine zweite Quellenadresse src2 für einen zweiten Eingangswert OP2 und eine Zieladresse dest für das Berechnungsergebnis res der jeweiligen Operation, wobei der Registerspeicher 5 durch die erste Quellenadresse src1, die zweite Quellenadresse src2 und die Zieladresse dest referenziert werden.The program instructions have exactly three parameters, namely a first source address src1 for a first input value OP1, a second source address src2 for a second input value OP2 and a target address dest for the calculation result res of the respective operation, the register memory 5 are referenced by the first source address src1, the second source address src2 and the target address dest.

Der MIN-MAX-Programmbefehl hat somit das Format "minmax src1, scr2, dest". Diese Felder bzw. Parameter haben folgende Bedeutung:
src1: Registeradresse, welche das Datenwort (x[k]) enthält,
src2: Auswahl des Vergleichsergebnisses (0 = minimaler Wert und 1 = maximaler Wert),
dest: Registeradresse, in welcher das Vergleichsergebnis gespeichert wird.
The MIN-MAX program command thus has the format "minmax src1, scr2, dest". These fields or parameters have the following meaning:
src1: register address which contains the data word (x [k]),
src2: selection of the comparison result (0 = minimum value and 1 = maximum value),
dest: Register address in which the comparison result is saved.

Die Verwendung und Auswirkung dieses zusätzlichen MIN-MAX-Programmbefehls wird im folgenden detailliert erläutert.The Use and impact of this additional MIN-MAX program command is explained in detail below.

Die 2 lässt die zusätzliche Extremwert-Ermittlungseinheit im Detail als Blockdiagramm erkennen. Sie weist eine erste Vergleichseinheit 15 und eine zweite Vergleichseinheit 16 auf. Die erste und zweite Vergleichseinheit 15, 16 hat jeweils zwei Eingänge und einen Ausgang und dient zum Ausgeben des minimalen bzw. maximalen Wertes der an den beiden Eingängen anliegenden Datenworte an den Ausgang. Pro Takt wird die erste und zweite Vergleichseinheit 15, 16 gleichzeitig betrieben.The 2 shows the additional extreme value determination unit in detail as a block diagram. It has a first comparison unit 15 and a second comparison unit 16 on. The first and second comparison unit 15 . 16 has two inputs and one output and is used to output the minimum or maximum value of the data words at the two inputs to the output. The first and second comparison unit per cycle 15 . 16 operated simultaneously.

Weiterhin ist ein Minimum-Zwischenregister 17 vor einen der beiden Eingänge der ersten Vergleichseinheit 15 geklemmt. Das Mininum-Zwischenregister 15 kann wahlweise mittels eines ersten Multiplexers M1 mit dem am Ausgang der ersten Vergleichseinheit 15 anliegenden Datenwort oder insbesondere zur Initialisierung mit einem Datenwort an einer ersten definierten Registeradresse r0 des Registerspeichers 5 belegt werden.There is also a minimum intermediate register 17 in front of one of the two inputs of the first comparison unit 15 clamped. The Mininum intermediate register 15 can optionally by means of a first multiplexer M1 with that at the output of the first comparison unit 15 Data word present or in particular for initialization with a data word at a first defined register address r0 of the register memory 5 be occupied.

Ebenso ist ein Maximum-Zwischenregister 18 vor einen der beiden Eingänge der zweiten Vergleichseinheit 16 geklemmt. Das Maximum-Zwischenregister 18 kann mit einem zweiten Multiplexer M2 wahlweise mit dem Datenwort am Ausgang MAX-out der zweiten Vergleichseinheit 16, d. h. einem relativen maximalen Wert, oder einem Datenwort an einer zweiten definierten Registeradresse r1 des Registerspeichers belegt werden.There is also a maximum intermediate register 18 in front of one of the two inputs of the second comparison unit 16 clamped. The maximum intermediate register 18 can with a second multiplexer M2 optionally with the data word at the output MAX-out of the second comparison unit 16 , ie a relative maximum value, or a data word at a second defined register address r1 of the register memory.

Der erste Multiplexer M1 und und der zweite Multiplexer M2 kann z. B. mit Hilfe des Steuerbefehlswortes, d. h. des zweiten Parameters des MIN-MAX-Programmbefehls angesteuert werden (z.B. src2 = 2).The first multiplexer M1 and and the second multiplexer M2 can e.g. B. using the control command word, d. H. of the second parameter of the MIN-MAX program command can be controlled (e.g. src2 = 2).

Alternativ kann ein zusätzlicher Programmbefehl "nop" vorgesehen sein, der ausschließlich für das Vorbesetzen des Minimum-Zwischenregisters 17 und des Maximum-Zwischenregisters 18 mit den Datenworten vorgesehen ist, die in den Registern 5 der ersten definierten Registeradresse r0 und der zweiten definierten Registeradresse r1 abgelegt sind. Durch den nop-Programmbefehl wird der übrige Programmablauf nicht gestört.As an alternative, an additional program instruction "nop" can be provided, which is only used to preset the minimum intermediate register 17 and the maximum intermediate register 18 with the data words provided in the registers 5 the first defined register address r0 and the second defined register address r1 are stored. The rest of the program is not disturbed by the nop program command.

Die Daten in dem Minimum- und Maximum-Zwischenregister 17, 18 werden mit jedem Takt registriert.The data in the minimum and maximum intermediate register 17 . 18 are registered with every bar.

Hierbei werden die ersten beiden Multiplexer M1 und M2 wie folgt angesteuert:
Ausgang Multiplexer M1:
r0: wenn nop-Programmbefehl oder Steuerbefehlswort src2 = 2
MIN_out: alle anderen Programmbefehle
Ausgang zweiter Multiplexer M2:
r1: wenn nop-Programmbefehl oder Steuerbefehlswort src2 = 2
MAX_out: alle anderen Befehle
The first two multiplexers M1 and M2 are controlled as follows:
Output multiplexer M1:
r0: if nop program command or control command word src2 = 2
MIN_out: all other program commands
Output of second multiplexer M2:
r1: if nop program command or control command word src2 = 2
MAX_out: all other commands

Es ist weiterhin ein ein dritter Multiplexer M3 an den Ausgängen MIN-out, MAX-out der ersten und zweiten Vergleichseinheit 15, 16 sowie dem Ausgang ALU-out der arithmetischen Logikeinheit ALU vorgesehen, um wahlweise das Datenwort an dem Ausgang MIN-out der ersten Vergleichseinheit 15, dem Ausgang MAX-out der zweiten Vergleichseinheit 16 oder der arithmetischen Logikeinheit ALU an den Datenbus zu legen. Der dritte Multiplexer M3 wird wie folgt angesteuert:
Ausgang dritter Multiplexer M3:
MIN_out: wenn MIN-MAX-Programmbefehl und Steuerbefehlswort src2 = 0
MAX_out: wenn MIN-MAX-Programmbefehl und Steuerbefehlswort src2 = 1
ALU_out: alle anderen Befehle
There is also a third multiplexer M3 at the outputs MIN-out, MAX-out of the first and second comparison units 15 . 16 and the output ALU-out of the arithmetic logic unit ALU are provided to selectively the data word at the output MIN-out of the first comparison unit 15 , the output MAX-out of the second comparison unit 16 or the arithmetic logic unit ALU on the data bus. The third multiplexer M3 is controlled as follows:
Output of third multiplexer M3:
MIN_out: if MIN-MAX program command and control command word src2 = 0
MAX_out: if MIN-MAX program command and control command word src2 = 1
ALU_out: all other commands

Die Registeradresse zum Schreiben des am Ausgang des dritten Multiplexers M3 anliegenden Datenwortes in den Registerspeicher 5 wird durch den dritten Parameter des MIN-MAX-Programmbefehls, d. h. durch die Zieladresse dest festgelegt.The register address for writing the data word present at the output of the third multiplexer M3 into the register memory 5 is determined by the third parameter of the MIN-MAX program command, ie by the destination address dest.

Der MIN-MAX-Programmbefehl wird nun auf dem Mikroprozessor 1 eingesetzt, z.B. zur Berechnung einer Folge von 8 Datenworten x[i] mit i = 0, 1,..., 7 zusammen mit einem herkömmlichen Ladebefehl zum Laden eines Datenwortes z. B. aus dem lokalen Speicher 14 in den Registerspeicher 5 mit dem Format
Id[Adresse des zu ladenden Datenwortes], Registeradresse des Registerspeichers,
wobei ein Pluszeichen im Ladebefehl Id für ein Post-Inkrement des Adressenregisters steht, und der oben erwähnte nop-Programmbefehl wird in der nachfolgenden Befehlsfolge eingesetzt, sofern der Ladebefehl parallel ausgeführt wird:

Figure 00140001
Figure 00150001
The MIN-MAX program command is now on the microprocessor 1 used, eg to calculate a sequence of 8th Data words x [i] with i = 0, 1, ..., 7 together with a conventional load command for loading a data word z. B. from local storage 14 in the register memory 5 with the format
Id [address of the data word to be loaded], register address of the register memory,
where a plus sign in the load command Id stands for a post-increment of the address register, and the above-mentioned nop program command is used in the following command sequence if the load command is executed in parallel:
Figure 00140001
Figure 00150001

In den ersten beiden Schritten erfolgt somit das Laden des unter der Adresse a0 abgelegten ersten Datenwortes x[0] in den Registerspeicher 5 an die erste und zweite definierte Registeradresse r0 und r1.In the first two steps, the first data word x [0] stored at address a0 is loaded into the register memory 5 to the first and second defined register addresses r0 and r1.

In dem dritten Schritt wird die Adresse a0 inkrementiert und das zweite Datenwort x[1] in den Registerspeicher unter der Registeradresse r7 geladen. Mit Hilfe des nop-Programmbefehls wird das Minimum-Zwischenregister min_reg 17 mit dem ersten Datenwort x[0] beschrieben, der unter der ersten definierten Registeradresse r0 abgelegt ist. Ferner wird das Maximum-Zwischenregister max_reg 18 mit dem ersten Datenwort x[0] beschrieben, das ebenfalls unter der zweiten definierten Registeradresse r1 abgelegt ist.In the third step, the address a0 is incremented and the second data word x [1] is loaded into the register memory under the register address r7. With the help of the nop program instruction, the minimum intermediate register min_reg 17 with the first data word x [0], which is stored under the first defined register address r0. Furthermore, the maximum intermediate register max_reg 18 with the first data word x [0], which is also stored under the second defined register address r1.

In dem vierten Schritt wird die Adresse a0 wiederum inkrementiert und das dritte Datenwort x[2] unter der Registeradresse r7 abgelegt. Gleichzeitig erfolgt der MIN-MAX-Programmbefehl, wobei die erste Quellenadresse src1 auf die Registeradresse r7 gesetzt ist. Es wird somit gleichzeitig das vorher unter der Registeradresse r7 abgelegte zweite Datenwort x[1] ausgelesen. Das Steuerbefehlswort als Parameter der zweiten Quellenadresse src2 ist auf 0 gesetzt, so dass das am Ausgang der ersten Vergleichseinheit 15 anliegende Vergleichsergebnis, d. h. der relative minimale Wert, über den dritten Multiplexer M3 an den Datenbus 6 gelegt wird. Als Zieladresse zur Speicherung des relativen minimalen Wertes ist die Registeradresse r0 angegeben. Das Ergebnis der ersten Vergleichseinheit 15, d. h. der relative minimale Wert, wird somit über den Daten bus 6 in dem Registerspeicher 5 unter der Registeradresse r0 abgelegt. Dies ist jedoch zunächst für das weitere Verfahren ohne Belang, da diese Registeradresse r0 zunächst nicht weiter benötigt wird.In the fourth step, the address a0 is incremented again and the third data word x [2] is stored under the register address r7. At the same time, the MIN-MAX program instruction is issued, the first source address src1 being set to the register address r7. The second data word x [1] previously stored under register address r7 is thus simultaneously read out. The control command word as a parameter of the second source address src2 is set to 0, so that it is at the output of the first comparison unit 15 pending comparison result, ie the relative minimum value, via the third multiplexer M3 to the data bus 6 is placed. Register address r0 is specified as the destination address for storing the relative minimum value. The result of the first comparison unit 15 , ie the relative minimum value, is thus bus over the data 6 in the register memory 5 filed under register address r0. However, this is initially irrelevant for the further procedure, since this register address r0 is initially no longer required.

In den folgenden Schritten wird die Adresse a0 wieder inkrementiert (a0+), so dass die weiteren Datenworte x[3, 4...,7] jeweils mit den in der ersten und zweiten Vergleichseinheit 15, 16 ermittelten minimalen und maximalen Werten, die jeweils an das Minimum-Zwischenregister 17 und Maximum-Zwischenregister 18 zurückgekoppelt werden, verglichen werden. Durch das Zurückkoppeln und Vergleichen der eingelesenen Datenworte x[i] mit den jeweiligen minimalen und maximalen Werten an dem Ausgang MIN-out, MAX-out der ersten und zweiten Vergleichseinheit 15, 16 wird sichergestellt, dass die in dem Minimum-Zwischenregister 17 und Maximum-Zwischenregister 18 vorliegenden Extremwerte die relativen Minima bzw. Maxima der Berechnung der Folge von Datenworten x[i] darstellen.In the following steps, the address a0 is incremented again (a0 +), so that the further data words x [3, 4 ..., 7] each with those in the first and second comparison unit 15 . 16 determined minimum and maximum values, each to the minimum intermediate register 17 and maximum intermediate register 18 be fed back, compared. By coupling back and comparing the read data words x [i] with the respective minimum and maximum values at the output MIN-out, MAX-out of the first and second comparison units 15 . 16 it is ensured that those in the minimum intermediate register 17 and maximum intermediate register 18 present extreme values represent the relative minima or maxima of the calculation of the sequence of data words x [i].

Das Ergebnis des Ladebefehls Id steht erst im nächsten Takt zur Verfügung. Daher erfolgt ein weiterer MIN-MAX-Programmbefehl für den Vergleich des letzten Datenwortes x[7] wobei das Steuerbefehlswort src2 auf 0 und die Zieladresse dest auf die Registeradresse r0 gesetzt ist. Das durch den vorherigen Ladebefehl unter der Registeradresse r7 gespeicherte letzte Datenwort x[7] wird hierbei nochmals verglichen und der minimale Wert am Ausgang MIN-out der ersten Vergleichseinheit 15 über den dritten Multiplexer M3 an den Datenbus 6 gelegt und unter der Registeradresse r0 abgespeichert.The result of the load command Id is only available in the next cycle. A further MIN-MAX program command is therefore carried out for the comparison of the last data word x [7], the control command word src2 being set to 0 and the target address dest being set to the register address r0. The last data word x [7] stored by the previous load command under register address r7 is compared again and the minimum value at the output MIN-out of the first comparison unit 15 via the third multiplexer M3 to the data bus 6 and saved under register address r0.

Anschließend wird ein weiterer MIN-MAX-Programmbefehl ausgeführt, wobei die erste Quellenadresse wieder auf die Registeradresse r7 gesetzt ist. Es erfolgt somit wiederum ein Vergleich des letzten Datenwortes x[7]. Nunmehr ist jedoch das Steuerbefehlswort, d.h. der Parameter der zweiten Quellenadresse src2 auf 1 gesetzt, so dass der dritte Multiplexer M3 den Ausgang MAX-out der zweiten Vergleichseinheit 16 auf den Datenbus 6 leitet. Als Registeradresse ist r1 angegeben, so dass das im Maximum-Zwischenregister 18 abgelegte absolute Maximum unter der Registeradresse r1 abgespeichert wird.Another MIN-MAX program command is then executed, the first source address being set again to register address r7. The last data word x [7] is again compared. However, the control command word, ie the parameter of the second source address src2, is now set to 1, so that the third multiplexer M3 has the output MAX-out of the second comparison unit 16 on the data bus 6 passes. R1 is specified as the register address, so that in the maximum intermediate register 18 stored absolute maximum is stored under register address r1.

Anschließend kann durch Zugriff auf die Registeradresse r0 und r1 das absolute Minimum und absolute Maximum weiterverarbeitet werden.Then you can the absolute minimum by accessing register address r0 and r1 and absolute maximum can be processed further.

Das Laden der Datenworte x[i] in die Registerspeicher 5 kann unter Umständen nicht parallel erfolgen. Dies hängt von der Bauweise des Mikroprozessors 1 ab. In diesem Falle wird der nop-Programmbefehl nur einmal nach Abschluss der ersten beiden Ladebefehle zur Initialisierung benötigt. Die Befehlsfolge ist dann wie folgt:

Figure 00170001
The loading of data words x [i] into the register memory 5 may not be possible in parallel. This depends on the design of the microprocessor 1 from. In this case, the nop program command is only required once after initialization of the first two load commands. The command sequence is then as follows:
Figure 00170001

Die Befehlsfolge unterscheidet sich somit nur unwesentlich von dem parallelen Ladebefehl, wobei die Auswirkungen identisch sind.The Command sequence is therefore only slightly different from the parallel one Load command, the effects are identical.

Claims (4)

Mikroprozessor (1) zur Ausführung von Programmbefehlen mit einer Ablaufsteuerung (2) zur Ausführung der Programmbefehle, mit einer arithmetischen Logikeinheit (ALU), mit einem Datenbus (6), und mit mindestens einem Registerspeicher (5), der an den Datenbus (6) und die arithmetische Logikeinheit (ALU) geklemmt ist, wobei ein Programmbefehl genau eine erste Quellenadresse (src 1) für einen ersten Eingangswert (OP1), eine zweite Quellenadresse (src2) für einen zweiten Eingangswert (OP2) und eine Zieladresse (dest) für das Berechnungsergebnis (RES) für den Zugriff auf den mindestens einen Registerspeicher enthält und eine zusätzliche Extremwert-Ermittlungseinheit (13) zur Ermittlung des minimalen Wertes (MIN) und des maximalen Wertes (MAX) einer Folge von Datenworten (x[i]) durch schrittweises Einlesen einzelner Datenworte (x(i)) aus dem Registerspeicher (5) in die Extremwert-Ermittlungseinheit (13), dadurch gekennzeichnet, dass die Extremwert-Ermittlungseinheit (13) – eine erste Vergleichseinheit (15) mit zwei Eingängen und einem Ausgang (MIN-out) zum Ausgeben des minimalen Wertes der an den beiden Eingängen anliegenden Datenworte an den Ausgang (MIN-out), – eine zweite Vergleichseinheit (16) mit zwei Eingängen und einem Ausgang (MAX-out) zum Ausgeben des maximalen Wertes der an den beiden Eingängen anliegenden Datenworte an den Ausgang (MAX-out), – ein Minimum-Zwischenspeicher (17), der vor einen der beiden Eingänge der ersten Vergleichseinheit (15) geklemmt ist und mit einem ersten Multiplexer (M1) wahlweise mit dem Datenwort am Ausgang (MIN-out) der ersten Vergleichseinheit (15) oder einem Datenwort an einer definierten Registeradresse (r0) eines Registerspeichers (5) geladen werden kann, – ein Maximum-Zwischenspeicher (18), der vor einen der beiden Eingänge der zweiten Vergleichseinheit (16) geklemmt ist und mit einem zweiten Multiplexer (M2) wahlweise mit dem Datenwort am Ausgang (MAX-out) der zweiten Vergleichseinheit (16) oder einem Datenwort an einer definierten Registeradresse (r1) eines Registerspeichers (5) geladen werden kann, und – einen dritten Multiplexer (M3) an den Ausgängen der ersten und zweiten Vergleichseinheit (15,16) und der arithmetischen Logikeinheit (ALU) hat, um Datenworte von genau einem ausgewählten Ausgang (MIN-out, MAX-out, ALU-out) an eine angegebene Registeradresse der Registerspeicher (5, 14) zu schreiben, und – dass ein Min-Max-Programmbefehl in dem Mikroprozessor (1) derart implementiert ist, dass – mit der ersten Quellenadresse (src1) des Min-Max-Programmbefehls eine Registeradresse eines ausgewählten Datenwortes (x[i]) der Folge von Da tenworten (x[i]) in dem Registerspeicher (5) zum Laden des ausgewählten Datenwortes (x[i]) aus dem Registerspeicher (5) an jeweils einen Eingang sowohl der ersten Vergleichseinheit (15) als auch der zweiten Vergleichseinheit (16) angesteuert wird, – mit der zweiten Quellenadresse (src2) des Min-Max-Programmbefehls der dritte Multiplexer (M3) zum wahlweisen Leiten des minimalen Wertes am Ausgang (MIN-out) der ersten Vergleichseinheit (15) oder des maximalen Wertes am Ausgang (MAX-out) der zweiten Vergleichseinheit (16) oder des Ausgangs (ALU-out) der arithmetischen Logikeinheit (ALU) an den Datenbus (6) angesteuert wird, und – mit der Zieladresse (dest) des Min-Max-Programmbefehls der Registerspeicher (5) zum Speichern des an den Datenbus (6) geleiteten Wertes adressiert wird.Microprocessor ( 1 ) for executing program commands with a sequential control system ( 2 ) for executing the program instructions, with an arithmetic logic unit (ALU), with a data bus ( 6 ), and with at least one register memory ( 5 ) connected to the data bus ( 6 ) and the arithmetic logic unit (ALU) is clamped, with a program command exactly one first source address (src 1) for a first input value (OP1), a second source address (src2) for a second input value (OP2) and a target address (dest) for contains the calculation result (RES) for access to the at least one register memory and an additional extreme value determination unit ( 13 ) to determine the minimum value (MIN) and the maximum value (MAX) of a sequence of data words (x [i]) by gradually reading in individual data words (x (i)) from the register memory ( 5 ) in the extreme value determination unit ( 13 ), characterized in that the extreme value determination unit ( 13 ) - a first comparison unit ( 15 ) with two inputs and one output (MIN-out) for outputting the minimum value of the data words present at the two inputs to the output (MIN-out), - a second comparison unit ( 16 ) with two inputs and one output (MAX-out) for outputting the maximum value of the data words present at the two inputs to the output (MAX-out), - a minimum buffer ( 17 ) in front of one of the two inputs of the first comparison unit ( 15 ) is clamped and with a first multiplexer (M1) optionally with the data word at the output (MIN-out) of the first comparison unit ( 15 ) or a data word at a defined register address (r0) of a register memory ( 5 ) can be loaded - a maximum buffer ( 18 ), which is in front of one of the two inputs of the second comparison unit ( 16 ) is clamped and with a second multiplexer (M2) optionally with the data word at the output (MAX-out) of the second comparison unit ( 16 ) or a data word at a defined register address (r1) of a register memory ( 5 ) can be loaded, and - a third multiplexer (M3) at the outputs of the first and second comparison unit ( 15 . 16 ) and the arithmetic logic unit (ALU) has to transfer data words from exactly one selected output (MIN-out, MAX-out, ALU-out) to a specified register address of the register memory ( 5 . 14 ) and - that a min-max program instruction in the microprocessor ( 1 ) is implemented in such a way that - with the first source address (src1) of the min-max program instruction, a register address of a selected data word (x [i]) of the sequence of data words (x [i]) in the register memory ( 5 ) to load the selected data word (x [i]) from the register memory ( 5 ) to an input of both the first comparison unit ( 15 ) and the second comparison unit ( 16 ) is controlled, - with the second source address (src2) of the min-max program instruction, the third multiplexer (M3) for optionally routing the minimum value at the output (MIN-out) of the first comparison unit ( 15 ) or the maximum value at the output (MAX-out) of the second comparison unit ( 16 ) or the output (ALU-out) of the arithmetic logic unit (ALU) to the data bus ( 6 ) is controlled, and - with the target address (dest) of the min-max program command the register memory ( 5 ) to save the data to the data bus ( 6 ) directed value is addressed. Verfahren zur Ermittlung eines minimalen Wertes (MIN) und eines maximalen Wertes (MAX) einer Folge von Datenworten (x[i]) mit einem Mikroprozessor (1) nach Anspruch 1, gekennzeichnet durch a) Laden eines ersten Datenwortes (x[0]) der Folge von Datenworten (x[i]) in einen Registerspeicher (5) an mindestens eine definierte Registeradresse (r0, r1), b) Laden des ersten Datenwortes (x[0]) aus dem Registerspeicher (5) in den Minimum-Zwischenspeicher (17) und den Maximum-Zwischenspeicher (18), c) Ausführen einer Folge von MIN-MAX-Programmbefehlen für die Folge von Datenworten (x[i]) jeweils durch Laden eines im nächsten Schritt zu vergleichenden Datenwortes (x[k]) in einen Registerspeicher (5) und Auslesen des im vorhergehenden Schritt geladenen Datenwortes (x[k-1]) aus dem Registerspeicher (5) zum Vergleichen in der ersten Vergleichseinheit mit dem im vorhergehenden Schritt bestimmten minimalen Wert und zum Vergleichen in der zweiten Vergleichseinheit (16) mit dem im vorhergehenden Schritt bestimmten maximalen Wert erfolgt, wobei der ermittelte minimale Wert in den Minimum-Zwischenspeicher (17) und der ermittelte maximale Wert in den Maximum-Zwischenspeicher (18) geschrieben wird, d) Schreiben des minimalen Wertes am Ausgang der ersten Vergleichseinheit (15) nach Ausführung der Folge von MIN-MAX-Programmbefehlen mit dem letzten MIN-MAX-Programmbefehl der Folge an eine erste Registeradresse (r0) und e) Schreiben des maximalen Wertes am Ausgang der zweiten Vergleichseinheit (16) mit einem weiteren MIN-MAX-Programmbefehl an eine zweite Registeradresse (r1).Method for determining a minimum value (MIN) and a maximum value (MAX) of a sequence of data words (x [i]) with a microprocessor ( 1 ) according to claim 1, characterized by a) loading a first data word (x [0]) of the sequence of data words (x [i]) into a register memory ( 5 ) to at least one defined register address (r0, r1), b) loading the first data word (x [0]) from the register memory ( 5 ) in the minimum buffer ( 17 ) and the maximum buffer ( 18 ), c) Execution of a sequence of MIN-MAX program instructions for the sequence of data words (x [i]) in each case by loading a data word (x [k]) to be compared in the next step into a register memory ( 5 ) and reading the data word (x [k-1]) loaded in the previous step from the register memory ( 5 ) for comparison in the first comparison unit with the minimum value determined in the previous step and for comparison in the second comparison unit ( 16 ) with the maximum value determined in the previous step, the determined minimum value being stored in the minimum buffer ( 17 ) and the determined maximum value in the maximum buffer ( 18 ) is written, d) writing the minimum value at the output of the first comparison unit ( 15 ) after execution of the sequence of MIN-MAX program instructions with the last MIN-MAX program instruction of the sequence to a first register address (r0) and e) writing of the maximum value at the output of the second comparison unit ( 16 ) with a further MIN-MAX program command to a second register address (r1). Verfahren nach Anspruch 2, dadurch gekennzeichnet, dass das Laden des im nächsten Schritt zu vergleichenden Datenwortes (x[k]) und das Auslesen des im vorhergehenden Schritt geladenen Datenwortes (x[k-1]) gleichzeitig erfolgt.A method according to claim 2, characterized in that loading the next one Step to compare data word (x [k]) and read the data word (x [k-1]) loaded in the previous step simultaneously he follows. Verfahren nach Anspruch 2, dadurch gekennzeichnet, dass das Laden des im nächsten Schritt zu vergleichenden Datenwortes (x[k]) und das Auslesen des im vorhergehenden Schritt geladenen Datenwortes (x[k-1]) jeweils nacheinander erfolgt.A method according to claim 2, characterized in that loading the next one Step to compare data word (x [k]) and read the data word loaded in the previous step (x [k-1]) each successively.
DE2001141917 2001-08-28 2001-08-28 Microprocessor and method for determining a minimum and maximum value of a sequence of data words Expired - Fee Related DE10141917B4 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
DE2001141917 DE10141917B4 (en) 2001-08-28 2001-08-28 Microprocessor and method for determining a minimum and maximum value of a sequence of data words

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
DE2001141917 DE10141917B4 (en) 2001-08-28 2001-08-28 Microprocessor and method for determining a minimum and maximum value of a sequence of data words

Publications (2)

Publication Number Publication Date
DE10141917A1 DE10141917A1 (en) 2003-04-03
DE10141917B4 true DE10141917B4 (en) 2004-12-09

Family

ID=7696746

Family Applications (1)

Application Number Title Priority Date Filing Date
DE2001141917 Expired - Fee Related DE10141917B4 (en) 2001-08-28 2001-08-28 Microprocessor and method for determining a minimum and maximum value of a sequence of data words

Country Status (1)

Country Link
DE (1) DE10141917B4 (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5345410A (en) * 1991-05-30 1994-09-06 Hitachi, Ltd. Arithmetic-logic unit with modulo addition/substraction function and microprocessor using the same

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5345410A (en) * 1991-05-30 1994-09-06 Hitachi, Ltd. Arithmetic-logic unit with modulo addition/substraction function and microprocessor using the same

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Tricon Architecture Overview Handbook, User's Manual, V 1.3.0, Aug. 1999 *

Also Published As

Publication number Publication date
DE10141917A1 (en) 2003-04-03

Similar Documents

Publication Publication Date Title
DE69534113T2 (en) Compression of the command words of a computer
DE60210494T2 (en) HIGH-SPEED CALCULATION IN ARITHMETIC AND LOGIC CIRCUITS
DE2714805C2 (en)
DE3587213T2 (en) PROCESSING UNIT WITH THE ABILITY TO EXECUTE ONE OR MORE PROGRAMS WITH A NUMBER OF FUNCTIONAL UNITS.
DE3854701T2 (en) Method and device for changing micro instructions with a macro instruction pipeline.
DE2318069A1 (en) COMPUTER CONTROL SYSTEM USING MICROPROGRAMMING AND STATIC / DYNAMIC EXTENSION OF CONTROL FUNCTIONS USING HARDWIRED LOGICAL MATRIX
DE1549480A1 (en) Data processing system
DE3856139T2 (en) microprocessor
DE60216210T2 (en) Binary size comparator
DE1549474B2 (en) Arrangement in an electronic digital data processing system for executing a first command and simultaneous decoding of a following command
DE112004001040T5 (en) Method and data processor with reduced operation interruption due to operand dependencies
DE3421737C2 (en) Device for determining an overlap of operands
DE2134816A1 (en) FACILITY FOR ADDRESS TRANSLATION
DE3121046C2 (en)
DE10141917B4 (en) Microprocessor and method for determining a minimum and maximum value of a sequence of data words
DE2403039C2 (en) Device for executing commands in an address-extended electronic data processing system
DE102020103414A1 (en) COMPRESSION METHODS FOR DATA STRUCTURES SUITABLE FOR ARTIFICIAL NEURAL NETWORKS
DE69927910T2 (en) Instruction output circuitry and method of out-of-order instruction execution whereby reference dependency information is set in an instruction when a succeeding instruction is stored in an instruction buffer d
DE4010896C2 (en) Method and circuit for processing synchronization commands
DE2204680C3 (en) Microprogram controller
DE3908086C1 (en) Method for compressing and decompressing digital data and device for carrying out the method
DE69833092T2 (en) System and method with mode bits, to support multiple coding standards.
DE3340078A1 (en) PROCESSOR CELL FOR USE IN AN ARRANGEMENT MADE FROM SUCH CELLS
EP1091290B1 (en) Processor system with Store or Load instruction having splitting information
EP1159675B1 (en) Microprocessor and method for addressing in a microprocessor

Legal Events

Date Code Title Description
OP8 Request for examination as to paragraph 44 patent law
8364 No opposition during term of opposition
8339 Ceased/non-payment of the annual fee