[go: up one dir, main page]

RU2729509C1 - Device for unpacking data - Google Patents

Device for unpacking data Download PDF

Info

Publication number
RU2729509C1
RU2729509C1 RU2019143298A RU2019143298A RU2729509C1 RU 2729509 C1 RU2729509 C1 RU 2729509C1 RU 2019143298 A RU2019143298 A RU 2019143298A RU 2019143298 A RU2019143298 A RU 2019143298A RU 2729509 C1 RU2729509 C1 RU 2729509C1
Authority
RU
Russia
Prior art keywords
mask
input
data
register
outputs
Prior art date
Application number
RU2019143298A
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 RU2019143298A priority Critical patent/RU2729509C1/en
Application granted granted Critical
Publication of RU2729509C1 publication Critical patent/RU2729509C1/en

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M7/00Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
    • H03M7/30Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

FIELD: computer equipment.
SUBSTANCE: invention relates to computer engineering and is intended for use in information processing systems, as well as in compression and decompression units without losses in systems for rational use of storage and transmission devices, processing of physical experiment data. Device comprises an input data register RD, a multiple-output priority unit FU, a group of N data switches with k digits, group of N registers by k digits with synchronous input R of setting to zero state, output buffer BQ, element NOR, N groups of k elements 2AND, register of common mask RM1, D-trigger with synchronous input R of setting to zero state, switch of KM mask, register of current mask RM2.
EFFECT: reduced bit depth of input data and ease of implementation with simultaneous increase of information capacity without loss of information due to reduction of required amount of memory for storage of sequence of groups of input data of binary symbols and corresponding symbols masks.
1 cl, 5 dwg

Description

ОБЛАСТЬ ТЕХНИКИAREA OF TECHNOLOGY

Изобретение относится к области вычислительной техники и предназначено для использования в системах обработки информации, а также может быть применено в блоках сжатия и распаковки данных без потерь в системах для рационального использования устройств хранения и передачи данных, обработки данных физических экспериментов.The invention relates to the field of computer technology and is intended for use in information processing systems, and can also be applied in blocks of compression and decompression of data without loss in systems for the rational use of storage and data transmission devices, processing data of physical experiments.

ПРЕДШЕСТВУЮЩИЙ УРОВЕНЬ ТЕХНИКИPRIOR ART

Известен способ сжатия восстановления данных без потерь (RU №2403677 С1, МПК Н03М 7/30, заявлено 09.02.2009, опубликовано 10.11.2010, Бюл. №31), в котором используется сжатие данных, ранее подвергнутых сжатию. В сжимаемом потоке данных считают количество нулей n0 и количество единиц n1, выбирают алгоритм присвоения неповторяющихся цифровых кодов всем возможным перестановкам с повторениями из по нулей и n1 единиц и нахождения соответствующей перестановки, которой присваивают цифровой код Nc, считают общее количество кодов nc, определяют значения d1=n0+n1-nc и d2=(n0+n1)/2, а для восстановления потока данных выполняют обратные операции.There is a known method of lossless data recovery compression (RU No. 2403677 C1, IPC Н03М 7/30, declared 02/09/2009, published 11/10/2010, Bull. No. 31), which uses data compression, previously compressed. In the compressed data stream, count the number of zeros n 0 and the number of ones n 1 , select an algorithm for assigning non-repeating digital codes to all possible permutations with repetitions of zeros and n 1 ones and finding the corresponding permutation, which is assigned a digital code N c , count the total number of codes n c , the values d 1 = n 0 + n 1 -n c and d 2 = (n 0 + n 1 ) / 2 are determined, and the reverse operations are performed to restore the data stream.

Известно кодирующее устройство (RU №153302 U1, МПК Н03М 7/30, заявлено 17.06.2014, опубликовано 10.07.2015, Бюл. №19), содержащее входной регистр, анализатор разрядов, блок управления ключами, блок ключей, ПЗУ, блок мультиплексоров, выходной регистр, а также тактовый генератор, делитель частоты, счетчик и выходной регистр со следующими соединениями: выход входного регистра 1-n соединен с входами анализатора разрядов и с блоком управления ключами, выходы 1-n2 анализатора соединены с информационными входами блока ключей, а выходы 1-n2 - с управляющими входами этого блока, выходы которого 1-n2 соединены с входами ПЗУ, а выходы 1-2n ПЗУ соединены с информационными входами блока мультиплексора, выходы которого 1-n являются выходами маркера устройства; выходы 3-8 входного регистра соединены с выходным регистром, выходы которого являются выходами информационных разрядов устройства; выход тактового генератора через счетчик соединен с управляющими входами блока мультиплексоров, а через делитель частоты - с управляющими входами: через выход 1 входного регистра, через выход 2 с блоком управления ключами, а через выход 3 с выходным регистром.Known encoding device (RU No. 153302 U1, IPC Н03М 7/30, declared on June 17, 2014, published on July 10, 2015, Bulletin No. 19) containing an input register, a discharge analyzer, a key control unit, a key block, a ROM, a multiplexer block, an output register, as well as a clock generator, a frequency divider, a counter and an output register with the following connections: the output of the input register 1-n is connected to the inputs of the bit analyzer and to the key control unit, the outputs 1-n 2 of the analyzer are connected to the information inputs of the key unit, and outputs 1-n 2 - with the control inputs of this block, the outputs of which 1-n 2 are connected to the ROM inputs, and the outputs 1-2n of the ROM are connected to the information inputs of the multiplexer unit, the outputs of which 1-n are the outputs of the device marker; outputs 3-8 of the input register are connected to the output register, the outputs of which are the outputs of the information bits of the device; the output of the clock generator through the counter is connected to the control inputs of the multiplexer unit, and through a frequency divider - to the control inputs: through the output 1 of the input register, through the output 2 with the key control unit, and through the output 3 with the output register.

Недостатком данных устройств является схемная сложность, что затрудняет их применение.The disadvantage of these devices is their circuit complexity, which complicates their use.

Известно устройство для упаковки данных (RU №2701711 С1, МПК Н03М 7/30, заявлено 09.01.2019, опубликовано 30.09.2019, Бюл. №28), содержащее N входных символов ID1, ID2, …, IDN по k разрядов соединенных с входным регистром данных 2, формирователь маски 3, содержащий группу из N элементов ИЛИ, коммутатор маски 4, регистр маски 5, многовыходной блок приоритета 6, содержащий w каскадов, блок коммутаторов данных 7, содержащий w коммутаторов 71, 72, …, 7w, коммутатор маски-данных 8, выходной буфер 9, элемент ИЛИ-НЕ 10, синхронный D-триггер 11, внешний вход С синхронизации 12, внешний вход R синхронной установки в нулевое состояние 13, внешние выходы Q устройства 14, содержащие w символов по k разрядов, а также внутреннюю шину данных DD из N символов по k разрядов, внутреннюю N разрядную шину маски символов М, группу из w внутренних шин указателей старших символов U1, U2, …, Uw (где w количество выходных символов), внутреннюю шину остаточной маски MS и флаг нулевых символов (флаг нуля) FZ.Known device for packing data (RU No. 2701711 C1, IPC Н03М 7/30, declared 01/09/2019, published 09/30/2019, bull. No. 28), containing N input characters ID1, ID2, ..., IDN by k bits connected to the input data register 2, mask generator 3, containing a group of N OR elements, mask switch 4, mask register 5, multi-output priority block 6, containing w stages, data switch block 7, containing w switches 7 1 , 7 2 , ..., 7w, mask-data switch 8, output buffer 9, OR-NOT element 10, synchronous D-flip-flop 11, external input C of synchronization 12, external input R of synchronous setting to zero 13, external outputs Q of device 14, containing w symbols of k bits , as well as an internal data bus DD of N symbols by k bits, an internal N-bit bus of a mask of symbols M, a group of w internal buses of pointers of the most significant symbols U1, U2, ..., Uw (where w is the number of output symbols), an internal bus of the residual mask MS and the null character flag (zero flag) FZ ...

Недостатком данного устройства является отсутствие средств для восстановления сжатых данных.The disadvantage of this device is the lack of tools for recovering compressed data.

Наиболее близким устройством того же назначения к заявленному изобретению по совокупности признаков является, принятое за прототип, устройство для декомпрессии данных (RU №2697618 С1, МПК Н03М 7/30, заявлено 30.10.2018, опубликовано 15.08.2019, Бюл. №23), содержащее шину входных данных 1 соединенную с входным регистром данных 2, многовыходной блок приоритета 3, который содержит w групп выходов указателей старших символов S1, S2, …, Sw по N разрядов (где w количество входных символов), группу из N коммутаторов данных 41, 42, …, 4N, группу из N регистров 51, 52, …, 5N с синхронным входом R установки в нулевое состояние, выходной буфер 6, выходы которого содержат N выходных символов Q1, Q2, … QN по k разрядов и которые являются внешними выходами устройства 13, элемент ИЛИ-НЕ 7, N групп 81, 82, …, 8N по k элементов 2И, регистр маски 9, D-триггер 10 с синхронным входом R установки в нулевое состояние,The closest device for the same purpose to the claimed invention in terms of a set of features is, taken as a prototype, a device for data decompression (RU No. 2697618 C1, IPC N03M 7/30, announced on 10/30/2018, published on 08/15/2019, bull. No. 23), containing the input data bus 1 connected to the input data register 2, a multi-output block of priority 3, which contains w groups of outputs of pointers of high-order symbols S1, S2, ..., Sw, N bits each (where w is the number of input characters), a group of N data switches 4 1 , 4 2 , ..., 4 N , a group of N registers 5 1 , 5 2 , ..., 5 N with a synchronous input R set to zero, output buffer 6, the outputs of which contain N output symbols Q1, Q2,… QN by k bits and which are external outputs of the device 13, OR-NOT element 7, N groups 8 1 , 8 2 , ..., 8 N by k elements 2I, mask register 9, D-flip-flop 10 with a synchronous input R setting to zero,

а также содержащее внешний вход С синхронизации 11, внешний вход R синхронной установки в нулевое состояние, внутреннюю шину данных D из w символов по k разрядов, внутреннюю шину приоритета MS, которая является группой вторых выходов многовыходного блока приоритета 3, внутреннюю N разрядную первую шину маски символов М, внутреннюю N разрядную вторую шину маски символов QM, которая является группой выходов регистра маски 9, и флаг нуля FZ,and also containing an external input C of synchronization 11, an external input R of synchronous setting to zero, an internal data bus D of w symbols by k bits each, an internal MS priority bus, which is a group of second outputs of a multi-output block of priority 3, an internal N-bit first mask bus symbols M, the internal N-bit second bus of the mask of symbols QM, which is the group of outputs of the mask register 9, and the zero flag FZ,

причем внешний вход С синхронизации 11 и внешний вход R синхронной установки в нулевое состояние 12 соединены соответственно с входами синхронизации С и входами R синхронной установки в нулевое состояние входного регистра данных 2, N групп регистров 5, выходного буфера 6, регистра маски 9 и D-триггера 10,moreover, the external input C of synchronization 11 and the external input R of synchronous zeroing 12 are connected, respectively, to the inputs of synchronization C and inputs R of synchronous zeroing of the input data register 2, N groups of registers 5, output buffer 6, mask register 9 and D- trigger 10,

причем выходы входного регистра 2 являются соответствующими w*k разрядами внутренней шины данных D, которые соединены с информационными входами каждого коммутатора данных группы из N коммутаторов данных 41, 42, …, 4N, управляющие входы выборки которых соединены с соответствующими одноименными разрядами w групп выходов S1, S2, …, Sw многовыходного блока приоритета 3,moreover, the outputs of the input register 2 are the corresponding w * k bits of the internal data bus D, which are connected to the information inputs of each data switch of a group of N data switches 4 1 , 4 2 , ..., 4 N , the control inputs of the sample of which are connected to the corresponding similar bits w groups of outputs S 1 , S2, ..., Sw multi-output block of priority 3,

при этом выходы группы из N коммутаторов данных 41, 42, …, 4N соединены с соответствующими информационными входами D одноименных регистров группы из N регистров 51, 52, …, 5N, у которых выходы QB1, QB2, …, QBN всех N регистров 51, 52, …, 5N соединены по группам с соответствующими первыми входами элементов 2И одноименных N групп 81, 82, …, 8N, выходы которых соединены с соответствующими группами информационных входов IQ1, IQ2, …, IQN выходного буфера 6, а вторые входы элементов 2И из N групп 81, 82, …, 8N по группам соединены между собой и подключены к соответствующим одноименным разрядам внутренней N разрядной второй шины маски QM,while the outputs of a group of N data switches 4 1 , 4 2 , ..., 4 N are connected to the corresponding information inputs D of the same registers of a group of N registers 5 1 , 5 2 , ..., 5 N , which outputs QB1, QB2, ..., QBN of all N registers 5 1 , 5 2 , ..., 5 N are connected in groups with the corresponding first inputs of elements 2I of the same N groups 8 1 , 8 2 , ..., 8 N , the outputs of which are connected to the corresponding groups of information inputs IQ1, IQ2, ... , IQN of the output buffer 6, and the second inputs of elements 2I of N groups 8 1 , 8 2 , ..., 8 N are interconnected in groups and connected to the corresponding bits of the same name of the internal N-bit second bus of the QM mask,

кроме того выход элемента ИЛИ-НЕ 7 является флагом нуля FZ и соединен с информационным D-входом D-триггера 10, выход которого соединен с входом СЕ разрешения работы регистра маски 9 и соединен с входом СЕ разрешения работы выходного буфера 6,in addition, the output of the OR-NOT element 7 is a zero flag FZ and is connected to the information D-input of the D-flip-flop 10, the output of which is connected to the CE input of the enable of the mask register 9 and is connected to the input of the CE of the enable of the output buffer 6,

причем шина входных данных 1 содержит группу входных разрядов данных ID из w символов по k разрядов и группу входных N разрядов маски символов IM, при этом вторая группа выходов входного регистра 2 является N разрядами внутренней первой шины маски символов М, которая соединена с входами многовыходного блока приоритета 3 и соединена с входами СЕ одноименных групп регистров 51, 52, …, 5N.moreover, the input data bus 1 contains a group of input data bits ID of w symbols by k bits and a group of input N bits of the symbol mask IM, while the second group of outputs of the input register 2 is N bits of the internal first bus of the mask of symbols M, which is connected to the inputs of the multi-output unit priority 3 and connected to the inputs of the CE of the same group of registers 5 1 , 5 2 ,…, 5 N.

Недостатками данного устройства являются аппаратные затраты на хранение текущей маски для каждой упакованной группы символов и передача на каждом такте N разрядов текущей маски.The disadvantages of this device are the hardware costs for storing the current mask for each packed group of symbols and transmitting N bits of the current mask at each clock cycle.

ЗАДАЧА ИЗОБРЕТЕНИЯOBJECT OF THE INVENTION

Задачей изобретения является разработка аппаратных средств для использования в системах обработки информации, блоках сжатия и распаковки данных без потерь в системах для рационального использования устройств хранения и передачи данных.The objective of the invention is to develop hardware for use in information processing systems, compression and decompression units without loss in systems for the rational use of storage and data transmission devices.

Техническим результатом изобретения является сокращение разрядности входных данных и простота реализации с одновременным повышением информационной вместимости без потерь информации за счет сокращения необходимого объема памяти для хранения последовательности групп входных данных двоичных символов и соответствующих масок символов.The technical result of the invention is to reduce the bit width of the input data and simplicity of implementation with a simultaneous increase in information capacity without loss of information by reducing the required amount of memory for storing a sequence of groups of input data of binary symbols and corresponding masks of symbols.

КРАТКОЕ ОПИСАНИЕ СУЩНОСТИ ИЗОБРЕТЕНИЯBRIEF DESCRIPTION OF THE INVENTION

Указанный технический результат при осуществлении изобретения достигается тем, что в устройство для распаковки данных содержащее шину IMD входных данных 1 соединенную с входным регистром RD данных 2, многовыходной блок FU приоритета 3, который содержит w групп выходов указателей старших символов U1, U2, …, Uw по N разрядов (где w количество входных символов), группу из N коммутаторов КD данных 41, 42, …, 4N, группу из N регистров 51, 52, …, 5N с синхронным входом R установки в нулевое состояние, выходной буфер BQ 6, выходы которого содержат N выходных символов Q1, Q2, …, QN по k разрядов и которые являются внешними выходами устройства 13, элемент ИЛИ-НЕ 7, N групп 81, 82, …, 8N по k элементов 2И, регистр RM1 общей маски 9, D-триггер 10 с синхронным входом R установки в нулевое состояние,The specified technical result in the implementation of the invention is achieved by the fact that in the device for unpacking data containing the input data bus IMD 1 connected to the input data register RD 2, the multi-output block FU of priority 3, which contains w groups of outputs of the pointers of the most significant symbols U1, U2, ..., Uw N bits each (where w is the number of input characters), a group of N switches KD data 4 1 , 4 2 , ..., 4 N , a group of N registers 5 1 , 5 2 , ..., 5 N with a synchronous input R setting to zero , output buffer BQ 6, the outputs of which contain N output symbols Q1, Q2, ..., QN in k bits and which are external outputs of the device 13, OR-NOT element 7, N groups 8 1 , 8 2 , ..., 8 N by k elements 2I, register RM1 of the general mask 9, D-flip-flop 10 with a synchronous input R set to zero,

а также содержащее внешний вход С синхронизации 11, внешний вход R синхронной установки в нулевое состояние 12, внутреннюю шину данных-маски MD из w символов по k разрядов, внутреннюю шину приоритета (остаточной маски) MS, которая является группой вторых выходов многовыходного блока приоритета 3, внутреннюю N разрядную шину общей маски символов QM, которая является группой выходов регистра RM1 общей маски 9, и флаг нуля (флаг нулевых символов) FZ,and also containing an external input C of synchronization 11, an external input R of synchronous zeroing 12, an internal data-mask bus MD of w symbols of k bits each, an internal priority bus (residual mask) MS, which is a group of second outputs of a multi-output block of priority 3 , the internal N-bit bus of the general mask of symbols QM, which is the group of outputs of the register RM1 of the general mask 9, and the zero flag (flag of zero symbols) FZ,

причем внешний вход С синхронизации 11 и внешний вход R синхронной установки в нулевое состояние 12 соединены соответственно с входами синхронизации С и входами R синхронной установки в нулевое состояние входного регистра RD данных 2, N групп регистров 51, 52, …, 5N, выходного буфера BQ 6, регистра RM1 общей маски 9 и D-триггера 10,moreover, the external input C of synchronization 11 and the external input R of synchronous zeroing 12 are connected, respectively, to the inputs of synchronization C and inputs R of synchronous zeroing of the input register RD of data 2, N groups of registers 5 1 , 5 2 , ..., 5 N , output buffer BQ 6, register RM1 of the general mask 9 and D-flip-flop 10,

причем выходы входного регистра 2 являются соответствующими w*k разрядами внутренней шины данных-маски MD, которые соединены с информационными входами каждого коммутатора данных КD группы из N коммутаторов данных 41, 42, …, 4N, управляющие входы выборки которых соединены с соответствующими одноименными разрядами w групп выходов U1, U2, …, Uw многовыходного блока FU приоритета 3,moreover, the outputs of the input register 2 are the corresponding w * k bits of the internal data-mask bus MD, which are connected to the information inputs of each data switch KD of a group of N data switches 4 1 , 4 2 , ..., 4 N , the control inputs of which are connected to the corresponding with the same name bits w of groups of outputs U1, U2, ..., Uw of a multi-output unit FU of priority 3,

при этом выходы группы из N коммутаторов КD данных 41, 42, …, 4N соединены с соответствующими информационными входами D одноименных регистров группы из N регистров 51, 52, …, 5N, у которых выходы QB1, QB2, …, QBN всех N регистров 51, 52, …, 5N соединены по группам с соответствующими первыми входами элементов 2И одноименных N групп 81, 82, …, 8N, выходы которых соединены с соответствующими группами информационных входов IQ1, IQ2, …, IQN выходного буфера BQ 6, а вторые входы элементов 2И из N групп 81, 82, …, 8N по группам соединены между собой и подключены к соответствующим одноименным разрядам внутренней N разрядной шины общей маски символов QM,while the outputs of a group of N switches KD data 4 1 , 4 2 , ..., 4 N are connected to the corresponding information inputs D of the same-name registers of a group of N registers 5 1 , 5 2 , ..., 5 N , whose outputs QB1, QB2, ... , QBN of all N registers 5 1 , 5 2 , ..., 5 N are connected in groups with the corresponding first inputs of elements 2I of the same N groups 8 1 , 8 2 , ..., 8 N , the outputs of which are connected with the corresponding groups of information inputs IQ1, IQ2, ..., IQN of the output buffer BQ 6, and the second inputs of elements 2I of N groups 8 1 , 8 2 , ..., 8 N are interconnected in groups and connected to the corresponding bits of the same name of the internal N bit bus of the general mask of symbols QM,

кроме того выход элемента ИЛИ-НЕ 7 является флагом нуля FZ и соединен с информационным D-входом D-триггера 10, выход которого соединен с входом СЕ разрешения работы регистра RM1 общей маски 9 и соединен с входом СЕ разрешения работы выходного буфера ВО 6,in addition, the output of the OR-NOT element 7 is a zero FZ flag and is connected to the information D-input of the D-flip-flop 10, the output of which is connected to the CE input for enabling the operation of the register RM1 of the general mask 9 and is connected to the CE input for enabling the output buffer VO 6,

дополнительно введены коммутатор КМ маски 14 и регистр RM2 текущей маски 15, у которого вход синхронизации С соединен с внешним входом С синхронизации 11, а вход R синхронной установки в нулевое состояние соединен с внешним входом 12 синхронной установки в нулевое состояние, а также введена внутренняя N разрядная шина текущей маски символов М,In addition, the switch KM of the mask 14 and the register RM2 of the current mask 15 are introduced, in which the synchronization input C is connected to the external input C of synchronization 11, and the input R of the synchronous setting to the zero state is connected to the external input 12 of the synchronous setting to the zero state, and also the internal N bit line of the current mask of characters M,

причем внутренняя шина данных-маски MD также соединена с информационными входами регистра общей маски 9 и с первой группой информационных входов коммутатора КМ маски 14, у которого вторая группа информационных входов соединена с внутренней шиной приоритета (остаточной маски) MS, а третий управляющий вход выборки коммутатора КМ маски 14 соединен с выходом D-триггера 10,moreover, the internal data-mask bus MD is also connected to the information inputs of the general mask register 9 and to the first group of information inputs of the switch KM of the mask 14, in which the second group of information inputs is connected to the internal priority bus (residual mask) MS, and the third control input of the switch selection KM mask 14 is connected to the output of the D-flip-flop 10,

при этом группа выходов коммутатора КМ маски 14 соединена с входами элемента ИЛИ-НЕ 7 и с информационными входами регистра RM2 текущей маски 15, группа выходов которого соединена с группой входов многовыходного блока приоритета 3 и является внутренней шиной текущей маски символов М, разряды которой соединены с входами СЕ одноименных групп регистров 51, 52, …, 5N.the group of outputs of the switch KM mask 14 is connected to the inputs of the OR-NOT element 7 and to the information inputs of the register RM2 of the current mask 15, the group of outputs of which is connected to the group of inputs of the multi-output block of priority 3 and is the internal bus of the current mask of symbols M, the bits of which are connected to CE inputs of the same name groups of registers 5 1 , 5 2 ,…, 5 N.

КРАТКОЕ ОПИСАНИЕ ЧЕРТЕЖЕЙBRIEF DESCRIPTION OF DRAWINGS

На фиг. 1 представлена схема предлагаемого устройства для распаковки данных. На фиг. 2 приведен формат данных до упаковки. На фиг. 3 приведены форматы данных на входе в устройство. На фиг. 4 приведен формат выходных данных. На фиг. 5 приведена потактовая временная диаграмма работы предлагаемого устройства при количестве символов до упаковки N=16 по k=4 разрядов, разрядности маски N=16, разрядности входной шины IMD данных-маски L=16, содержащей w=4 символов по k=4 разрядов или N=16 разрядов маски.FIG. 1 shows a diagram of the proposed device for unpacking data. FIG. 2 shows the format of the data before packing. FIG. 3 shows the data formats at the input to the device. FIG. 4 shows the format of the output data. FIG. 5 shows a clockwise time diagram of the proposed device operation with the number of symbols before packing N = 16 in k = 4 bits, the width of the mask N = 16, the width of the input IMD data-mask bus L = 16, containing w = 4 symbols of k = 4 bits, or N = 16 mask bits.

В устройстве на фиг. 1-5 и в тексте приняты следующие обозначения:In the device of FIG. 1-5 and the following designations are adopted in the text:

С - вход синхронизации,С - synchronization input,

СЕ - вход разрешения работы,CE - work permit entry,

BQ - выходной буфер,BQ - output buffer,

D - информационный вход триггера,D - information input of the trigger,

DD - данные до упаковки (сжатия) - N символов по k разрядов,DD - data before packing (compression) - N characters by k bits,

dd - входные символы, содержащие по k разрядов,dd - input characters, containing k bits each,

IMD - входная шина данных-маски разрядностью L ≥ max (N, w*k), где w количество символов по k разрядов, N разрядов маски,IMD is the input mask data bus with a width of L ≥ max (N, w * k), where w is the number of symbols in k bits, N bits of the mask,

ID - набор из w входных символов по k разрядов,ID - a set of w input characters k-bit each,

IM - входная маска N разрядности,IM - input mask of N bit width,

MD - внутренняя шина данных-маски - w символов по k разрядов или N разрядов маски,MD - internal data-mask bus - w symbols, k-bit each or N mask bits,

FU - многовыходной блок приоритета, содержащий w каскадов,FU - multi-output priority block containing w stages,

FZ - флаг нулевых символов (флаг нуля),FZ - flag of zero characters (flag of zero),

IQ1, IQ2, …, IQN - N групп входов символов выходного буфера 6,IQ1, IQ2, ..., IQN - N groups of input symbols of the output buffer 6,

k - разрядность символов,k - character length,

KD - коммутатор данных,KD - data switch,

KM - коммутатор маски,KM - mask switch,

L - разрядность входных данных, где L ≥ max (N, w*k),L is the bit width of the input data, where L ≥ max (N, w * k),

М - внутренняя N разрядная шина текущей маски символов,M - internal N-bit bus of the current character mask,

MS - внутренняя шина приоритета (остаточной маски),MS - internal bus priority (residual mask),

N - количество выходных символов по k разрядовN - the number of output characters by k bits

ТСЕ - выход триггера,TCE - trigger output,

Q1, Q2, …, ON - N выходных символов по k разрядов после распаковки (восстановления),Q1, Q2, ..., ON - N output symbols by k bits after unpacking (restoring),

QB1, QB2, …, QBN - N символов с выходов группы регистров 51, 52, …, 5N,QB1, QB2, ..., QBN - N characters from the outputs of the register group 5 1 , 5 2 , ..., 5 N ,

QM - внутренняя N разрядная шина общей маски символов,QM - internal N-bit bus of the common character mask,

R - вход синхронной установки в нулевое состояние,R - input of synchronous setting to zero state,

RD - входной регистр данных,RD - input data register,

RG - регистр,RG - register,

RM1 - регистр общей маски,RM1 - general mask register,

RM2 - регистр текущей маски,RM2 - register of the current mask,

S1, S2, …, Sw - группа из w внутренних шин маски символов в блоке приоритета,S1, S2, ..., Sw - a group of w internal buses of the character mask in the priority block,

U1, U2, …, Uw - w групп N разрядных указателей старшей единицы в коде «1 из N»,U1, U2, ..., Uw - w groups of N-bit pointers of the most significant unit in the code "1 of N",

V - количество ненулевых символов во входных данных ID,V is the number of non-zero characters in the input ID,

w - количество символов во входных данных IMD,w is the number of characters in the input IMD data,

Z - максимальное количество групп во входной последовательности ненулевых символов, причем Z=] N/w [(большее целое) когда количество V ненулевых символов больше (N-w+1),Z - the maximum number of groups in the input sequence of non-zero symbols, and Z =] N / w [(greater integer) when the number of non-zero symbols V is greater than (N-w + 1),

1 - внешняя входная шина данных-маски IMD,1 - external input bus of data-mask IMD,

2 - входной регистр данных RD,2 - input data register RD,

3 - многовыходной блок приоритета FU,3 - multi-output priority block FU,

41, 42, …, 4N - группа из N коммутаторов данных по k разрядов,4 1 , 4 2 ,…, 4 N - a group of N data switches, k-bit each,

51, 52, …, 5N - группа из N регистров по k разрядов с синхронным входом R установки в нулевое состояние,5 1 , 5 2 , ..., 5 N - a group of N registers of k bits each with a synchronous input R setting to zero,

6 - выходной буфер BQ,6 - output buffer BQ,

7 - элемент ИЛИ-НЕ,7 - element OR NOT,

81, 82, …, 8N - N групп по k элементов 2И,8 1 , 8 2 , ..., 8 N - N groups of k elements 2I,

9 - регистр общей маски RM1,9 - register of the general mask RM1,

10 - D-триггер с синхронным входом R установки в нулевое состояние,10 - D-flip-flop with synchronous input R setting to zero state,

11 - внешний вход С синхронизации,11 - external input С synchronization,

12 - внешний вход R синхронной установки в нулевое состояние,12 - external input R of synchronous setting to zero state,

13 -внешние выходы Q1, Q2, …, QN,13 - external outputs Q1, Q2, ..., QN,

14 - коммутатор маски КМ,14 - KM mask switch,

15 - регистр текущей маски RM2.15 - register of the current mask RM2.

Устройство для распаковки данных содержит шину IMD входных данных 1 соединенную с входным регистром RD данных 2, многовыходной блок FU приоритета 3, который содержит w групп выходов указателей старших символов U1, US2, …, Uw по N разрядов (где w количество входных символов), группу из N коммутаторов КD данных 41, 42, …, 4N, группу из N регистров с синхронным входом R установки в нулевое состояние, выходной буфер BQ 6, выходы которого содержат N выходных символов Q1, Q2, …, QN по k разрядов и которые являются внешними выходами устройства 13, элемент ИЛИ-НЕ 7, N групп 81, 82, …, 8N по k элементов 2И, регистр RM1 общей маски 9, D-триггер 10 с синхронным входом R установки в нулевое состояние, коммутатор КМ маски 14 и регистр RM2 текущей маски 15.The device for unpacking data contains an input data IMD bus 1 connected to the input data register RD 2, a multi-output block FU of priority 3, which contains w groups of outputs of pointers of high-order symbols U1, US2, ..., Uw in N bits (where w is the number of input characters), a group of N switches KD data 4 1 , 4 2 , ..., 4 N , a group of N registers with a synchronous input R set to zero, an output buffer BQ 6, the outputs of which contain N output symbols Q1, Q2, ..., QN by k bits and which are external outputs of the device 13, the OR-NOT element 7, N groups 8 1 , 8 2 , ..., 8 N by k elements 2I, register RM1 of the general mask 9, D-flip-flop 10 with a synchronous input R setting to zero , switch KM mask 14 and register RM2 of the current mask 15.

Кроме того устройство содержит внешний вход С синхронизации 11, внешний вход R синхронной установки в нулевое состояние 12, внутреннюю шину данных-маски MD из w символов по k разрядов, внутреннюю шину приоритета (остаточной маски) MS, которая является группой вторых выходов многовыходного блока приоритета 3, внутреннюю N разрядную шину общей маски символов QM, которая является группой выходов регистра RM1 общей маски 9, флаг нуля FZ и внутреннюю N разрядную шину текущей маски символов М.In addition, the device contains an external synchronization input C 11, an external input R synchronously zeroing 12, an internal data-mask bus MD of w symbols by k bits, an internal priority bus (residual mask) MS, which is a group of second outputs of a multi-output priority block 3, the internal N-bit line of the QM common symbol mask, which is the group of outputs of the register RM1 of the common mask 9, the zero flag FZ and the internal N-bit line of the current M symbol mask.

Входной регистр RD данных 2, N группа регистров 51, 52, …, 5N, выходной буфер BQ 6, регистр RM1 общей маски 9, D-триггер 10 и регистр RM2 текущей маски 15 содержат вход синхронизации С и вход синхронной установки в нулевое состояние R.Input register RD data 2, N group of registers 5 1 , 5 2 , ..., 5 N , output buffer BQ 6, register RM1 of general mask 9, D-flip-flop 10 and register RM2 of current mask 15 contain synchronization input C and input synchronous setting to zero state R.

Внешний вход С синхронизации 11 и внешний вход R синхронной установки в нулевое состояние 12 соединены соответственно с входами синхронизации С и входами R синхронной установки в нулевое состояние входного регистра RD данных 2, N групп регистров 51, 52, …, 5N, выходного буфера BQ 6, регистра RM1 общей маски 9, D-триггера 10 и регистра RM2 текущей маски 15.External input C of synchronization 11 and external input R of synchronous setting to zero state 12 are connected, respectively, to the inputs of synchronization C and inputs R of synchronous setting to zero state of the input register RD data 2, N groups of registers 5 1 , 5 2 , ..., 5 N , output buffer BQ 6, register RM1 of general mask 9, D-flip-flop 10 and register RM2 of the current mask 15.

Входная шина IMD данных-маски 1 содержит L разрядов (L ≥ max (N, w*k) где w количество символов по k разрядов, N разрядов маски). На входную шину 1 последовательно поступают маски ненулевых символов IM и наборы данных ID.The input IMD bus of the data-mask 1 contains L bits (L ≥ max (N, w * k) where w is the number of symbols by k bits, N bits of the mask). The input bus 1 sequentially receives masks of non-zero symbols IM and data sets ID.

Входной регистр данных 2 предназначен для временного хранения масок ненулевых символов IM и наборов данных ID. При этом выходы входного регистра данных 2 являются внутренней шиной данных-маски MD.Input data register 2 is for temporary storage of IM non-zero character masks and ID data sets. In this case, the outputs of the input data register 2 are the internal data-mask bus MD.

Выходной BQ буфер 9 содержит N*k и предназначен для хранения выходных последовательностей распакованных значений символов.Output BQ buffer 9 contains N * k and is designed to store the output sequences of unpacked character values.

Регистр RM1 общей маски 9 предназначен для хранения общей маски в течение времени распаковки и используется для выделения всех ненулевых символов и передачи их на входы выходного буфера BQ 6.The register RM1 of the common mask 9 is intended for storing the common mask during the decompression time and is used to select all non-zero symbols and transfer them to the inputs of the output buffer BQ 6.

Регистр RM2 текущей маски 15 предназначен для выделения текущих ненулевых символов и разрешения их загрузки в группу регистров 51, 52, …, 5N.Register RM2 of the current mask 15 is designed to select the current non-zero characters and enable their loading into the group of registers 5 1 , 5 2 ,…, 5 N.

D-триггер 10 предназначен для управления записью в выходной буфер бив регистр RM1 общей маски 9. Выход ТСЕ D-триггера 10 установленный в единичное состояние ТСЕ=1 разрешает загрузку распакованных данных в выходной буфер BQ 6 и определяет передачу общей маски через коммутатор КМ маски 14 и разрешает загрузку маски в регистр RM1 общей маски 9.D-flip-flop 10 is designed to control writing to the output buffer biv register RM1 of the general mask 9. The TCE output of the D-flip-flop 10 set to the single state TCE = 1 allows loading the unpacked data into the output buffer BQ 6 and determines the transfer of the general mask through the switch KM mask 14 and enables the loading of the mask into the register RM1 of the general mask 9.

Коммутатор КМ маски 14 осуществляет передачу общей или текущей масок.The switch KM mask 14 transmits the general or current masks.

Многовыходной блок FU приоритета 3 формирует на выходах каждой из w групп унитарные коды «1 из N», которые соответствуют значению кода на внутренней шине текущей маски М. Унитарные коды «1 из N», формируются в порядке старшинства приоритетов. Коммутаторы КD данных 41, 42, …, 4N предназначены для выделения из w символов по k разрядов с внутренней шины маски-данных MD одного из символов разрешенного в соответствии с унитарным кодом «1 из N» установленным на выходах w групп N разрядных указателей старшей единицы U1, U2, …, Uw.Multi-output unit FU of priority 3 generates unitary codes "1 of N" at the outputs of each of w groups, which correspond to the value of the code on the internal bus of the current mask M. Unitary codes "1 of N" are formed in priority order of priorities. Switches KD data 4 1 , 4 2 , ..., 4 N are designed to extract from w symbols by k bits from the internal bus of the MD data mask one of the symbols allowed in accordance with the unitary code "1 of N" set at the outputs w of groups of N bit high unit pointers U1, U2,…, Uw.

Выходы группы из N коммутаторов данных 41, 42, …, 4N соединены с соответствующими информационными входами D одноименных регистров группы из N регистров 51, 52, …, 5N, у которых управляющие входы СЕ разрешения работы соединены с одноименными разрядами внутренней N разрядной шины текущей маски символов М.Outputs of a group of N data switches 4 1 , 4 2 , ..., 4 N are connected to the corresponding information inputs D of the same-name registers of a group of N registers 5 1 , 5 2 , ..., 5 N , in which the control inputs of the CE permission to work are connected to the same-name bits internal N-bit bus of the current mask of M.

Группа из N регистров 51, 52, …, 5N предназначена для записи на каждом такте до w ненулевых символов по k разрядов входных данных ID, в соответствии с кодом, установленным на внутренней N разрядной первой шине маски символов М.A group of N registers 5 1 , 5 2 , ..., 5 N is intended for recording at each clock cycle up to w nonzero symbols of k bits of input data ID, in accordance with the code set on the internal N-bit first bus of the M symbol mask.

Выходы QB1, QB2, …, QBN всех N регистров 51, 52, …, 5N соединены по группам с соответствующими первыми входами элементов 2И одноименных N групп 81, 82, …, 8N, выходы которых соединены с соответствующими группами информационных входов IQ1, IQ2, …, IQN выходного буфера ВО 6, который предназначен для хранения восстановленных значений после распаковки данных.The outputs QB1, QB2, ..., QBN of all N registers 5 1 , 5 2 , ..., 5 N are connected in groups with the corresponding first inputs of elements 2I of the same N groups 8 1 , 8 2 , ..., 8 N , the outputs of which are connected to the corresponding groups information inputs IQ1, IQ2, ..., IQN of the output buffer VO 6, which is designed to store the recovered values after unpacking the data.

Вторые входы элементов 2И из N групп 81, 82, …, 8N по группам соединены между собой и подключены к соответствующим одноименным разрядам внутренней N разрядной общей маски символов QM, которая является выходами регистра маски 9, у которого группа информационных D-входов соединена с N разрядами внутренней шины текущей маски символов М. Разряды общей маски символов QM разрешают передачу ненулевых символов после восстановления с выходов QB1, QB2, …, QBN всех N регистров 51, 52, …, 5N по группам через элементы 2И из N групп 81, 82, …, 8N на группы входов IQ1, IQ2, …, IQN символов выходного буфера BQ 6.The second inputs of elements 2I from N groups 8 1 , 8 2 , ..., 8 N in groups are interconnected and connected to the corresponding bits of the same name of the internal N-bit common mask of symbols QM, which is the outputs of the mask register 9, which has a group of information D-inputs connected to N bits of the internal bus of the current mask of symbols M. The bits of the general mask of symbols QM allow the transmission of nonzero symbols after restoration from the outputs QB1, QB2, ..., QBN of all N registers 5 1 , 5 2 , ..., 5 N in groups through elements 2I from N groups 8 1 , 8 2 , ..., 8 N for input groups IQ1, IQ2, ..., IQN symbols of the output buffer BQ 6.

Внутренняя шина приоритета (остаточной маски) MS, которая является группой вторых выходов многовыходного блока приоритета 3, соединена с входами элемента ИЛИ-НЕ 7, выход которого является флагом нуля FZ и соединен с информационным D-входом D-триггера 10, выход которого соединен с входами СЕ разрешения работы выходного буфера ВQ6, регистра RM1 общей маски 9 и управляющим входом коммутатора КМ маски 14.The internal bus of the priority (residual mask) MS, which is a group of second outputs of the multi-output block of priority 3, is connected to the inputs of the OR-NOT element 7, the output of which is the FZ zero flag and is connected to the information D-input of the D-flip-flop 10, the output of which is connected to the inputs of CE for enabling the output buffer BQ6, register RM1 of the general mask 9 and the control input of the switch KM mask 14.

Единичное значение флага нуля FZ=1 формируется если нулевые значения установлены во всех разрядах на выходе коммутатора КМ маски 14.The single value of the zero flag FZ = 1 is formed if zero values are set in all bits at the output of the switch KM mask 14.

Выходы выходного буфера BQ 6 содержат N выходных символов Q1, Q2, …, QN по k разрядов и являются внешними выходами устройства 13.The outputs of the output buffer BQ 6 contain N output symbols Q1, Q2, ..., QN in k bits and are external outputs of the device 13.

ПОДРОБНОЕ ОПИСАНИЕ СУЩНОСТИ ИЗОБРЕТЕНИЯDETAILED DESCRIPTION OF THE INVENTION

Принцип работы предлагаемого устройства состоит в следующем.The principle of operation of the proposed device is as follows.

Код маски IM и коды входных данных ID поступают последовательно по одной входной шине 1 данных-маски IMD. Код общей маски IM сохраняется на регистре RM1 общей маски 9 в течение времени распаковки набора данных DD из N символов по k разрядов. Формируемая текущая маска сохраняется на регистре RM2 текущей маски 14.The IMD mask code and the input data ID codes are sequentially received on one input data-mask IMD bus 1. The general mask code IM is stored in the general mask register RM1 during the decompression time of the DD dataset of N characters by k bits. The current mask being formed is stored in the RM2 register of the current mask 14.

Перед началом работы все регистры и D-триггер 10 устанавливаются в нулевое состояние, а флаг нуля принимает единичное значение FZ=1.Before starting work, all registers and D-flip-flop 10 are set to zero, and the zero flag takes on a single value FZ = 1.

После упаковки (сжатия) данных DD, содержащих N символов по k разрядов (фиг. 2), формируется последовательность сжатых данных, элементы которой состоят из одной группы маски символов IM с разрядностью N и из соответствующих групп данных (символов) ID, содержащих до w ненулевых символов по k разрядов данных (фиг. 3). Максимальное количество элементов входной последовательности составляет Z=] N/w [(большее целое) когда количество V ненулевых символов больше (N-w+1).After packing (compressing) the DD data containing N symbols of k bits each (Fig. 2), a sequence of compressed data is formed, the elements of which consist of one group of the IM symbol mask with a width of N and from the corresponding groups of ID data (symbols) containing up to w nonzero symbols for k data bits (Fig. 3). The maximum number of elements in the input sequence is Z =] N / w [(greater integer) when the number of non-zero characters V is greater than (N-w + 1).

На шину входных данных 1 предлагаемого устройства поступает входная последовательность упакованных данных, содержащая N разрядов маски символов IM и входные разряды данных ненулевых символов ID, начиная со старших символов, которые состоят из w символов по k разрядов (фиг. 3). При этом единичное значение разрядов маски символов IM соответствует ненулевым символам в исходных данных DD до упаковки (сжатия).The input data bus 1 of the proposed device receives an input sequence of packed data containing N bits of the IM symbol mask and input data bits of non-zero symbols ID, starting with the most significant symbols, which consist of w symbols by k bits each (Fig. 3). In this case, the unit value of the bits of the IM symbol mask corresponds to nonzero symbols in the original DD data before packing (compression).

Многовыходной блок FU приоритета 3 определяет не только сигнал с наивысшим приоритетом, но также определяет сигналы со вторым, третьим, …, w-м по старшинству приоритетами. В соответствии с кодом текущей маски М на выходах многовыходного блока приоритета 3 формируются w групп приоритета U1, U2, …, Uw в порядке старшинства приоритета. При этом каждому из N разрядов маски символов М присваивается фиксированный приоритет. В устройстве старший приоритет присвоен старшему N-му разряду из N разрядов маски символов М, а далее приоритет уменьшается от разряда к разряду с уменьшением номера разряда. Младший приоритет задан для младшего 1-го разряда маски символов М. Среди выходных w групп U1, U2, …, Uw многовыходного блока приоритета 3 наивысший приоритет присвоен младшей первой группе U1, а далее приоритет уменьшается от группы к группе с увеличением номера группы. Младший приоритет задан для группы со старшим номером Uw. На выходах каждой из w групп приоритета U1, U2, …, Uw вырабатывается результат в виде унитарного кода «1 из N» - единичный сигнал будет установлен только на одном выходе соответствующем высшему (старшему) приоритету. Старший приоритет в каждой из w групп приоритета U1, U2, …, Uw присвоен разряду со старшим номером.The multi-output unit FU of priority 3 determines not only the signal with the highest priority, but also determines the signals with the second, third, ..., wth priority. In accordance with the code of the current mask M at the outputs of the multi-output block of priority 3, w priority groups U1, U2, ..., Uw are formed in priority order of priority. In this case, each of the N bits of the M symbol mask is assigned a fixed priority. In the device, the highest priority is assigned to the highest N-th bit of the N bits of the mask of symbols M, and then the priority decreases from bit to bit with decreasing bit number. The lowest priority is set for the lower 1st bit of the symbol mask M. Among the output w groups U1, U2, ..., Uw of the multi-output block of priority 3, the highest priority is assigned to the lowest first group U1, and then the priority decreases from group to group with increasing group number. The lowest priority is set for the group with the highest number Uw. At the outputs of each of the w priority groups U1, U2, ..., Uw, a result is generated in the form of a unitary code "1 from N" - a single signal will be set only at one output corresponding to the highest (senior) priority. The highest priority in each of the w priority groups U1, U2,…, Uw is assigned to the bit with the highest number.

Далее в соответствии со значениями w групп приоритета U1, U2, …, Uw на выходы группы из N коммутаторов данных 41, 42, …, 4N передаются не более w соответствующих ненулевых символов входных данных ID с внутренней шины данных-маски MD.Further, in accordance with the values w of the priority groups U1, U2, ..., Uw, no more than w corresponding non-zero symbols of the input data ID from the internal bus of the data-mask MD are transmitted to the outputs of the group of N data switches 4 1 , 4 2 , ..., 4 N.

Одновременно также осуществляется запись в регистр RM2 текущей маски 15 нового значения с внутренней шины приоритета MS, в которой исключены w разрядов старших единичных значений, которые соответствуют обработанным ненулевым символам первой группы ID11, а единичные значения шины приоритета MS соответствуют следующим ненулевым символам последовательности.At the same time, a new value is written into the register RM2 of the current mask 15 from the internal MS priority bus, in which w bits of the most significant ones are excluded, which correspond to the processed non-zero symbols of the first group ID11, and the single values of the MS priority bus correspond to the next non-zero characters in the sequence.

На следующем такте в соответствии с единичными значениями N разрядов текущего кода с внутренней шины маски символов М проводится запись с внутренней шины данных-маски MD до w входных ненулевых символов по k разрядов, соответствующие w единичным значениям, начиная со старших разрядов текущей маски символов М, и нулевые значения символов, соответствующие единичным значениям, превышающим w, начиная со старших разрядов текущей маски символов М, в соответствующие регистры 51, 52, …, 5N.On the next clock cycle, in accordance with the unit values of N bits of the current code, from the internal bus of the mask of symbols M, up to w input non-zero symbols of k bits are written from the internal bus of the mask of symbols MD, corresponding to w unit values, starting with the most significant bits of the current mask of symbols of M, and zero symbol values corresponding to the ones exceeding w, starting from the most significant bits of the current symbol mask M, into the corresponding registers 5 1 , 5 2 , ..., 5 N.

Одновременно с шины входных данных 1 проводится прием следующих значений элементов упакованной (сжатой) последовательности данных во входной регистр данных 2. Далее аналогично проводится восстановление данных и осуществляется прием до w следующих входных ненулевых символов по k разрядов в соответствующие регистры 51, 52, …, 5N, в соответствии со значениями разрядов текущей маски символов М.Simultaneously, from the input data bus 1, the following values of the elements of the packed (compressed) data sequence are received into the input data register 2. Further, the data is restored in the same way and up to w next input non-zero symbols are received in k bits in the corresponding registers 5 1 , 5 2 , ... , 5 N , in accordance with the values of the digits of the current character mask M.

Если на текущем такте обработаны все единичные значении разрядов текущей маски символов М, то нулевые значения устанавливаются во всех разрядах внутренней шины приоритета MS на выходах многовыходного блока FU приоритета 3, формируется единичное значение флага нуля FZ=1 и на следующем такте единичное значение устанавливается на выходе D-триггера 10.If at the current cycle all the unit values of the digits of the current symbol mask M are processed, then zero values are set in all bits of the internal MS priority bus at the outputs of the multi-output unit FU of priority 3, a unit value of the zero flag FZ = 1 is formed and at the next cycle the unit value is set at the output D-flip-flop 10.

Кроме того, для каждых новых входных данных DD на первом такте первичное значение маски символов IM, соответствующее всем V ненулевым символам из N входных символов до упаковки (сжатия), записывается в регистр RM1 общей маски 9 при единичном значении на выходе D-триггера 10.In addition, for each new input data DD on the first clock cycle, the primary value of the symbol mask IM, corresponding to all V non-zero symbols of the N input symbols before packing (compression), is written into the register RM1 of the general mask 9 at a single value at the output of the D-flip-flop 10.

В каждом такте, в соответствии с единичными значениями разрядов регистра RM1 общей маски 9, на выходы N групп по k элементов 2И 81, 82, …, 8N передаются значения символов QB1, QB2, …, QBN с выходов соответствующих регистров 51, 52, …, 5N, или формируются нулевые символы соответствующие нулевым значениям разрядов регистра RM1 общей маски 9. Значения с выходов N групп по k элементов 2И 81, 82, …, 8N поступают на входы символов IQ1, IQ2, …, IQN выходного буфера BQ 6, которые, при единичном значении на выходе D-триггера 10, на следующем такте записываются в выходной буфер BQ 6 и поступают на внешние выходы 13 устройства. При этом N выходных символов по k разрядов восстановленных данных Q1, Q2, …, QN (фиг. 4) соответствуют данным DD до упаковки (сжатия) без потери информации.In each cycle, in accordance with the unit values of the bits of the register RM1 of the general mask 9, the values of the symbols QB1, QB2, ..., QBN from the outputs of the corresponding registers 5 1 are transmitted to the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 N , 5 2 , ..., 5 N , or zero symbols are formed corresponding to the zero values of the bits of the register RM1 of the general mask 9. The values from the outputs of N groups of k elements 2I 8 1 , 8 2 ,…, 8 N are fed to the inputs of the symbols IQ1, IQ2, ..., IQN of the output buffer BQ 6, which, with a single value at the output of the D-flip-flop 10, are written in the next clock cycle into the output buffer BQ 6 and fed to the external outputs 13 of the device. In this case, N output symbols by k bits of recovered data Q1, Q2, ..., QN (Fig. 4) correspond to DD data before packing (compression) without loss of information.

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

При подаче единичного сигнала на вход 12 синхронной установки R в нулевое состояние по тактовому сигналу С на внешнем входе 11 в нулевое состояние устанавливаются входной регистр RD данных 1, группа из N регистров 51, 52, …, 5N, выходной буфер ВQ6, регистр RM1 общей маски 9, D-триггер 10 и регистр RM2 текущей маски 15. При этом нулевые значения также устанавливаются во всех N разрядах внутренней шины приоритета (остаточной маски) MS и внутренней шины общей маски символов QM, на всех выходах многовыходного блока FU приоритета 3 и формируется единичное значение флага нуля FZ=1 на выходе элемента ИЛИ-НЕ 7.When a single signal is applied to the input 12 of the synchronous setting R to the zero state by the clock signal C, the input register RD of data 1, a group of N registers 5 1 , 5 2 , ..., 5 N , the output buffer BQ6, are set to the zero state at the external input 11, register RM1 of the general mask 9, D-flip-flop 10 and register RM2 of the current mask 15. In this case, zero values are also set in all N bits of the internal priority bus (residual mask) MS and the internal bus of the general mask of symbols QM, at all outputs of the multi-output priority block FU 3 and a single value of the zero flag FZ = 1 is formed at the output of the OR-NOT element 7.

Далее на первом такте во входной регистр RD данных 2 с шины входных данных 1 принимается код первой маски символов IM1. При этом прием в регистры 51, 52, …, 5N, и выходной буфер ВQ6 не выполняется, так как у них на входах разрешения СЕ установлены нулевые сигналы, которые поступают с выхода D-триггера 10. Одновременно в единичное состояние устанавливается D-триггер 10, так как установлен флаг нуля FZ=1.Further, in the first clock cycle, the code of the first symbol mask IM1 is received from the input data bus 1 into the input data register RD 2. In this case, the reception in registers 5 1 , 5 2 , ..., 5 N , and the output buffer BQ6 is not performed, since they have zero signals set at the CE enable inputs, which come from the output of the D-flip-flop 10. At the same time, D is set to a single state -trigger 10, since the zero flag FZ = 1 is set.

Далее значение маски символов IM1 передается на вход регистра RM1 общей маски 9 и через коммутатор маски КМ 14 на вход регистра RM2 текущей маски 15, прием в которые осуществляется по следующему тактовому сигналу С на внешнем входе 11. При этом одновременно осуществляется прием первой группы ID11 из w входных символов в регистр RD данных 2 с шины IMD входных данных 1.Further, the value of the symbol mask IM1 is transmitted to the input of the register RM1 of the general mask 9 and through the switch of the mask KM 14 to the input of the register RM2 of the current mask 15, the reception into which is carried out by the next clock signal C at the external input 11. At the same time, the first group ID11 from w input characters into data register RD 2 from input data bus 1 IMD.

При этом в соответствии с кодом маски IM1, с выхода регистра RM2 текущей маски 15, на выходах многовыходного блока FU приоритета 3 формируются w групп приоритета U1, U2, …, Uw в порядке старшинства приоритета. На выходах каждой из w групп приоритета U1, U2, …, Uw вырабатывается результат в виде унитарного кода «1 из N» - единичный сигнал будет установлен только на одном выходе соответствующем высшему (старшему) приоритету. В соответствии с единичными значениями сигналов приоритета U1, U2, …, Uw в группе из N коммутаторов данных 41, 42, …, 4N на выходы передаются не более w соответствующих ненулевых символов данных ID11, а на остальных выходах коммутаторов данных 41, 42, …, 4N устанавливаются значения нулевых символов.In this case, in accordance with the code of the mask IM1, from the output of the register RM2 of the current mask 15, at the outputs of the multi-output unit FU of priority 3, w priority groups U1, U2, ..., Uw are formed in the order of priority priority. At the outputs of each of the w priority groups U1, U2, ..., Uw, a result is generated in the form of a unitary code "1 from N" - a single signal will be set only at one output corresponding to the highest (senior) priority. In accordance with the unit values of the priority signals U1, U2, ..., Uw in a group of N data switches 4 1 , 4 2 , ..., 4 N , no more than w corresponding nonzero data symbols ID11 are transmitted to the outputs, and at the other outputs of the data switches 4 1 , 4 2 ,…, 4 N set to zero characters.

Одновременно разряды кода маски QM с выхода регистра RM2 текущей маски 15, передаются на соответствующие одноименные входы СЕ разрешения работы регистров 51, 52, …, 5N., прием в которые осуществляется в следующем такте по всем единичным значениям кода общей маски QM. Кроме того, если на текущем такте обработаны все единичные значении разрядов текущей маски символов М или если все разряды входной маски IM имеют нулевые значения, то нулевые значения устанавливаются во всех разрядах внутренней шины приоритета (остаточной маски) MS, которые поступают на выходы многовыходного блока FU приоритета 3 и далее по которым на выходе элемента ИЛИ-НЕ 7 формируется единичное значение флага нуля FZ=1, а при наличии не обработанных единичных разрядов текущей маски символов М формируется нулевое значение флага нуля FZ=0.At the same time, the bits of the QM mask code from the output of the RM2 register of the current mask 15 are transmitted to the corresponding CE inputs of the same name, allowing the operation of registers 5 1 , 5 2 , ..., 5 N. , Which are received in the next clock cycle for all single values of the common QM mask code. In addition, if at the current clock cycle all the unit values of the digits of the current symbol mask M have been processed or if all the bits of the input mask IM have zero values, then zero values are set in all bits of the internal priority bus (residual mask) MS, which are fed to the outputs of the multi-output block FU priority 3 and further, according to which a single value of the zero flag FZ = 1 is formed at the output of the OR-NOT element 7, and if there are unprocessed single digits of the current mask of symbols M, the zero value of the zero flag FZ = 0 is formed.

По следующему тактовому импульсу С в соответствии с единичными значениями разрядов кода текущей маски М проводится запись в соответствующие регистры 51, 52, …, 5N до w входных ненулевых символов по k разрядов с шины текущей маски М, начиная со старших разрядов текущей маски символов М, и нулевые значения символов, соответствующие единичным значениям текущей маски символов М, превышающим w. При этом также осуществляется запись в регистр RM2 текущей маски 15 нового значения с внутренней шины приоритета (остаточной маски) MS, в которой исключены w разрядов старших единичных значений, которые соответствуют обработанным ненулевым символам первой группы ID11, а единичные значения шины приоритета MS соответствуют следующим ненулевым символам элементов входной последовательности.According to the next clock pulse C, in accordance with the unit values of the bits of the code of the current mask M, the corresponding registers 5 1 , 5 2 , ..., 5 N are written to w input non-zero symbols in k bits from the bus of the current mask M, starting with the most significant bits of the current mask symbols M, and null symbol values corresponding to the values of the current mask of M symbols, greater than w. In this case, a new value is also written into the register RM2 of the current mask 15 from the internal priority bus (residual mask) MS, in which w bits of the most significant unit values are excluded, which correspond to the processed nonzero symbols of the first group ID11, and the unit values of the MS priority bus correspond to the following nonzero characters of elements of the input sequence.

Кроме того соответствующее значение флага нуля FZ принимается в D-триггер 10, который управляет коммутатором КМ маски 14. Одновременно осуществляется прием во входной регистр 2 следующих данных ID или маски символов IM с шины входных данных 1.In addition, the corresponding value of the zero flag FZ is received in the D-flip-flop 10, which controls the switch CM of the mask 14. At the same time, the next data ID or the mask of symbols IM from the input data bus 1 is received into the input register 2.

Далее аналогично, как в предыдущих тактах, проводится анализ следующих единичных разрядов кода текущей маски М и в группе из N коммутаторов данных 41, 42, …, 4N на выходы передаются соответствующие следующие w ненулевых символов входных данных ID с внутренней шины MD данных-маски.Further, similarly, as in the previous clock cycles, the analysis of the next single digits of the code of the current mask M is carried out and in a group of N data switches 4 1 , 4 2 , ..., 4 N , the corresponding next w nonzero symbols of the input data ID from the internal data bus MD are transmitted to the outputs -masks.

Одновременно на каждом такте, в соответствии с единичными значениями разрядов с регистра RM1 общей маски 9 установленными на шине кода маски QM, на выходы N групп по k элементов 2И 81, 82, …, 8N передаются значения символов QB1, QB2, …, QBN с выходов соответствующих регистров 51, 52, …, 5N, или формируются нулевые символы соответствующие нулевым значениям разрядов регистра RM1 общей маски 9. Значения с выходов N групп по k элементов 2И 81, 82, …, 8N поступают на входы символов IQ1, IQ2, …, IQN выходного буфера BQ 6, которые, при единичном значении на выходе D-триггера 10, на следующем такте записываются в выходной буфер BQ 6 и поступают на внешние выходы 13 устройства. При этом N выходных символов по к разрядов восстановленных данных Q1, Q2, …, QN (фиг. 4) соответствуют данным DD до упаковки (сжатия) без потери информации.Simultaneously at each cycle, in accordance with the unit values of the digits from the register RM1 of the general mask 9 set on the QM mask code bus, the values of the symbols QB1, QB2, ... are transmitted to the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 N , QBN from the outputs of the corresponding registers 5 1 , 5 2 , ..., 5 N , or zero characters are formed corresponding to the zero values of the bits of the register RM1 of the general mask 9. Values from the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 N come to the inputs of the symbols IQ1, IQ2, ..., IQN of the output buffer BQ 6, which, with a single value at the output of the D-flip-flop 10, on the next clock are written to the output buffer BQ 6 and go to the external outputs 13 of the device. In this case, N output symbols by k bits of recovered data Q1, Q2, ..., QN (Fig. 4) correspond to DD data before packing (compression) without loss of information.

В потактовой временной диаграмме на фиг. 5 приведен пример последовательности наборов входных данных для DD1, …, DD5, элементы последовательности кодов на входе устройства после упаковки (сжатия), содержащие коды маски IM и коды наборов символов ID, и восстановление сжатых данных в предлагаемом устройстве, при количестве входных символов N=16 по k=4 разрядов и количестве символов w=4 во входных данных ID. На фиг. 5 в скобках указана форма представления данных - двоичная (2) или шестнадцатеричная (16).In the clock cycle in FIG. 5 shows an example of a sequence of input data sets for DD1, ..., DD5, elements of the sequence of codes at the input of the device after packing (compression), containing IM mask codes and codes of ID character sets, and recovery of compressed data in the proposed device, with the number of input characters N = 16 of k = 4 bits and the number of characters w = 4 in the input data ID. FIG. 5 in brackets is the form of data representation - binary (2) or hexadecimal (16).

В такте 1 шестнадцать символов первых данных DD1 до упаковки (сжатия) содержат четыре ненулевых символа (В, А, 5, 2), которые далее сжимаются, и формируется соответствующая маска IM1=0С24, и далее код маски и данные последовательно поступают по входной шине IMD данных-маски 1 в предлагаемое устройство. В такте 1 сначала поступает код маски IM1=0С24, который принимается во входной регистр 2 в такте 2 и передается на внутреннюю шину маски-данных MD. Далее код маски IM1=0С24 передается на вход регистр RM1 общей маски 9 и при единичном значении ТСЕ=1 на выходе D-триггера 10 также передается на вход регистра RM2 текущей маски 15, прием в которые осуществляется в такте 3. При этом устанавливается нулевое значение флага нуля FZ=0, которое на такте 3 передается на выход ТСЕ=0 D-триггера 10.In cycle 1, the sixteen symbols of the first data DD1 before packing (compression) contain four nonzero symbols (B, A, 5, 2), which are further compressed, and the corresponding mask IM1 = 0C24 is formed, and then the mask code and data are sequentially received via the input bus IMD data mask 1 into the proposed device. In cycle 1, the mask code IM1 = 0C24 is first received, which is received in the input register 2 in cycle 2 and is transmitted to the internal mask data bus MD. Further, the mask code IM1 = 0С24 is transmitted to the input of the register RM1 of the general mask 9 and with a single value of TCE = 1 at the output of the D-flip-flop 10 it is also transmitted to the input of the register RM2 of the current mask 15, the reception of which is carried out in cycle 3. This sets the zero value the zero flag FZ = 0, which is transmitted to the output TCE = 0 of the D-flip-flop 10 at clock 3.

Одновременно на такте 3 в соответствии со значением кода маски IM1=0С24 с выхода регистра RM2 текущей маски 15 многовыходной блок FU приоритета 3 формирует w групп приоритета U1=0800, U2=0400, U3=0020, U4=0004, по которым проводится восстановление данных в группе из N=16 коммутаторов данных 41, 42, …, 416, а затем результаты восстановления в такте 4 записываются в регистры 51, 52, …, 516 (QB1, QB2, …, QB16). При этом также код MS=0000, с внутренней шины приоритета (остаточной маски) MS, проходит через коммутатор КМ маски 14, так как нулевое состояние установлено на выходе ТСЕ=0 D-триггера 10, и который на такте 4 записывается в регистр RM2 текущей маски 15. При этом устанавливается единичное значение флага нуля FZ=1, которое далее устанавливает в единичное значение ТСЕ=1 выход D-триггера 10 в такте 5.Simultaneously, on cycle 3, in accordance with the value of the mask code IM1 = 0С24 from the output of register RM2 of the current mask 15, the multi-output unit FU of priority 3 forms w priority groups U1 = 0800, U2 = 0400, U3 = 0020, U4 = 0004, according to which the data is restored in a group of N = 16 data switches 4 1 , 4 2 , ..., 4 16 , and then the results of restoration in clock cycle 4 are written to registers 5 1 , 5 2 ,…, 5 16 (QB1, QB2,…, QB16). At the same time, the code MS = 0000, from the internal bus of the priority (residual mask) MS, passes through the switch KM of the mask 14, since the zero state is set at the output TCE = 0 of the D-flip-flop 10, and which at clock 4 is written into the RM2 register of the current masks 15. In this case, the unit value of the zero flag FZ = 1 is set, which further sets the output of D-flip-flop 10 to a unit value TCE = 1 in step 5.

Одновременно на такте 4 в соответствии с единичными значениями разрядов QM=0C24 регистра RM1 общей маски 9, на выходы N групп по k элементов 2И 81, 82, …, 816 передаются значения символов QB1, QB2, …, QB16 с выходов соответствующих регистров 51, 52, …, 516, которые поступают на входы IQ1, IQ2, …, IQ16 выходного буфера 6 и восстановленные данные (В, А, 5, 2) записываются на следующем такте 5 в выходной буфер 6 и поступают на внешние выходы 13 соответствующих выходных символов Q1, Q2, …, Q16 (QD1 на фиг. 5), при единичном значении на выходе D-триггера 10. Таким образом, распаковка входных данных DDI, содержащих маску IM1=0С24 и четыре ненулевых символа ID1=ВА52, поступивших на тактах 1 и 2, проведена за четыре такта.Simultaneously, on cycle 4, in accordance with the unit values of the bits QM = 0C24 of the RM1 register of the general mask 9, the values of the symbols QB1, QB2, ..., QB16 are transmitted to the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 16 from the outputs of the corresponding registers 5 1 , 5 2 , ..., 5 16 , which are fed to the inputs IQ1, IQ2, ..., IQ16 of the output buffer 6 and the recovered data (B, A, 5, 2) are written on the next clock cycle 5 to the output buffer 6 and fed to external outputs 13 of the corresponding output symbols Q1, Q2, ..., Q16 (QD1 in Fig. 5), with a single value at the output of the D-flip-flop 10. Thus, unpacking the input DDI data containing the mask IM1 = 0C24 and four non-zero symbols ID1 = BA52, which arrived at measures 1 and 2, was carried out in four measures.

В такте 3 вторые данные DD2 до компрессии содержат все нулевые символы. Поэтому формируются нулевые разряды маски IM21=0000, которые в такте 4 записываются во входной RD регистр 2 и поступают на шину маски-данных MD, а далее при единичном значении ТСЕ=1 на выходе D-триггера 10 проходят через коммутатор КМ маски 14 и принимаются в регистр RM2 текущей маски 15, а также в регистр RM1 общей маски 9. При этом на всех выходах U1-U4 блока FU приоритета 3 формируются нулевые значения. Поэтому в такте 5 не проводится запись в регистры 51, 52, …, 516, в которых сохраняется предыдущая информация. Но так как в регистре RM1 общей маски 9 установлена нулевая информация, то на выходах элементов 2И 81, 82, …, 8N также устанавливаются нулевые значения кодов символов, поэтому на входах IQ1, IQ2, …, IQ16 выходного буфера BQ 6 также формируются нулевые значения, которые записываются в такте 6 в выходной буфер BQ 6 (QD2 все нули на фиг. 5).In cycle 3, the second data DD2 before compression contains all zero characters. Therefore, the zero bits of the mask IM21 = 0000 are formed, which in clock cycle 4 are written into the input RD register 2 and enter the data mask MD bus, and then, with a single value of TCE = 1 at the output of the D-flip-flop 10, they pass through the switch KM of the mask 14 and are received into the register RM2 of the current mask 15, as well as into the register RM1 of the general mask 9. In this case, zero values are generated at all outputs U1-U4 of the FU block of priority 3. Therefore, in step 5, no writing is made to registers 5 1 , 5 2 , ..., 5 16 , in which the previous information is stored. But since zero information is set in the register RM1 of the general mask 9, then at the outputs of the elements 2I 8 1 , 8 2 , ..., 8 N zero values of the character codes are also set, therefore, at the inputs IQ1, IQ2, ..., IQ16 of the output buffer BQ 6 zero values are formed, which are written in cycle 6 into the output buffer BQ 6 (QD2 are all zeros in Fig. 5).

В такте 4 третьи данные DD3 содержат восемь ненулевых символов (Е, В, 9, 8, 7, 6, 3, 1), которые сжимаются и формируется соответствующая им общая маска IM3=4В6А, содержащая восемь единичных разрядов для всех ненулевых символов. Код маски IM3=4В6А в такте 4 поступает по входной шине IMD данных-маски 1, принимается во входной RD регистр 2 и в такте 5 и передается на внутреннюю шину маски-данных MD. Далее код маски IM3=4В6А передается на вход регистра RM1 общей маски 9 и при единичном значении ТСЕ=1 на выходе D-триггера 10 также передается на вход регистра RM2 текущей маски 15. Прием в регистры 9 и 15 осуществляется в такте 6. Одновременно в такте 5 устанавливается нулевое значение флага нуля FZ=0, которое в такте 6 устанавливает значение ТСЕ=0 на выходе D-триггера 10.In cycle 4, the third data DD3 contains eight nonzero symbols (E, B, 9, 8, 7, 6, 3, 1), which are compressed and the corresponding general mask IM3 = 4B6A is formed, containing eight one bits for all nonzero symbols. The mask code IM3 = 4B6A in cycle 4 is received via the input IMD bus of data-mask 1, is received in the input RD register 2 and in cycle 5 and is transmitted to the internal bus of the MD data-mask. Further, the mask code IM3 = 4B6A is transmitted to the input of the RM1 register of the general mask 9 and, with a single value of TCE = 1, at the output of the D-flip-flop 10, it is also transferred to the input of the RM2 register of the current mask 15. The reception in registers 9 and 15 is carried out in cycle 6. Simultaneously in in step 5, the zero value of the zero flag FZ = 0 is set, which in step 6 sets the value TCE = 0 at the output of D-flip-flop 10.

Одновременно в такте 5 на входную шину IMD данных-маски 1 поступает код ID31=EB98 соответствующий первым четырем ненулевым символам, а в такте 6 поступает код ID32=7631 соответствующий вторым четырем ненулевым символам третьих данных DD3. При этом одновременно на такте 6 для кода текущей маски М=4В6А с регистра RM2 текущей маски 15 передается в многовыходной блок FU приоритета 3 и формируются w=4 групп приоритета U1=4000, U2=0800, U3=0200, U4=0100, по которым проводится восстановление данных ID31=EB98 в группе из N=16 коммутаторов данных 41, 42, …, 416, а затем результаты восстановления в такте 7 записываются в восемь соответствующих регистров 51, 52, …, 516 (QB1, QB2, …, QB16) в соответствии с текущей маской IM3=4В6А с регистра RM2 текущей маски 15. При этом в регистры 51, 52, …, 516 соответствующие четырем младшим единичным разрядам маски будут записаны нулевые значения, а в разрядах, соответствующим всем нулевым значениям кода текущей маски М=4В6А, сохраняются предыдущие значения.Simultaneously, in cycle 5, the code ID31 = EB98 corresponding to the first four non-zero symbols is received on the input IMD bus of the data-mask 1, and in cycle 6 the code ID32 = 7631 corresponding to the second four non-zero symbols of the third data DD3 is received. At the same time, at the same time at step 6 for the code of the current mask M = 4B6A from the register RM2 of the current mask 15 is transmitted to the multi-output unit FU of priority 3 and w = 4 groups of priority U1 = 4000, U2 = 0800, U3 = 0200, U4 = 0100 are formed, according to which recover data ID31 = EB98 in a group of N = 16 data switches 4 1 , 4 2 , ..., 4 16 , and then the results of recovery in step 7 are written into eight corresponding registers 5 1 , 5 2 , ..., 5 16 (QB1 , QB2, ..., QB16) in accordance with the current mask IM3 = 4B6A from the RM2 register of the current mask 15. In this case, zero values will be written to registers 5 1 , 5 2 , ..., 5 16 corresponding to the four least significant single digits of the mask, and in the digits corresponding to all zero values of the code of the current mask M = 4B6A, the previous values are retained.

Одновременно в такте 6 код MS=006A, с внутренней шины приоритета (остаточной маски) MS, проходит через коммутатор КМ маски 14, так как установлено значение ТСЕ=0 на выходе D-триггера 10, и на такте 7 записывается в регистр RM2 текущей маски 15 и устанавливается код текущей маски М=006А. Поэтому в такте 7 для кода текущей маски М=006А, с выхода регистра RM2 текущей маски 15, в многовыходном блоке FU приоритета 3 формируются w=4 групп приоритета U1=0040, U2=0020, U3=0008, U4=0002, по которым проводится восстановление данных ID32=7631 в группе из N=16 коммутаторов данных 41, 42, …, 416, а затем результаты восстановления в такте 8 записываются в восемь соответствующих регистров 51, 52, …, 516 (QB1, QB2, …, QB16) в соответствии с кодом текущей маски М=006А с регистра RM2 текущей маски 15. Одновременно в такте 7 формируется нулевой код остаточной маски MS=0000, по которому формируется единичное значение флага нуля FZ=1 и далее в такте 8 в единичное состояние ТСЕ=1 устанавливается на выходе D-триггера 10, который разрешает прием следующего кода маски IM4=1610 для четвертых данных DD4.Simultaneously, in cycle 6, the code MS = 006A, from the internal priority bus (residual mask) MS, passes through the switch KM of mask 14, since the value TCE = 0 is set at the output of D-flip-flop 10, and at cycle 7 it is written into the RM2 register of the current mask 15 and the current mask code is set M = 006A. Therefore, in step 7 for the code of the current mask M = 006A, from the output of the register RM2 of the current mask 15, in the multi-output block FU of priority 3, w = 4 priority groups U1 = 0040, U2 = 0020, U3 = 0008, U4 = 0002 are formed, according to which data recovery ID32 = 7631 is performed in a group of N = 16 data switches 4 1 , 4 2 , ..., 4 16 , and then the results of recovery in cycle 8 are written into eight corresponding registers 5 1 , 5 2 , ..., 5 16 (QB1, QB2, ..., QB16) in accordance with the code of the current mask M = 006A from the register RM2 of the current mask 15. Simultaneously, in step 7, the zero code of the residual mask MS = 0000 is generated, according to which a single value of the zero flag FZ = 1 is formed and further in step 8 in the single state TCE = 1 is set at the output of the D-flip-flop 10, which allows the reception of the next mask code IM4 = 1610 for the fourth data DD4.

Кроме того на такте 8 в соответствии с единичными значениями разрядов QM=4B6A регистра RM1 общей маски 9, на выходы N групп по k элементов 2И 81, 82, …, 816 передаются значения символов QB1, QB2, …, QB16 с выходов соответствующих регистров 51, 52, …, 516, которые поступают на входы IQ1, IQ2, …, IQ16 выходного буфера BQ 6 и восстановленные данные ненулевых символов (Е, В, 9, 8, 7, 6, 3, 1) записываются на следующем такте 9 в выходной буфер 6, при единичном значении ТСЕ=1 на выходе D-триггера 10, и поступают на внешние выходы 13 соответствующих выходных символов Q1, Q2, …, Q16 (QD3 на фиг. 5).In addition, on cycle 8, in accordance with the unit values of the bits QM = 4B6A of the RM1 register of the general mask 9, the values of the symbols QB1, QB2, ..., QB16 are transmitted to the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 16 from the outputs the corresponding registers 5 1 , 5 2 , ..., 5 16 , which are fed to the inputs IQ1, IQ2, ..., IQ16 of the output buffer BQ 6 and the recovered data of non-zero symbols (E, B, 9, 8, 7, 6, 3, 1) are written on the next clock cycle 9 into the output buffer 6, with a unit value of TCE = 1 at the output of the D-flip-flop 10, and are fed to the external outputs 13 of the corresponding output symbols Q1, Q2, ..., Q16 (QD3 in Fig. 5).

Одновременно в такте 7 четвертые данные DD4, содержащие четыре ненулевых символов (А, С, F, 4), сжимаются и формируется соответствующая общая маска IM4=1610 содержащая четыре единичных разряда для всех ненулевых символов. Код маски IM4=1610 в такте 8 принимается во входной регистр RD2 и с выходов передается на внутреннюю шину маски-данных MD. Далее код маски IM4=1610 передается на вход регистра RM1 общей маски 9 и при единичном значении ТСЕ=1 на выходе D-триггера 10 также передается на вход регистра RM2 текущей маски 15, прием в которые осуществляется в такте 9. Одновременно в такте 8 устанавливается нулевое значение флага нуля FZ=0, так как на выходе коммутатора маски КМ 14 установлен код общей маски IM4=1610, а в такте 9 нулевое состояние устанавливается на выходе ТСЕ=0 D-триггера 10. Одновременно в такте 9 осуществляется прием группы входных символов ID41=ACF4 в регистр RD данных 2 с шины входных данных 1.Simultaneously, in step 7, the fourth data DD4, containing four non-zero symbols (A, C, F, 4), is compressed and the corresponding general mask IM4 = 1610 is formed, containing four one-bits for all non-zero symbols. The mask code IM4 = 1610 in clock cycle 8 is received in the input register RD2 and is transferred from the outputs to the internal mask data bus MD. Further, the mask code IM4 = 1610 is transmitted to the input of the RM1 register of the general mask 9 and with a single value of TCE = 1 at the output of the D-flip-flop 10 it is also transmitted to the input of the RM2 register of the current mask 15, which are received in step 9. At the same time, in step 8, it is set the zero value of the zero flag FZ = 0, since the general mask code IM4 = 1610 is set at the output of the KM mask switch 14, and in step 9 the zero state is set at the output of TCE = 0 of the D-flip-flop 10. Simultaneously, in step 9, a group of input symbols is received ID41 = ACF4 to RD Data Register 2 from Input Data Bus 1.

В такте 9 в соответствии со значением кода маски IM4=1610 с выхода регистра RM2 текущей маски 15 многовыходной блок FU приоритета 3 формирует w групп приоритета U1=1000, U2=0400, U3=0200, U4=0010, по которым проводится восстановление данных в группе из N=16 коммутаторов данных 41, 42, …, 416, а затем результаты восстановления в такте 10 записываются в соответствующие регистры 51, 52, …, 516 (QB1, QB2, …, QB16). При этом с внутренней шины приоритета (остаточной маски) MS, код MS=0000 проходит через коммутатор КМ маски 14,так как нулевое состояние установлено на выходе ТСЕ=0 D-триггера 10, и устанавливается единичное значение флага нуля FZ=1, по которому в такте 10 единичное состояние устанавливается на выходе ТСЕ=1 D-триггера 10.In cycle 9, in accordance with the value of the mask code IM4 = 1610 from the output of the register RM2 of the current mask 15, the multi-output unit FU of priority 3 forms w priority groups U1 = 1000, U2 = 0400, U3 = 0200, U4 = 0010, according to which data is restored to a group of N = 16 data switches 4 1 , 4 2 , ..., 4 16 , and then the results of recovery in clock cycle 10 are written into the corresponding registers 5 1 , 5 2 ,…, 5 16 (QB1, QB2,…, QB16). In this case, from the internal bus of the priority (residual mask) MS, the code MS = 0000 passes through the switch KM of the mask 14, since the zero state is set at the output TCE = 0 of the D-flip-flop 10, and a single value of the zero flag FZ = 1 is set, according to which in step 10, a single state is set at the output TCE = 1 of D-flip-flop 10.

Одновременно в такте 10 в соответствии с единичными значениями разрядов QM=1610 регистра RM1 общей маски 9, на выходы N групп по k элементов 2И 81, 82, …, 816 передаются значения символов QB1, QB2, …, QB16 с выходов соответствующих регистров 51, 52, …, 516, которые поступают на входы IQ1, IQ2, …, IQ16 выходного буфера BQ 6 и восстановленные данные (А, С, F, 4), записываются на следующем такте 11 в выходной буфер BQ 6 и поступают на внешние выходы 13 соответствующих выходных символов Q1, Q2, …, Q16 (QD4 на фиг. 5), при единичном значенииТСЕ=1 на выходе D-триггера 10.At the same time, in cycle 10, in accordance with the unit values of the bits QM = 1610 of the RM1 register of the general mask 9, the values of the symbols QB1, QB2, ..., QB16 are transmitted to the outputs of N groups of k elements 2I 8 1 , 8 2 , ..., 8 16 from the outputs of the corresponding registers 5 1 , 5 2 , ..., 5 16 , which are fed to the inputs IQ1, IQ2, ..., IQ16 of the output buffer BQ 6 and the recovered data (A, C, F, 4), are written on the next clock cycle 11 to the output buffer BQ 6 and are fed to the external outputs 13 of the corresponding output symbols Q1, Q2, ..., Q16 (QD4 in Fig. 5), with a single value of TCE = 1 at the output of the D-flip-flop 10.

Кроме того в такте 9 для пятых данных DD5, которые содержат все нулевые символы, формируются нулевые разряды маски IM5=0000, которые в такте 10 записываются во входной RD регистр 2 и поступают на шину маски-данных MD, а далее при единичном значении ТСЕ=1 на выходе D-триггера 10 проходят через коммутатор КМ маски 14 и принимаются в регистр RM2 текущей маски 15, а также в регистр RM1 общей маски 9. При этом на всех выходах блока FU приоритета 3 формируются нулевые значения, поэтому в такте 11 не проводится запись в регистры 51, 52, …, 516, в которых сохраняется предыдущая информация. Но, так как в регистре RM1 общей маски 9 установлена нулевая информация, то на выходах элементов 2И 81, 82, …, 8N также устанавливаются нулевые значения кодов символов, поэтому на входах IQ1, IQ2, …, IQ16 выходного буфера BQ 6 также формируются нулевые значения, которые записываются в такте 12 в выходной буфер BQ 6 и поступают на внешние выходы 13 соответствующих выходных символов Q1, Q2, …, Q16 (QD5 все нули на фиг. 5), при единичном значении ТСЕ=1 на выходе D-триггера 10.In addition, in step 9 for the fifth data DD5, which contain all zero characters, the zero bits of the mask IM5 = 0000 are formed, which in step 10 are written into the input RD register 2 and fed to the data mask-data bus MD, and then with a single value of TCE = 1 at the output of the D-flip-flop 10 pass through the switch KM of the mask 14 and are received into the register RM2 of the current mask 15, as well as into the register RM1 of the general mask 9. At the same time, zero values are generated at all outputs of the FU block of priority 3, therefore, in cycle 11, no writing to registers 5 1 , 5 2 ,…, 5 16 , in which the previous information is saved. But, since zero information is set in the register RM1 of the general mask 9, then the outputs of the elements 2I 8 1 , 8 2 , ..., 8 N are also set to zero values of the character codes, therefore, at the inputs IQ1, IQ2, ..., IQ16 of the output buffer BQ 6 zero values are also formed, which are written in cycle 12 to the output buffer BQ 6 and are fed to the external outputs 13 of the corresponding output symbols Q1, Q2, ..., Q16 (QD5 all zeros in Fig. 5), with a unit value of TCE = 1 at the output D -trigger 10.

Таким образом, вышеизложенные сведения позволяют сделать вывод, что предлагаемое устройство решает поставленную задачу по распаковке данных без потери информации. При этом N выходных символов по k разрядов восстановленных данных Q1, Q2, …, QN соответствуют данным DD до упаковки (сжатия) без потери информации.Thus, the above information allows us to conclude that the proposed device solves the task of unpacking data without losing information. In this case, N output symbols by k bits of recovered data Q1, Q2, ..., QN correspond to DD data before packing (compression) without loss of information.

В сравнении с прототипом в предлагаемом устройстве сокращается разрядность входных данных за счет исключения внешней N разрядной шины маски символов IM. При этом также сокращается объем памяти для хранения данных после упаковки и объем передаваемой информации.In comparison with the prototype in the proposed device, the bit width of the input data is reduced by eliminating the external N-bit bus of the IM symbol mask. It also reduces the amount of storage space after packaging and the amount of information transferred.

Таким образом, вышеизложенные сведения позволяют сделать вывод, что предлагаемое устройство обеспечивает распаковку входных данных без потерь, обладает регулярностью узлов и связей, простотой конструкции и устройство соответствует заявляемому техническому результату - сокращение разрядности входных данных и уменьшение объема памяти для хранения последовательности групп входных данных двоичных символов.Thus, the above information allows us to conclude that the proposed device provides unpacking of input data without loss, has regularity of nodes and connections, simplicity of design and the device corresponds to the claimed technical result - a reduction in the bit width of the input data and a decrease in the amount of memory for storing a sequence of groups of input data of binary characters ...

Claims (9)

Устройство для распаковки данных, содержащее шину IMD входных данных 1, соединенную с входным регистром RD данных 2, многовыходной блок FU приоритета 3, который содержит w групп выходов указателей старших символов U1, U2, …, Uw по N разрядов (где w - количество входных символов), группу из N коммутаторов КD данных 41, 42, …, 4N, группу из N регистров 51, 52, …, 5N с синхронным входом R установки в нулевое состояние, выходной буфер BQ 6, выходы которого содержат N выходных символов Q1, Q2, …, QN по k разрядов и которые являются внешними выходами устройства 13, элемент ИЛИ-НЕ 7, N групп 81, 82, …, 8N по k элементов 2И, регистр RM1 общей маски 9, D-триггер 10 с синхронным входом R установки в нулевое состояние,A device for unpacking data containing the IMD bus of input data 1, connected to the input data register RD 2, a multi-output block FU of priority 3, which contains w groups of outputs of pointers of high-order symbols U1, U2, ..., Uw by N bits each (where w is the number of input characters), a group of N switches KD data 4 1 , 4 2 , ..., 4 N , a group of N registers 5 1 , 5 2 , ..., 5 N with a synchronous input R set to zero, an output buffer BQ 6, whose outputs contain N output symbols Q1, Q2, ..., QN by k bits and which are external outputs of the device 13, OR-NOT element 7, N groups 8 1 , 8 2 , ..., 8 N by k elements 2 AND, register RM1 of the general mask 9 , D-flip-flop 10 with a synchronous input R set to zero, а также содержащее внешний вход С синхронизации 11, внешний вход R синхронной установки в нулевое состояние 12, внутреннюю шину данных-маски MD из w символов по k разрядов, внутреннюю шину приоритета (остаточной маски) MS, которая является группой вторых выходов многовыходного блока приоритета 3, внутреннюю N разрядную шину общей маски символов QM, которая является группой выходов регистра RM1 общей маски 9, и флаг нуля (флаг нулевых символов) FZ,and also containing an external input C of synchronization 11, an external input R of synchronous zeroing 12, an internal data-mask bus MD of w symbols of k bits each, an internal priority bus (residual mask) MS, which is a group of second outputs of a multi-output block of priority 3 , the internal N-bit bus of the general mask of symbols QM, which is the group of outputs of the register RM1 of the general mask 9, and the zero flag (flag of zero symbols) FZ, причем внешний вход С синхронизации 11 и внешний вход R синхронной установки в нулевое состояние 12 соединены соответственно с входами синхронизации С и входами R синхронной установки в нулевое состояние входного регистра RD данных 2, N групп регистров 51, 52, …, 5N, выходного буфера BQ 6, регистра RM1 общей маски 9 и D-триггера 10,moreover, the external input C of synchronization 11 and the external input R of synchronous zeroing 12 are connected, respectively, to the inputs of synchronization C and inputs R of synchronous zeroing of the input register RD of data 2, N groups of registers 5 1 , 5 2 , ..., 5 N , output buffer BQ 6, register RM1 of the general mask 9 and D-flip-flop 10, причем выходы входного регистра 2 являются соответствующими w*k разрядами внутренней шины данных-маски MD, которые соединены с информационными входами каждого коммутатора данных KD группы из N коммутаторов данных 41, 42, …, 4N, управляющие входы выборки которых соединены с соответствующими одноименными разрядами w групп выходов U1, U2, …, Uw многовыходного блока FU приоритета 3,moreover, the outputs of the input register 2 are the corresponding w * k bits of the internal data-mask bus MD, which are connected to the information inputs of each data switch KD of a group of N data switches 4 1 , 4 2 , ..., 4 N , the control inputs of which are connected to the corresponding with the same name bits w of groups of outputs U1, U2, ..., Uw of a multi-output unit FU of priority 3, при этом выходы группы из N коммутаторов КD данных 41, 42, …, 4N соединены с соответствующими информационными входами D одноименных регистров группы из N регистров 51, 52, …, 5N, у которых выходы QB1, QB2, …, QBN всех N регистров 51, 52, …, 5N соединены по группам с соответствующими первыми входами элементов 2И одноименных N групп 81, 82, …, 8N, выходы которых соединены с соответствующими группами информационных входов IQ1, IQ2, …, IQN выходного буфера BQ 6, а вторые входы элементов 2И из N групп 81, 82, …, 8N по группам соединены между собой и подключены к соответствующим одноименным разрядам внутренней N разрядной шины общей маски символов QM,while the outputs of a group of N switches KD data 4 1 , 4 2 , ..., 4 N are connected to the corresponding information inputs D of the same-name registers of a group of N registers 5 1 , 5 2 , ..., 5 N , whose outputs QB1, QB2, ... , QBN of all N registers 5 1 , 5 2 , ..., 5 N are connected in groups with the corresponding first inputs of elements 2I of the same N groups 8 1 , 8 2 , ..., 8 N , the outputs of which are connected with the corresponding groups of information inputs IQ1, IQ2, ..., IQN of the output buffer BQ 6, and the second inputs of elements 2I of N groups 8 1 , 8 2 , ..., 8 N are interconnected in groups and connected to the corresponding bits of the same name of the internal N bit bus of the general mask of symbols QM, кроме того выход элемента ИЛИ-НЕ 7 является флагом нуля FZ и соединен с информационным D-входом D-триггера 10, выход которого соединен с входом СЕ разрешения работы регистра RM1 общей маски 9 и соединен с входом СЕ разрешения работы выходного буфера ВО 6,in addition, the output of the OR-NOT element 7 is a zero FZ flag and is connected to the information D-input of the D-flip-flop 10, the output of which is connected to the CE input for enabling the operation of the register RM1 of the general mask 9 and is connected to the CE input for enabling the output buffer VO 6, отличающееся тем, что в него дополнительно введены коммутатор КМ маски 14 и регистр RM2 текущей маски 15, у которого вход синхронизации С соединен с внешним входом С синхронизации 11, а вход R синхронной установки в нулевое состояние соединен с внешним входом 12 синхронной установки в нулевое состояние, а также введена внутренняя N разрядная шина текущей маски символов М,characterized in that the switch KM of the mask 14 and the register RM2 of the current mask 15 are additionally introduced into it, in which the synchronization input C is connected to the external input C of synchronization 11, and the input R of the synchronous setting to the zero state is connected to the external input 12 of the synchronous setting to the zero state , and also introduced the internal N-bit bus of the current mask of symbols M, причем внутренняя шина данных-маски MD также соединена с информационными входами регистра общей маски 9 и с первой группой информационных входов коммутатора КМ маски 14, у которого вторая группа информационных входов соединена с внутренней шиной приоритета (остаточной маски) MS, а третий управляющий вход выборки коммутатора КМ маски 14 соединен с выходом D-триггера 10,moreover, the internal data-mask bus MD is also connected to the information inputs of the general mask register 9 and to the first group of information inputs of the switch KM of the mask 14, in which the second group of information inputs is connected to the internal priority bus (residual mask) MS, and the third control input of the switch selection KM mask 14 is connected to the output of the D-flip-flop 10, при этом группа выходов коммутатора КМ маски 14 соединена с входами элемента ИЛИ-НЕ 7 и с информационными входами регистра RM2 текущей маски 15, группа выходов которого соединена с группой входов многовыходного блока приоритета 3 и является внутренней шиной текущей маски символов М, разряды которой соединены с входами СЕ одноименных групп регистров 51, 52, …, 5N.the group of outputs of the switch KM mask 14 is connected to the inputs of the OR-NOT element 7 and to the information inputs of the register RM2 of the current mask 15, the group of outputs of which is connected to the group of inputs of the multi-output block of priority 3 and is the internal bus of the current mask of symbols M, the bits of which are connected to CE inputs of the same name groups of registers 5 1 , 5 2 ,…, 5 N.
RU2019143298A 2019-12-23 2019-12-23 Device for unpacking data RU2729509C1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU2019143298A RU2729509C1 (en) 2019-12-23 2019-12-23 Device for unpacking data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU2019143298A RU2729509C1 (en) 2019-12-23 2019-12-23 Device for unpacking data

Publications (1)

Publication Number Publication Date
RU2729509C1 true RU2729509C1 (en) 2020-08-07

Family

ID=72085768

Family Applications (1)

Application Number Title Priority Date Filing Date
RU2019143298A RU2729509C1 (en) 2019-12-23 2019-12-23 Device for unpacking data

Country Status (1)

Country Link
RU (1) RU2729509C1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2785770C1 (en) * 2022-03-09 2022-12-13 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for combining data groups

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5384567A (en) * 1993-07-08 1995-01-24 International Business Machines Corporation Combination parallel/serial execution of sequential algorithm for data compression/decompression
RU2403677C1 (en) * 2009-02-09 2010-11-10 Сергей Борисович Муллов Method for lossless data compression and retrieval
WO2017131579A1 (en) * 2016-01-29 2017-08-03 Zeropoint Technologies Ab Methods, devices and systems for compressing and decompressing data
RU2658147C1 (en) * 2017-10-05 2018-06-19 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Data decompression device
RU2697618C1 (en) * 2018-10-30 2019-08-15 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for decompression of data

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5384567A (en) * 1993-07-08 1995-01-24 International Business Machines Corporation Combination parallel/serial execution of sequential algorithm for data compression/decompression
RU2403677C1 (en) * 2009-02-09 2010-11-10 Сергей Борисович Муллов Method for lossless data compression and retrieval
WO2017131579A1 (en) * 2016-01-29 2017-08-03 Zeropoint Technologies Ab Methods, devices and systems for compressing and decompressing data
RU2658147C1 (en) * 2017-10-05 2018-06-19 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Data decompression device
RU2697618C1 (en) * 2018-10-30 2019-08-15 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for decompression of data

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2785770C1 (en) * 2022-03-09 2022-12-13 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for combining data groups

Similar Documents

Publication Publication Date Title
CA2077271C (en) Method and apparatus for compressing data
US4593393A (en) Quasi parallel cyclic redundancy checker
CA2096176C (en) Variable length decoder
US4506372A (en) Method and apparatus for recognizing in a receiver the start of a telegram signal consisting of a bit impulse sequence
EP4012928B1 (en) Methods, devices and systems for semantic-value data compression and decompression
CN108702160B (en) Method, apparatus and system for compressing and decompressing data
US4498174A (en) Parallel cyclic redundancy checking circuit
Even On information lossless automata of finite order
US20140161139A1 (en) Method, device and system for compressing time series data
AU669746B2 (en) Method and device for detection and correction of errors in ATM cell headers
EP0628228A1 (en) Data compression using hashing
US6307488B1 (en) LZW data compression and decompression apparatus and method using grouped data characters to reduce dictionary accesses
US5594437A (en) Circuit and method of unpacking a serial bitstream
RU2622878C1 (en) Device for data compression
US3588364A (en) Adaptive encoder and decoder
RU2729509C1 (en) Device for unpacking data
IE902591A1 (en) Data and forward error control coding techniques for digital¹signals
US5488366A (en) Segmented variable length decoding apparatus for sequentially decoding single code-word within a fixed number of decoding cycles
RU2672625C1 (en) Device for compression of data
RU2658147C1 (en) Data decompression device
RU2697618C1 (en) Device for decompression of data
RU2701711C1 (en) Device for packing data
RU2710987C1 (en) Device for data compression
US5825314A (en) Variable-length code decoder
JPH0628149A (en) Data compression method for multiple types of data