SU1693610A2 - Device for microprocessor checking - Google Patents

Device for microprocessor checking Download PDF

Info

Publication number
SU1693610A2
SU1693610A2 SU894763201A SU4763201A SU1693610A2 SU 1693610 A2 SU1693610 A2 SU 1693610A2 SU 894763201 A SU894763201 A SU 894763201A SU 4763201 A SU4763201 A SU 4763201A SU 1693610 A2 SU1693610 A2 SU 1693610A2
Authority
SU
USSR - Soviet Union
Prior art keywords
output
input
microprocessor
stack
counter
Prior art date
Application number
SU894763201A
Other languages
Russian (ru)
Inventor
Игорь Зелимович Альтерман
Михаил Аркадьевич Гладштейн
Валерий Михайлович Комаров
Николай Алексеевич Шубин
Original Assignee
Рыбинский Авиационный Технологический Институт
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 Рыбинский Авиационный Технологический Институт filed Critical Рыбинский Авиационный Технологический Институт
Priority to SU894763201A priority Critical patent/SU1693610A2/en
Application granted granted Critical
Publication of SU1693610A2 publication Critical patent/SU1693610A2/en

Links

Landscapes

  • Debugging And Monitoring (AREA)

Description

1one

(61) 1444783 (21)4763201/24 (22)27.11.89 (46)23.11.91. Бюл. №43 (71) Рыбинский авиационный технологический институт(61) 1444783 (21) 4763201/24 (22) 11/27/89 (46) 11/23/91. Bul №43 (71) Rybinsk Aviation Technological Institute

(72)И.З.Альтерман, М.А.Гладштейн, В.М.Комаров и Н.А.Шубин (53)681.3(088.8)(72) I.Z.Alterman, M.A. Gladshtein, V.M. Komarov and N.A. Shubin (53) 681.3 (088.8)

(56)Авторское свидетельство СССР Nfc 1444783, кл. G 06 F 11/28, 1987.(56) USSR Author's Certificate Nfc 1444783, cl. G 06 F 11/28, 1987.

(54) УСТРОЙСТВО ДЛЯ КОНТРОЛЯ МИКРОПРОЦЕССОРА(54) DEVICE FOR THE CONTROL OF A MICROPROCESSOR

(57)Изобретение относитс  к вычислительной технике и может найти применение при(57) The invention relates to computing and can be used in

построении микропроцессорных устройств дл  повышени  их надежности. Цель изобретени  - расширение функциональных возможностей за счет контрол  содержимого указател  стека микропроцессора при выполнении стековых команд. Устройство дл  контрол  микропроцессора содержит счетчик 1, схему 2 сравнени , регистры 4 и 5, блок посто нной пам ти 6, сумматор 7, мультиплексор 8, элементы И 3, 9 - 11, триггеры 13, 14 и элемент НЕ 12. В устройство введены дешифратор 15, регистры 16, 17, сумматор 18, схема сравнени . 19, счетчик 20, мультиплексор 21, блок задани  22 границы стека, .элементы И 23-25, элементы ИЛИ 27 - 29 и триггер 30. 1 ил., 1 табл.building microprocessor devices to increase their reliability. The purpose of the invention is to expand the functionality by controlling the contents of the microprocessor stack pointer when executing stack instructions. The device for controlling the microprocessor contains a counter 1, a comparison circuit 2, registers 4 and 5, a block of permanent memory 6, an adder 7, a multiplexer 8, elements AND 3, 9-11, triggers 13, 14 and an element HE 12. The device is entered decoder 15, registers 16, 17, adder 18, comparison circuit. 19, counter 20, multiplexer 21, task block 22 stack boundaries, AND 23-25 elements, OR elements 27-29 and trigger 30. 30. Il, 1 tab.

гg

3131

(L

СWITH

о юo you

0000

оabout

юYu

Изобретение относитс  к вычислительной технике и  вл етс  усовершенствованием устройства по авт.св. № 1444783.The invention relates to computing and is an improvement of the device according to the author. No. 1444783.

Цель изобретени  - расширение функциональных возможностей за счет контрол  содержимого указател  стека микропроцессора при выполнении стековых команд.The purpose of the invention is to expand the functionality by controlling the contents of the microprocessor stack pointer when executing stack instructions.

На-чертеже изображена структурна  схема устройства.The drawing shows a block diagram of the device.

Устройство дл  контрол  микропроцессорной системы содержит первый счетчик 1, первую схему 2 сравнени  и первый 3 элемент И, первый 4 и второй 5 регистры, блок 6 посто нной пам ти, первый сумматор 7, первый мультиплексор 8, второй 9, третий 10 и четвертый 11 элементы И, элемент НЕ 12, первый 13 и второй 14 триггеры, дешифратор 15, третий 16 и четвертый 17 регистры , второй сумматор 18, вторую схему 19 сравнени , второй счетчик 20, второй мультиплексор 21, блока 22 задани  границы стека, п тый элемент И 23, шестой 24 и седьмой 25 элементы И, контролируемый микропроцессор 26, первый 27, второй 28 и третий 29 элементы ИЛИ и третий триггер 30, выход 31 неисправности устройства.The device for controlling the microprocessor system contains the first counter 1, the first comparison circuit 2 and the first 3 element I, the first 4 and second 5 registers, the persistent memory block 6, the first adder 7, the first multiplexer 8, the second 9, the third 10 and the fourth 11 elements AND, element 12, first 13 and second 14 flip-flops, decoder 15, third 16 and fourth 17 registers, second adder 18, second comparison circuit 19, second counter 20, second multiplexer 21, block 22 defining stack boundaries, fifth element And 23, the sixth 24 and the seventh 25 And elements, controlled microprocess p 26, the first 27, second 28 and third 29 element or the third flip-flop 30, the output 31 malfunction.

Устройство- работает следующим образом .The device works as follows.

После включени  питани  в схеме контролируемого микропроцессора 26 формируетс  сигнал сброса RESET, который через шину управлени  поступает на входы сброса первого счетчика 1, второго регистра 5 и триггеров 13, 14 и 30, что приводит к их установке в нулевое состо ние. Одновременно счетчик команд микропроцессора 26 также устанавливаетс  в нулевое состо ние . Затем микропроцессор 26 начинает последовательную выборку и исполнение команд по заданной программе. Дл  микропроцессора КР580 последние могут быть однобайтными, двухбайтными и трех- байтными. В результате этого адрес следующей команды может быть больше адреса предыдущей команды соответственно на одну, две или три единицы младшего разр да при условии правильного функционировани  микропроцессора. Кроме того, в системе команд микропроцессора имеютс  команды переходов, которые могут скачком измен ть содержимое счетчика команд микропроцессора .After power is turned on in the controlled microprocessor circuit 26, a reset signal RESET is generated, which is fed through the control bus to the reset inputs of the first counter 1, the second register 5 and the flip-flops 13, 14 and 30, which causes them to reset to zero. At the same time, the microprocessor command counter 26 is also set to the zero state. Then the microprocessor 26 begins the sequential selection and execution of commands for a given program. For the KP580 microprocessor, the latter can be single-byte, double-byte and three-byte. As a result, the address of the next command may be greater than the address of the previous command by one, two or three lower-order units, provided the microprocessor functions correctly. In addition, there are transition instructions in the microprocessor's instruction set, which can abruptly change the contents of the microprocessor instruction counter.

Момент считывани  первого байта команды легко идентифицируетс  по совпадению сигналов на лини х выборки первого байта команды (М1) и чтени  пам ти (MEMR), шины управлени  микропроцессора 26. В этот момент срабатывает третий элемент И 10 и код первого байта команды, установленный в это врем  на шине данныхThe moment of reading the first byte of the command is easily identified by the coincidence of signals on the sampling lines of the first byte of the command (M1) and reading memory (MEMR), microprocessor control bus 26. At this point, the third element AND 10 and the code of the first byte of the command set to this data bus time

фиксируетс  в первом регистре 4. Этот байт поступает на адресные входы блока 6 посто нной пам ти, в результате чего на его основном выходе будет установлен код,is fixed in the first register 4. This byte goes to the address inputs of block 6 of the permanent memory, as a result of which a code will be set at its main output,

равный количеству байт в команде, а на дополнительном выходе - код типа команд (операционна  команда - команда перехода ).equal to the number of bytes in a command, and at the additional output - a command type code (the operational command is a transition command).

В частности, дл  контрол  микро0 процессора серии КР580 коды, хранимые данные в блбке 6 посто нной пам ти, должны соответствовать данным, приведенным в табл.1. Кажда  клеточка этой таблицы соответствует одному из 256 воз5 можных адресов. Код в каждой клетке состоит из двух цифр. Права  цифра соответствует дес тиричному эквиваленту двоичного кода, формируемого на основном выходе блока 6 посто нной пам ти иIn particular, in order to control the microprocessor of the KP580 series, the codes stored in the block 6 of the permanent memory should correspond to the data given in Table 1. Each cell of this table corresponds to one of the 256 possible addresses. The code in each cell consists of two numbers. The right number corresponds to the decimal equivalent of the binary code generated at the main output of block 6 of the permanent memory and

0 равна количеству байт (1,2 или 3) команды микропроцессора. Лева  цифра соответствует состо нию дополнительного выхода блока 6 посто нной пам ти и равна единице , если адресный байт соответствует ко5 манде перехода, в противном случае равна нулю.0 is equal to the number of bytes (1,2 or 3) of the microprocessor command. The left digit corresponds to the state of the additional output of the block 6 of the permanent memory and is equal to one if the address byte corresponds to the transition command, otherwise it is zero.

Таким образом, на выходах блока 6 посто нной пам ти непосредственно после момента фиксации первого байта очеред0 ной команды в первом регистре 4 будет установлен код в соответствии с данными таблицы.Thus, the outputs of block 6 of the permanent memory immediately after the moment of fixation of the first byte of the order command in the first register 4 will set the code in accordance with the data in the table.

В результате возможны две ситуации: очередна  команда не  вл етс  командойAs a result, two situations are possible: the next command is not the command

5 перехода; очередна  команда - команда перехода .5 transitions; the next command is the transition team.

В первом случае на вход D первого триггера 13 поступает сигнал логического О, и по окончании сигнала с выхода третьего эле0 мента И 10 первый триггер 13 не измен ет своего состо ни . Код байтности очередной команды с основного выхода блока 6 посто нной пам ти поступает на первый вход сумматора 7, а на второй его вход черезIn the first case, the input D of the first trigger 13 receives a logical O signal, and at the end of the signal from the output of the third element And 10 the first trigger 13 does not change its state. The byte code of the next command from the main output of the block 6 of the permanent memory is fed to the first input of the adder 7, and to the second input of it through

5 первый мультиплексор 8 поступает код из второго регистра 5.5, the first multiplexer 8 receives a code from the second register 5.

По этим данным первый сумматор 7 формирует сумму и перенос (дл  микропроцессора КР580 мультиплексор 8, сумматор 7According to these data, the first adder 7 forms the sum and transfer (for the microprocessor KP580 multiplexer 8, the adder 7

0 и регистр 5 содержат по два двоичных разр да , так как двоичный код байтности может быть только 01,10 или 11). Сумма поступает на вход второго регистра 5 и записываетс  в него по заднему фронту сигнала с выхода0 and register 5 each contain two binary bits, since the binary byte code can only be 01.10 or 11). The sum goes to the input of the second register 5 and is written into it on the falling edge of the signal from the output

5 третьего элемента И 10 благодар  элементу НЕ 12. Сигнал с выхода последнего проходит также на вход инкрементировани  первого счетчика 1 через второй элемент И 9г если значение переноса на выходе первого сумматора 7 равно логической 1.5 of the third element AND 10 due to the element NO 12. The signal from the output of the last passes also to the input of the increment of the first counter 1 through the second element I 9g if the transfer value at the output of the first adder 7 is equal to logical 1.

Таким образом в первом счетчике 1 (старшие разр ды) и во втором регистре 5 (младшие разр ды) формируетс  ожидаемый код адреса первого байта следующей команды, Этот код поступает на вход первой схемы 2 сравнени . В момент извлечени  первого байта следующей команды микропроцессор 26 формирует ее адрес на шине адреса и сигналы М1 и MEMR на шине управлени .Thus, in the first counter 1 (most significant bits) and in the second register 5 (least significant bits) the expected address code of the first byte of the next command is generated. This code is fed to the input of the first comparison circuit 2. At the moment of extracting the first byte of the next command, microprocessor 26 generates its address on the address bus and the signals M1 and MEMR on the control bus.

Если микропроцессор работает без сбоев , то выданный адрес совпадает с ожидаемым адресом, поступающим из первого счетчика 1 и второго регистра 5. В этом случае на инвертирующем выходе первой схемы 2 сравнени  устанавливаетс  нулевой потенциал, что обеспечивает пассивный логический уровень на выходе первого элемента И 3.If the microprocessor operates without failures, then the issued address coincides with the expected address coming from the first counter 1 and the second register 5. In this case, the zero potential is set at the inverting output of the first comparison circuit 2, which ensures a passive logic level at the output of the first And 3 element.

Если же имеет место сбой, то адреса будут неравны, на выходе первой схемы 2 сравнени  по вл етс  сигнал логической единицы. Совпадение этого сигнала с активным сигналом с инверсного выхода первого триггера 13 и сигналом с выхода третьего элемента И 10 вызывает срабатывание первого элемента И 3, установку второго триггера 14 и по вление на выходе третьего элемента ИЛИ 29, т.е. на выходе 31 устройства , активного сигнала, свидетельствующего о неправильной работе микропроцессора.If there is a failure, then the addresses will be unequal, a logical unit signal appears at the output of the first comparison circuit 2. The coincidence of this signal with the active signal from the inverse output of the first trigger 13 and the signal from the output of the third element And 10 triggers the first element And 3, sets the second trigger 14 and the output of the third element OR 29, i.e. output 31 of the device, the active signal indicating a malfunction of the microprocessor.

Если же очередна  команда - команда перехода, то на дополнительном выходе блока 6 посто нной пам ти будет установлен единичный сигнал. В результате по заднему фронту сигнала с выхода третьего элемента И 10, благодар  элементу НЕ 12, первый триггер 13 переходит в единичное состо ние. Сигнал с его инверсного выхода блокирует контроль совпадени  адресов при извлечении следующей команды с помощью первого элемента И 3. Кроме того, происходит переключение первого мультиплексора 8 и он подключает к второму входу первого сумматора 7 младшие разр ды шины адреса контролируемого микропроцессора .If the next command is a transition command, then a single signal will be set at the additional output of block 6 of the permanent memory. As a result, on the falling edge of the signal from the output of the third element AND 10, thanks to the element NOT 12, the first trigger 13 goes into one state. The signal from its inverse output blocks the control of address matching when the next command is extracted using the first element And 3. In addition, the first multiplexer 8 switches and it connects the lower bits of the address of the controlled microprocessor to the second input of the first adder 7.

Таким образом, при извлечении первого байта команды следующий за командой перехода контроль не проводитс , а ее адрес плюс байтность команды (ожидаемый адрес следующей команды) фиксируетс  в первом счетчике t и втором регистре 5. Фиксаци  старших разр дов адреса в счетчике 1 производитс  сигналом с выхода четвертого элемента И 11, работа которого разрешаетс  единичным сигналом с выхода триггера 13,Thus, when extracting the first byte of a command, the control following the transition command is not performed, and its address plus the command byte (the expected address of the next command) is recorded in the first counter t and the second register 5. The high-order address bits in counter 1 are produced by the output signal the fourth element And 11, whose operation is permitted by a single signal from the output of the trigger 13,

Запись младших разр дов, представл ющих собой сумму младших разр дов адреса очередной команды с ее байтностью с выхода первого сумматора во второй регистр 5, а также учет переноса с выхода сумматора 7 в счетчик 1 происходит совер- 5 шенно аналогично первому случаю. Кроме того, по окончании считывани  команды, следующей за командой перехода (если она. конечно, сама не  вл етс  командой перехода ), происходит возврат первого триггераThe entry of the least significant bits, which are the sum of the lower bits of the address of the next command with its byte from the output of the first adder to the second register 5, as well as the transfer account from the output of the adder 7 to counter 1, occurs quite similarly to the first case. In addition, after reading the command following the transition command (if it is, of course, not the transition command itself), the first trigger returns.

0 13 в состо ние логического О и, следовательно , восстанавливаетс  режим контрол . Контроль за изменением программного счетчика при выполнении команд перехода0 13 to the logical O state and, therefore, the monitoring mode is restored. Control over program counter changes when executing transition commands

5 проводитс  в устройстве на основе контрол  содержимого указател  стека микропроцессора . При сбое программного счетчика при выполнении команд перехода происходит выполнение ложного потока команд, в5 is conducted in the device based on the control of the contents of the microprocessor stack pointer. If the program counter fails, the transition command executes a false command stream;

0 результате чего указатель стека выходит за допустимые границы, которые заранее могут быть определены программистом.As a result, the stack pointer is out of range, which can be determined in advance by the programmer.

Кроме того, возможный сбой указател  стека микропроцессора сам становитс In addition, the possible failure of the microprocessor's stack pointer itself becomes

5 причиной неправильной установки программного счетчика, не обнаруживаемой описанной частью устройства.5 the reason for the incorrect installation of the software counter that is not detectable by the described part of the device.

Дл  контрол  за поведением указател  стека микропроцессора 2 дешифратор 15To control the behavior of the microprocessor stack pointer 2, the decoder 15

0 настраиваетс  на селекцию только одной команды - Загрузка указател  стека. В системе команд микропроцессора КР580 этой командой  вл етс  команда LXf SP, D16. Когда в первом регистре 4 фиксируетс 0 is configured to select only one command. - Loading the stack pointer. In the KP580 microprocessor command system, this command is the command LXf SP, D16. When in the first register 4 is fixed

5 код этой команды, единичный сигнал с выхода дешифратора разрешает работу п того элемента И 23. В результате в следующих циклах выполнени  этой команды по сигналу MEMR на шине управлени  производитс 5 the code of this command, a single signal from the output of the decoder enables the operation of the fifth element AND 23. As a result, in the following cycles of the execution of this command, the MEMR signal on the control bus is performed

0 запись в регистры 16 и 17 данных, адресующих вершину стека.0 entry in registers 16 and 17 of data addressing the top of the stack.

Эти же данные фиксируютс  в указателе стека микропроцессора 26. Одновременно с записью данных в регистры 16 и 17 по сиг5 налу с выхода п того элемента И 23 производитс  очистка второго счетчика 20. Данные о вершине стека с выходов регистров 16 и 17 посто нно присутствуют на первом входе второго сумматора 18. На второйThe same data is recorded in the index of the stack of the microprocessor 26. Simultaneously with the recording of data in registers 16 and 17 on the signal from the output of the element And 23, the second counter 20 is cleared. The data on the top of the stack from the outputs of registers 16 and 17 are constantly present on the first the input of the second adder 18. On the second

0 вход сумматора 18 поступает код с выхода счетчика 20,  вл ющийс  текущим смещением указател  стека микропроцессора 26 или, иначе, индексом относительно вершины стека.0 the input of the adder 18 receives the code from the output of the counter 20, which is the current offset of the pointer of the microprocessor 26 or, otherwise, an index relative to the top of the stack.

5 Разр дность счетчика 20 в общем случае определ етс  разр дностью адреса, поступающего на первый вход сумматора 18. Однако разр дность счетчика 20 может быть существенно уменьшена с учетом выполнени  реальных программ В этих случа х старшие разр ды второго входа сумматора5 The width of the counter 20 is generally determined by the width of the address arriving at the first input of the adder 18. However, the width of the counter 20 can be significantly reduced taking into account the implementation of real programs. In these cases, the higher bits of the second input of the adder

18 должны быть подключены к потенциалу Лог.1, так как сумматор 18 реализует функцию вычитани  вершины стека и индекса, т.е. дл  корректного отслеживани  указател  стека микропроцессора индекс должен быть установлен на втором входе сумматора 18 в дополнительном коде.18 must be connected to the potential of Log.1, since the adder 18 implements the function of subtracting the top of the stack and the index, i.e. In order to correctly track the microprocessor stack pointer, the index must be set at the second input of the adder 18 in the additional code.

В момент обращени  к стеку микропроцессора 26 формируетс  сигнал STACK на шине управлени , который разблокирует элементы И 24 и 25. При реализации цикла Запись в стек сигнал микропроцессора MEMW с шины управлени  через элемент И 25 поступает на вход декрементировани  второго счетчика 20, в результате чего его состо ние уменьшаетс  на единицу, и код на выходе сумматора 18 также уменьшаетс  на единицу. Таким образом, на выходе сумматора 18 формируетс  ожидаемый код указател  стека микропроцессора 26. Этот код поступает на вход второй схемы 19 сравнени .At the moment of accessing the stack of microprocessor 26, a STACK signal is generated on the control bus that unlocks AND 24 and 25. When the cycle is implemented, the MEMW microprocessor signal from the control bus through the AND 25 element enters the decrement input of the second counter 20, resulting in the state is decremented by one, and the code at the output of the adder 18 is also decremented by one. Thus, at the output of the adder 18, the expected index code of the microprocessor stack 26 is formed. This code is fed to the input of the second comparison circuit 19.

Если микропроцессор 26 работает без сбоев, то выданный адрес  чейки стека совпадает с ожидаемым адресом, поступающим из сумматора 18. В этом случае на инвертирующем выходе второй схемы 19 сравнени  устанавливаетс  нулевой потенциал , что обеспечивает пассивный логический уровень на входе второго элемента ИЛИ 28.If microprocessor 26 operates without failures, then the issued cell address of the stack matches the expected address from adder 18. In this case, the inverting output of the second comparison circuit 19 sets zero potential, which ensures a passive logic level at the input of the second element OR 28.

Если же имеет место сбой указател  стека , то адреса не равны, на выходе второй схемы 19 сравнени  по вл етс  сигнал логической 1 которыйчерезэлементИЛИ28 проходит на вход третьего триггера 30. Установка его в единичное состо ние произойдет в момент среза сигнала MEMW, который через инверсный вход первого элемента ИЛИ 27 поступает на синхровход третьего триггера 30. Единичный сигнал с триггера 30 поступает через третий элемент ИЛИ 29 на выход устройства 31 и свидетельствует о неправильной работе микропроцессора 26.If the stack pointer fails, then the addresses are not equal, at the output of the second comparison circuit 19 a logical signal 1 appears which is through the element OR28 passes to the input of the third trigger 30. It will be set to one at the time of the cut-off of the MEMW signal the first element OR 27 is supplied to the synchronous input of the third trigger 30. A single signal from the trigger 30 is supplied through the third element OR 29 to the output of the device 31 and indicates the microprocessor 26 does not work correctly.

Таким образом, после реализации цикла записи информации в стек на выходе второго сумматора 18 всегда устанавливаетс  адрес последней заполненной  чейки стека. Этот же адрес фиксируетс  в указателе стека микропроцессора 26 по окончании выполнени  стековой команды.Thus, after the implementation of the cycle of writing information to the stack at the output of the second adder 18, the address of the last filled stack cell is always set. The same address is recorded in the stack pointer of the microprocessor 26 upon completion of the execution of the stack instruction.

Если сбои указател  стека микропроцессора 26 не имеют место, то в цикле Чтение из стека микропроцессор 26 выдает на шину адреса адрес  чейки стека, соответствующий адресу на выходе сумматора 18. Тогда на инвертирующем выходе второй схемы 19 сравнени  устанавливаетс  нулевой потенциал, свидетельствующий о равенстве адресов на ее входах. Результат сравнени  адресов фиксируетс  в третьем триггере 30 по фронту синхросигнала, поступающего на соответствующий вход триггера 30 через элементы И 24 и ИЛИ 27 в момент совпадени  сигналов STACK и MEMR на шине управлени  микропроцессора 26.If the microprocessor stack pointer 26 fails, then in the Read cycle from the stack, the microprocessor 26 outputs the address of the stack cell to the address bus corresponding to the address at the output of the adder 18. Then the inverting output of the second comparison circuit 19 establishes zero potential, indicating that the addresses are equal her entrances. The result of the address comparison is fixed in the third trigger 30 on the front of the synchronizing signal, which arrives at the corresponding input of the trigger 30 through the AND 24 and OR 27 elements at the time of the STACK and MEMR signals on the microprocessor control bus 26.

Одновременно этот же сигнал, поступа At the same time, the same signal

0 на вход инкрементировани  счетчика 20, увеличивает на единицу индекс на его выходе , соответственно увеличива  на единицу индекс на его выходе, соответственно увеличива  на единицу адрес на выходе сумма5 тора 18. Это полностью согласуетс  с действи ми микропроцессора 26, который по окончании каждого цикла Чтение из стека увеличивает содержимое указател  стека на единицу.0 to the input of incrementing the counter 20, increases by one the index at its output, respectively, increasing by one the index at its output, respectively increasing by one the output address of the sum of 5 torus 18. This is fully consistent with the actions of the microprocessor 26, which at the end of each cycle Read from the stack increases the contents of the stack pointer by one.

0 В случае сбо  указател  стека микропроцессора 26 фиксаци  сигнала ошибки на выходе 31 устройства при выполнении цикла Чтение из стека производитс  аналогично .0 In the case of the microprocessor 26 stack pointer fixation, an error signal is fixed at the device output 31 when executing a cycle. The reading from the stack is performed similarly.

5 Дл  контрол  глубины стека, нарушаемой вследствие ложных переходов программного счетчика микропроцессора 26, второй мультиплексор 21 производит сопоставление индекса на выходе счетчика 20 с кодом,5 To control the stack depth violated due to false transitions of the program counter of the microprocessor 26, the second multiplexer 21 maps the index at the output of the counter 20 to a code,

0 установленным в блоке 22 задани . Двоичный коде выхода блока 22 задани  подключает на инвертирующий выход мультиплексора 21 соответствующий разр д с выхода счетчика 20. Данный разр д выбираетс  пользовате5 лем с помощью блока 22 задани  в качестве границы стека, исход  из программы, выполн емой микропроцессором. Например, если глубина стека равна 64  чейкам пам ти , то в качестве контрольного выбираетс  60 installed in block 22 tasks. The binary output code of task block 22 connects to the inverting output of multiplexer 21 a corresponding bit from the counter 20 output. This bit is selected by the user using task block 22 as a stack boundary, starting from the program executed by the microprocessor. For example, if the stack depth is 64 memory locations, then 6

0-7 разр д счетчика 20. По вление на нем сигнала логического О в момент реализации стековой программы будет свидетельст- вовать о переполнении стека, т.е. о нарушении выбранной глубины.0-7 is the counter's 20 bit. The appearance of a logical O signal at it at the time of the stack program implementation will indicate a stack overflow, i.e. about the violation of the selected depth.

5 В результате на инверсном выходе мультиплексора 21 по вл етс  единичный сигнал, который через элемент ИЛИ 28 поступает на D-вход триггера 30 и вызывает его установку. Единичный сигнал с выхода5 As a result, a single signal appears at the inverse output of multiplexer 21, which through the element OR 28 enters the D input of the trigger 30 and causes its installation. Single output signal

0 триггера 30 через элемент ИЛИ 29 поступает на выход ошибки 31 устройства, свидетельству  тем самым о нарушении правильного функционировани  микропроцессора 26.0 trigger 30 through the element OR 29 is fed to the output of the error 31 of the device, thereby indicating a violation of the correct functioning of the microprocessor 26.

5 Если микропроцессор 26 работает без сбоев, то при реализации обращени  к стеку на выбранном входе мультиплексора 21 всегда присутствует сигнал логической 1. который не может перевести триггер 30 в активное состо ние.5 If the microprocessor 26 operates without failures, then when implementing the access to the stack at the selected input of the multiplexer 21 there is always a logical signal 1. which cannot transfer the trigger 30 to the active state.

Таким образом, в устройстве посто нно контролируетс  правильность изменени  программного счетчика (за исключением моментов перехода) и указател  стека микропроцессора . Также в устройстве контро- лируетс  глубина стека, косвенно характеризующа  корректность переходов микропроцессора по программе.Thus, the device constantly monitors the correctness of the change in the program counter (with the exception of the transition points) and the microprocessor stack pointer. The device also controls the depth of the stack, which indirectly characterizes the correctness of microprocessor transitions according to the program.

Сигнал ошибки с выхода устройства может быть использован различными способа- ми, например, дл  световой или звуковой сигнализации о неправильной работе микропроцессора , дл  прерывани  или сброса микропроцессора с целью восстановлени  вычислений после сбо  и дл  подключени  резервного микропроцессора.The error signal from the output of the device can be used in various ways, for example, to light or sound the microprocessor to malfunction, to interrupt or reset the microprocessor to restore the calculations after a failure, and to connect a backup microprocessor.

Claims (1)

Формула изобретени Invention Formula Устройство дл  контрол  микропроцессора по авт.св. № 1444783, отличающеес  тем, что, с целью расширени  функциональных возможностей за счет контрол  содержимого указател  стека микропроцессора при выполнении стековых команд, оно содержит дешифратор, третий и четвертый регистры, второй сумматор, вторую схему сравнени , второй счетчик, второй мультиплексор, блок задани  границы стека, п тый, шестой и седьмой элементы И, первый, второй и третий элементы ИЛИ и третий триггер, причем информаци- онный вход третьего регистра соединен с входом устройства дл  подключени  к шине данных контролируемого микропроцессора , выход третьего регистра соединен с информационным входом четвертого регистра, выход которого и выход третьего регистра образуют первый информационный вход второго сумматора, второй информационный вход которого и информационный вход второго мультиплексора соединены с выходом второго счетчика, вход сброса которого и входы синхронизации третьего и четвертого регистров соединены с выходом п того элемента И, первыйA device for controlling a microprocessor auth.St. No. 1444783, characterized in that, in order to extend the functionality by monitoring the contents of the microprocessor stack pointer when executing stack instructions, it contains a decoder, a third and fourth registers, a second adder, a second comparison circuit, a second counter, a second multiplexer, a boundary setting block the stack, the fifth, sixth and seventh elements AND, the first, second and third elements OR and the third trigger, and the information input of the third register is connected to the input of the device for connection to the data bus is controlled microprocessor, the output of the third register is connected to the information input of the fourth register, the output of which and the output of the third register form the first information input of the second adder, the second information input of which and the information input of the second multiplexer are connected to the output of the second counter, whose reset input and synchronization inputs of the third and fourth registers are connected to the output of the first item, And, the first вход которого соединен с выходом дешифратора , информационный вход которого соединен с выходом первого регистра, первый информационный вход второй схемы сравнени  соединен с входом устройства дл  подключени  к шине адреса контролируемого микропроцессора, выход второго сумматора соединен с вторым информационным входом второй схемы сравнени , первые входы шестого и седьмого элементов И соединены с входом устройства дл  подключени  к выходу сигнала обращени  к стеку контролируемого микропроцессора, вторые входы п того и шестого элементов И соединены с входом устройства дл  подключени  к выходу чтени  пам ти контролируемого микропроцессора, второй вход седьмого элемента И соединен с входом устройства дл  подключени  к выходу записи в пам ть контролируемого микропроцессора , инверсный вход п того элемента И соединен с входом устройства дл  подключени  к выходу признака первого байта команды контролируемого микропроцессора , пр мой и инверсный выходы первого элемента ИЛИ и входы инкрементировани  и декрементировани  второго счетчика соединены соответственно с выходами шестого и седьмого элементов И, выход блока задани  границы стека соединен с адресным входом второго мультиплексора, инверсный выход которого соединен с первым входом второг.о элемента ИЛИ, второй вход которого соединен-с инверсным выходом второй схемы сравнени , выходы первого и второго элементов ИЛИ соединены соответственно с С- и D-входами третьего триггера, R-вход которого соединен с входом устройства дл  подключени  к выходу сброса контролируемого микропроцессора, выходы второго и третьего триггеров соединены соответственно с первым и вторым входами третьего элемента ИЛИ, выход которого  вл етс  выходом неисправности устройства.the input of which is connected to the output of the decoder, the information input of which is connected to the output of the first register, the first information input of the second comparison circuit is connected to the input of the device for connection to the address bus of the controlled microprocessor, the output of the second adder is connected to the second information input of the second comparison circuit, the first inputs of the sixth and the seventh elements And connected to the input of the device for connecting to the output of the signal access to the stack controlled by the microprocessor, the second inputs of the fifth and sixth element The units And are connected to the input of the device for connecting the readout memory of the controlled microprocessor, the second input of the seventh element And is connected to the input of the device for connecting to the write output to the memory of the controlled microprocessor, the inverse input of the fifth element And is connected to the input of the device for connecting to the output the sign of the first byte of the command of the controlled microprocessor, the direct and inverse outputs of the first OR element, and the inputs of the increment and decrement of the second counter are connected respectively to the outputs of the sixth and seventh elements And, the output of the stack boundary setting block is connected to the address input of the second multiplexer, the inverse output of which is connected to the first input of the second OR element, the second input of which is connected to the inverse output of the second comparison circuit, the outputs of the first and second elements OR connected respectively to the C- and D-inputs of the third trigger, the R-input of which is connected to the input of the device for connection to the reset output of the controlled microprocessor, the outputs of the second and third triggers are connected respectively But with the first and second inputs of the third OR element, the output of which is the output of a device failure. Продолжение таблицыTable continuation Продолжение таблицыTable continuation
SU894763201A 1989-11-27 1989-11-27 Device for microprocessor checking SU1693610A2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
SU894763201A SU1693610A2 (en) 1989-11-27 1989-11-27 Device for microprocessor checking

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
SU894763201A SU1693610A2 (en) 1989-11-27 1989-11-27 Device for microprocessor checking

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
SU1444783 Addition

Publications (1)

Publication Number Publication Date
SU1693610A2 true SU1693610A2 (en) 1991-11-23

Family

ID=21481622

Family Applications (1)

Application Number Title Priority Date Filing Date
SU894763201A SU1693610A2 (en) 1989-11-27 1989-11-27 Device for microprocessor checking

Country Status (1)

Country Link
SU (1) SU1693610A2 (en)

Similar Documents

Publication Publication Date Title
US4176394A (en) Apparatus for maintaining a history of the most recently executed instructions in a digital computer
JP2755581B2 (en) Digital data processing system
EP0098172B1 (en) Register control processing system
SU1693610A2 (en) Device for microprocessor checking
EP0363567A2 (en) A computer with interrupt controlled clock speed and its method of operation
JPH0320776B2 (en)
RU2022343C1 (en) Storage protective device
RU1817096C (en) Device for controlling microprocessor
SU1599862A1 (en) Device for monitoring microprocessor
SU1163328A1 (en) Device for checking microcomputer
SU1642472A1 (en) Device for checking the sequence of operatorъs actions
SU1444783A1 (en) Device for monitoring microprocessor
SU1481775A1 (en) Device for checking program progress
RU1815644C (en) Device for control of program execution in computer
SU1508216A1 (en) Memory protection device
SU1425684A1 (en) Program execution checking device
SU1629910A1 (en) Microprogram control unit
SU1460722A1 (en) Device for monitoring a multiprocessor system
JPS6053330B2 (en) Program writing method
SU1068937A1 (en) Firmware control unit
SU1238072A2 (en) Device for generating memory address
SU1605239A1 (en) Device for checking multiprocessor system
SU1564620A2 (en) Device for control of microprocessor system
SU1587512A1 (en) Device for checking counters
JP3019336B2 (en) Microprocessor development support equipment