KR0123855B1 - The method of parallel processing for one to master slave - Google Patents

The method of parallel processing for one to master slave

Info

Publication number
KR0123855B1
KR0123855B1 KR1019940023457A KR19940023457A KR0123855B1 KR 0123855 B1 KR0123855 B1 KR 0123855B1 KR 1019940023457 A KR1019940023457 A KR 1019940023457A KR 19940023457 A KR19940023457 A KR 19940023457A KR 0123855 B1 KR0123855 B1 KR 0123855B1
Authority
KR
South Korea
Prior art keywords
slave
cpu
master
task
dpram
Prior art date
Application number
KR1019940023457A
Other languages
Korean (ko)
Other versions
KR960011720A (en
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 KR1019940023457A priority Critical patent/KR0123855B1/en
Publication of KR960011720A publication Critical patent/KR960011720A/en
Application granted granted Critical
Publication of KR0123855B1 publication Critical patent/KR0123855B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline, look ahead
    • G06F9/3885Concurrent instruction execution, e.g. pipeline, look ahead using a plurality of independent parallel functional units
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4812Task transfer initiation or dispatching by interrupt, e.g. masked

Abstract

setting an initial value to the variables related to an object system; instructing some work from a master CPU to a specific slave CPU; interrupting the master CPU after performing the instructed work and recording the result in a DPRAM; and setting the job pointer for the work instruction structure as "0" when the work instructed to the slave CPU is completed.

Description

일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법Parallel Processing Method in One-to-Many Master-Slave Computing Units

제1도는 종래 일대다 마스터-슬레이브 방식 컴퓨터 시스템의 개략적인 장치 구성도.1 is a schematic device diagram of a conventional one-to-many master-slave computer system.

*도면의 주요부분에 대한 부호의 설명* Explanation of symbols for main parts of the drawings

11 : 마스터 CPU11: master CPU

12a, 12b, 12r, 12s : 슬레이브 CPU12a, 12b, 12r, 12s: slave CPU

13a, 13b, 13r, 13s : DPRAM13a, 13b, 13r, 13s: DPRAM

본 발명은 하나의 본체 내에 다수의 CPU(Central Processing Unit)를 설치하고, 그중 하나의 CPU는 메인 프로그램을 실행하고, 나머지 CPU들은 함수적인 기능으로만 호출되는 일대다 마스터-슬레이브(master-slave)방식 연산 장치에서의 병렬 처리 방법에 관한 것으로서, 특히 별도의 병렬 처리용 프로그래밍 언어를 사용하지 않고서도 소망하는 작업을 용이하게 프로그래밍할 수 있는 일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법에 관한 것이다.The present invention installs a plurality of central processing units (CPUs) in one main body, one of which executes a main program, and the other CPUs are called only as functional functions, and are one-to-many master-slave. In particular, the present invention relates to a parallel processing method in a method computing device, and in particular, to a parallel processing method in a one-to-many master-slave computing device that can easily program a desired task without using a separate programming language for parallel processing. will be.

통상, 마스터-슬레이브 방식의 컴퓨터 시스템은 하나의 본체내에 다수의 CPU를 설치하고, 그중 하나의 CPU는 메인 프로그램을 실행하고, 나머지 CPU들은 함수적인 기능으로만 작용하는 일대다 마스터-슬레이브 시스템으로 구성되어 있는 경우가 많다.Typically, a master-slave computer system installs a large number of CPUs in one main body, one of which executes a main program, and the other CPUs constitute a one-to-many master-slave system that functions only as a functional function. There are many cases.

첨부 도면의 제1도에는 그와 같은 종래 일대다 마스터-슬레이브 방식 컴퓨터 시스템의 일예가 도시되어 있다.1 of the accompanying drawings shows an example of such a conventional one-to-many master-slave computer system.

이를 참조하면, 종래 일대다 마스터-슬레이브 방식 컴퓨터 시스템(10)은 도시된 것과 같이 하나의 마스터 CPU(11)에 다수개의 슬레이브CPU(12a, 12b…, 12r, 12s)가 DPRAM(Dual Ported Random Access Memory : 13a, 13b…, 13r, 13s)을 통하여 연결되어 있다. 이때의, DPRAM(13a, 13b…, 13r, 13s)은 양방향 참조 및 기록이 가능하고, 또한 양방향으로 인터럽트 신호를 송신해주는 기능을 가지고 있다. 따라서, 각각의 CPU에는 DPRAM(13a, 13b…, 13r, 13s)을 통하여 인터럽트가 걸리게 되고, 해당 인터럽트 벡터 함수 내에는 인터럽트를 보낸 CPU와 통신을 하며 특정한 작업을 수행하기 위한 코드가 들어 있게 된다. 여기서, 물론 인터럽트를 받는 마스터 CPU는 어느 CPU가 인터럽트를 보냈는지 알 수 있도록 회로가 구성되어 있다. 이때, 인터럽트를 보낸 CPU는 지시할 작업의 내용을 DPRAM(13a, 13b…, 13r, 13s)상의 약속된 위치에 미리 기록해 놓게 된다. 또한, 작업을 완수한 CPU는 필요할 경우 결과의 내용을 DPRAM(13a, 13b…, 13r, 13s)상의 약속된 위치에 남겨 놓게 된다. 결국, 이와 같은 시스템 구성에 의해 다수개의 CPU들이 동시에 하나의 목적을 위하여 서로 다른 작업들을 병렬처리하는 것이 가능해진다.Referring to this, in the conventional one-to-many master-slave computer system 10, as illustrated, a plurality of slave CPUs 12a, 12b, 12r, and 12s are connected to one master CPU 11, and Dual Ported Random Access (DPRAM) is shown. Memory: 13a, 13b…, 13r, 13s). At this time, the DPRAMs 13a, 13b, 13r, and 13s can bidirectionally reference and write, and have a function of transmitting interrupt signals in both directions. Therefore, each CPU is interrupted through DPRAMs 13a, 13b, 13r, and 13s, and the interrupt vector function contains code for communicating with the CPU that sent the interrupt and performing a specific task. Here, of course, the interrupted master CPU has a circuit configured to know which CPU sent the interrupt. At this time, the interrupted CPU records in advance the contents of the task to be instructed at the predetermined positions on the DPRAMs 13a, 13b, 13r, and 13s. In addition, the CPU which has completed the work leaves the contents of the result in a promised position on the DPRAMs 13a, 13b ..., 13r, 13s if necessary. As a result, this system configuration allows multiple CPUs to parallelize different tasks simultaneously for one purpose.

그런데, 종래의 이와 같은 일대다 마스터-슬레이브 방식의 컴퓨터 시스템은 병렬 처리 프로그래밍의 숙련자가 아니고서는 그와 같은 시스템을 이용하여 소망하는 작업을 프로그래밍하여 실행시키기가 사실상 매우 어렵다. 왜냐하면, 대부분의 실행 프로그램이 순차적인 프로그래밍 언어를 바탕으로 하며, 병렬처리를 위한 프로그래밍 언어는 극히 제한된 전문가들만이 사용하는 실정이기 때문이다. 결국, 순차적인 언어를 택할 경우에는 전체적인 시스템 수준의 준비가 뒤따라야 하며, 이의 고려가 없을 때는 프로그래밍에 많은 시간과 비용이 소요된다. 또한, 종래의 방식에서는 어떤 슬레이브 CPU에서의 작업완료를 체크할 때, 슬레이브 CPU의 번호를 알아야 하고, 리턴(return) 인자들을 읽어오는 부분을 프로그램해야 하며, 소스(source) 코드의 길이가 늘어나 소스 코드에 혼동이 생기기 쉽다는 단점이 많다.However, such a one-to-many master-slave computer system of the prior art is in fact very difficult to program and execute a desired task using such a system unless a person skilled in parallel processing programming. This is because most executable programs are based on a sequential programming language, and a programming language for parallel processing is used only by extremely limited experts. After all, if you choose to use a sequential language, you will have to do a whole system-level preparation. Without this, programming can be time-consuming and expensive. In addition, in the conventional method, when checking the completion of work on a slave CPU, the number of the slave CPU must be known, a part of reading the return factors must be programmed, and the source code length is increased. There are many drawbacks to code that can be confusing.

본 발명은 상기와 같은 문제점들을 감안하여 창출된 것으로서, 별도의 병렬 처리용 프로그래밍 언어를 사용하지 않고서도 소망하는 작업을 용이하게 프로그래밍할 수 있는 일대다 마스터- 슬레이브 방식 연산장치에서의 병렬처리 방법을 제공함에 그 목적이 있다.SUMMARY OF THE INVENTION The present invention has been made in view of the above problems, and provides a parallel processing method in a one-to-many master-slave type computing device that can easily program a desired task without using a separate parallel programming language. The purpose is to provide.

상기의 목적을 달성하기 위하여 본 발명에 따른 일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법은, 대상 시스템에 관련되는 변수들에 초기값을 설정하는 단계, 특정 슬레이브 CPU에 소정의 작업을 지시하는 단계, 지시받은 작업을 수행하고 결과를 DPRAM에 기록한 후, 마스터 CPU로 인터럽트를 걸어주는 단계, 및 상기 슬레이브 CPU에 지시한 작업이 완료되면 작업지시 구조체에 대한 포인터 변수(job pointer)를 0(zero)화 하는 단계를 포함하여 된 점에 그 특징이 있다.In order to achieve the above object, a parallel processing method in a one-to-many master-slave operation unit according to the present invention comprises the steps of: setting initial values to variables related to a target system; Performing the indicated operation, writing the result to DPRAM, interrupting to the master CPU, and when the instruction instructed to the slave CPU is completed, the pointer variable for the job instruction structure is set to 0 ( It is characterized by the fact that it includes a zeroing step.

이와 같이 포인터 변수를 이용함으로써, 특정 슬레이브 CPU의 번호를 기억할 필요가 없고, 작업의 성격에 알맞는 변수 이름을 정의하여 객체 지향적인 프로그래밍을 할 수 있으며, 응용 프로그램의 소스 코드 길이를 단축시킬 수 있는 장점이 있다.By using pointer variables in this way, there is no need to remember the number of a specific slave CPU, object-oriented programming can be done by defining variable names appropriate to the nature of the task, and shortening the source code length of an application program. There is an advantage.

이하 첨부된 도면을 참조하면서 본 발명의 실시예를 상세히 설명한다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings.

본 발명의 최종적인 산물을 요약하면 두 가지 프로그램 모듈로 압축할 수 있다.In summary, the final product of the present invention can be compressed into two program modules.

그 첫번째는 마스터 CPU를 위한 모듈로서, 이는 사용자의 응용 프로그램과 링크(link)되어 동작된다.The first is a module for the master CPU, which runs in link with the user's application.

두번째는 각각의 슬레이브 CPU를 위한 모듈로서, 자체적으로 동작되며 응용함수를 추가로 링크시켜 작업의 종류를 사용자의 소망에 따라 확장할 수 있다. 이 두가지 모듈을 각각 마스터 모듈과 슬레이브 모듈이라고 부르기로 한다.The second is a module for each slave CPU, which runs on its own and can further link application functions to expand the type of work according to the user's wishes. We will call these two modules master and slave modules, respectively.

여기서, 마스터 모듈의 동작은 다음과 같은 순서에 의해 수행된다.Here, the operation of the master module is performed in the following order.

먼저, 초기화 단계에서 관련되는 변수들에 초기값을 설정하게 된다.First, initial values are set to variables related to the initialization step.

즉, CmdStat[all]=CMDSTAT-NONE :That is, CmdStat [all] = CMDSTAT-NONE:

SysJobPtr[all]=0SysJobPtr [all] = 0

그런 후, 특정 슬레이브 CPU에게 특정작업을 지시하게 된다. 작업이 완료되면, 슬레이브 CPU는 마스터 CPU에게 인터럽트를 걸어서 마스터 CPU가 결과를 DPRAM으로부터 읽어 오고, 작업지시 구조체에 대한 포인터 변수(job pointer라 한다.)를 0으로 만든다. 이와 같은 일련의 작업이 수행됨에 있어서, 시스템에 사용된 가상프로그램 및 C++언어를 표기해 보면 다음과 같다.It then instructs a particular slave CPU to do something. When the job completes, the slave CPU interrupts the master CPU so that the master CPU reads the result from the DPRAM and zeroes the pointer variable (called the job pointer) to the work instruction structure. In this series of operations, the virtual program and C ++ language used in the system are as follows.

마스터 모듈의 데이터 형태 및 상수 정의Data type and constant definition of master module

typedef enum {CMDSTAT-NONE, CMDSTAT-BUSY} T-CmdStat ;typedef enum {CMDSTAT-NONE, CMDSTAT-BUSY} T-CmdStat;

# define ENDOFARG ∼# define ENDOFARG -

# define CHARARG ∼# define CHARARG ~

# define INTARG ∼# define INTARG ∼

# define LONGARG ∼# define LONGARG -

# define FLOATARG ∼# define FLOATARG ~

# define DOUBLEARG ∼ ※ AlocJP( )에서 사용# define DOUBLEARG ~ ※ Used by AlocJP ()

# define CHARPTRARG ∼# define CHARPTRARG ~

# define INTPTRARG ∼# define INTPTRARG ~

# define LONGPTRARG ∼# define LONGPTRARG ~

# define FLOATPTRARG ∼# define FLOATPTRARG ∼

# define DOUBLEPTRARG ∼# define DOUBLEPTRARG ∼

# define POSTJOB ∼# define POSTJOB ~

typedef struct T-JP* T-JobPtr : /*Job구조체에 대한 포인터타입*/typedef struct T-JP * T-JobPtr: / * Pointer type for the structure

struct T-JP /*Job구조체*/struct T-JP / * Job structure * /

{ void (*postjob)(T-JobPtr jp, int which) :/ *후처리 함수*/{void (* postjob) (T-JobPtr jp, int which): / * Post-processing function * /

char *char-arg ; /*리턴인자 리스트*/char * char-arg; / * Return argument list * /

int *int-arg ;int * int-arg;

long *long-arg ;long * long-arg;

float *float-arg ;float * float-arg;

double *double-arg ;double * double-arg;

char **charptr-arg ;char ** charptr-arg;

int **intptr-arg ;int ** intptr-arg;

long **longptr-arg ;long ** longptr-arg;

float **floatptr-arg ;float ** floatptr-arg;

double **doubleptr-arg ; } ;double ** doubleptr-arg; };

마스터 모듈의 변수 정의Variable definition of master module

T-CmdStat CmdStat[N] ; /*Slave CPU의 busy 여부 저장*/T-CmdStat CmdStat [N]; / * Save slave CPU busy * /

T-JobPtr *SysJobPtrPtr[N] ;T-JobPtr * SysJobPtrPtr [N];

l/*각 Slave CPU에 할당된 작업을 기술하는 구조체를 가리키는 포인터 변수에 대한 포인터 배열 */ll / * array of pointers to pointer variables that point to structures describing operations allocated to each slave CPU * / l

마스터 모듈의 함수 정의Function definition in master module

void Write Dpram(int which, int offset, int data) ;void Write Dpram (int which, int offset, int data);

int Read Dpram(int which, int offset) ;int Read Dpram (int which, int offset);

int Check Intr(void) ; /*Interrupt를 보낸 Slave CPU의 번호를 Return 없으면 -1*/int Check Intr (void); / * -1 * / if returning the number of the slave CPU that sent the interrupt

void Call Slave CPU (int which, int jobid, T-JobPtr *jp, int Indent argsize, int * arglist) : 이는 Slave CPU에 작업을 지시하는 함수로, 다음과 같은 순서로 수행하게 된다.void Call Slave CPU (int which, int jobid, T-JobPtr * jp, int Indent argsize, int * arglist): This is a function that instructs the slave CPU to execute the job in the following order.

1) Cmdstat[which]==CMDSTAT-NONE일 때까지 대기1) Wait until Cmdstat [which] == CMDSTAT-NONE

2) Cmdstat[which]-CMDSTAT-BUSY ;2) Cmdstat [which] -CMDSTAT-BUSY;

3) Write Dpram (which, 0, argsize) ;3) Write Dpram (which, 0, argsize);

4) Write Dpram (which, i+1, arglist[i]) ;4) Write Dpram (which, i + 1, arglist [i]);

5) SysJobPtrPtr[which]=jpp ;5) SysJobPtrPtr [which] = jpp;

6) Write Dpram (which, PCINTDSP, jobid) ; */6) Write Dpram (which, PCINTDSP, jobid); * /

int ScanArgSize(int which) ; |/* =={Read Dpram(which, 0) ; */scan |offset[which]-0 ;}*/int ScanArgSize (int which); / * == {Read Dpram (which, 0); * / scan | offset [which] -0;} * /

int ScanArgList(int which) ; |/* == Read Dpram(which, scanoffset |[which]++)*/int ScanArgList (int which); / * == Read Dpram (which, scanoffset | [which] ++) * /

T-JobPtr AllocJP(int firstarg,…) ;T-JobPtr AllocJP (int firstarg,…);

한편, Job Pointer 구조체를 할당하여 그 포인터를 리턴하는 함수의 수행은 다음과 같다.On the other hand, the function to allocate the Job Pointer structure and return the pointer is as follows.

T-JobPtr jp1, jp2 ;T-JobPtr jp1, jp2;

float ret ;float ret;

jp1-AllocJP(ENDOFARG) ; 리턴인자를 필요로 하지 않을 경우jp1-AllocJP (ENDOFARG); If no return argument is required

jp2 AllocJP(POSTJOB, postfunc, INTARG, 2, 0, 1 FLOATPTRARG, 1, indentret, ENDOFARG) ; /* 후처리 함수로 postfunc를 사용하고, 그 인자로 0,1을 indent 리턴인자로 ret를 사용할 경우 */jp2 AllocJP (POSTJOB, postfunc, INTARG, 2, 0, 1 FLOATPTRARG, 1, indentret, ENDOFARG); / * If we use postfunc as a post-processing function and 0,1 as the argument and ret as the indent return argument, * /

여기서, 상기 함수들은 마스터 모듈을 이용한 라이브러리화에만 필요하고, 실제 라이브러리를 사용하는 프로그램에서는 알 필요가 없다.Here, the functions are only necessary for librarying using a master module, and do not need to be known in a program using an actual library.

마스터 CPU의 Interrupt Vector 함수Interrupt Vector Function of Master CPU

void MasterIntrVector (…)void MasterIntrVector (…)

{ int jobid, which ;{int jobid, which;

begin ;begin;

which= Check Intr( ) ;which = Check Intr ();

jobid= Read Dpram(which, DSPINTPC) ;jobid = Read Dpram (which, DSPINTPC);

Cmdstat[which]=CMDSTAT-NONE ;Cmdstat [which] = CMDSTAT-NONE;

if (SysJobPtrPtr[which])if (SysJobPtrPtr [which])

{if (SysJobPtrPtr[which]→postjob){if (SysJobPtrPtr [which] → postjob)

SysJobPtrPtr[which]→postjob(*SysJobPtrPtr[which], which) ; /*후처리 함수*/SysJobPtrPtr [which] → postjob (* SysJobPtrPtr [which], which); / * Postprocess function * /

*SysJobPtrPtr[which]=0 ; /* job pointer 변수를 0으로 만듦* SysJobPtrPtr [which] = 0; / * zero the job pointer variable

*/ SysJobPtrPtr[which]=0 ; }* / SysJobPtrPtr [which] = 0; }

if ((which=Check Intr( )) -1 /* vector 수행중 들어온 요구를 처리 */ }if ((which = Check Intr ()) -1 / * Handle requests coming in during vector execution * /}

이상과 같이 지금까지는 마스터 모듈의 동작과 그에 관련된 함수 및 변수에 관한 정의 등을 살펴보았다.So far, we have looked at the operation of the master module and the definitions of functions and variables related to it.

그러면, 이제부터는 슬레이브 모듈에 관하여 설명해 보기로 한다.Now, the slave module will be described.

슬레이브 모듈의 동작을 순서에 입각해서 단계별로 정리해 보면 다음과 같다.The operation of the slave module can be summarized as follows in order.

마스터 모듈의 동작에서와 같이 최초의 초기화단계에서는 우선 관련 변수들의 초리값을 설정하게 된다.As in the operation of the master module, in the initial initialization stage, the initial values of related variables are set first.

즉, JobFunc[all job id's] = all job funstions ;That is, JobFunc [all job id's] = all job funstions;

JobId = 0 ;JobId = 0;

그와 같이 초기값 설정이 완료되면, 마스터 CPU로부터 지시받은 작업을 수행하고, DPRAM에 그 결과를 기록한 후 마스터 CPU로 인터럽트를 걸어주게 되는데 다음과 같은 순서에 의해 진행된다.When the initial value setting is completed as described above, it performs the operation instructed by the master CPU, writes the result in DPRAM, and interrupts the master CPU.

1) 먼저 인터럽트 벡터 함수에서 JobId를 읽어 들인다. (슬레이브 CPU 의 Interrupt Vector 함수 참조)1) First read the JobId from the interrupt vector function. (See Interrupt Vector Function of Slave CPU.)

2) 그런 후, 메인 함수로 돌아가 해당함수를 호출한다. (슬레이브 모듈의 함수 정의참조)2) Then return to the main function and call it. (See Function Definition of Slave Module)

3) 해당 함수 내에서, 마스터 CPU가 넘겨 준 인자들을 DPRAM을 통하여 읽어들인 후, 작업을 수행하고, 결과를 DPRAM에 적어 놓은 후, 마스터 CPU에 인터럽트를 보내게 된다. 이와 같은 일련의 작업이 수행됨에 있어서, 시스템에 사용된 가상프로그램 및 C++언어를 표기해 보면 다음과 같다.3) Within the function, the parameters passed by the master CPU are read through the DPRAM, the task is executed, the results are written in the DPRAM, and the interrupt is sent to the master CPU. In this series of operations, the virtual program and C ++ language used in the system are as follows.

슬레이브 모듈의 변수 정의Variable Definition of Slave Module

int JobId ;int JobId;

void (*Job Func[NUM-JOB]) (void) ;void (* Job Func [NUM-JOB]) (void);

슬레이브 모듈의 함수 정의Function definition of slave module

void main(void)void main (void)

{ JobId = 0{JobId = 0

while(1) /*JobId는 Interrupt Vector에서*/while (1) / * JobId is * / in Interrupt Vector

if (JobId) /*값을 읽어들임*/if (JobId) / * read the value * /

JobFunc(JobId) ( ) ;JobFunc (JobId) ();

JobId=0 ;JobId = 0;

Write Dpram(DSPINTPC, DSP-CMDINT) ; }Write Dpram (DSPINTPC, DSP-CMDINT); }

슬레이브 CPU의 Interrupt Vector 함수Interrupt Vector Function of Slave CPU

void SlaveIntrVector( )void SlaveIntrVector ()

{ JobId = Read Dpram(PCINTDSP) ; }{JobId = Read Dpram (PCINTDSP); }

마스터 CPU에서의 작업의 지시 과정Instruction process of work on the master CPU

마스터 모듈을 이용하여 라이브러리(Library)내의 어떤 함수를 구축할 때, 다음과 같은 단계로 진행된다.When building a function in a library using a master module, the following steps are taken:

1) JodPointer jp를 할당한다.1) Assign JodPointer jp.

2) arglist[ ]에 필요한 인자들을 복사한다.2) Copy the necessary arguments to arglist [].

3) callSlaveCPU(which, jobid, jp, argsize, arglist) ;3) callSlaveCPU (which, jobid, jp, argsize, arglist);

슬레이브 CPU에서의 작업의 수행 과정Execution of work on slave CPUs

JobFunc[jobid] 로 대입되는 기능함수의 수행순서는 다음과 같다.The execution order of function functions assigned to JobFunc [jobid] is as follows.

1) argsize를 읽는다.(DPRAM에서)1) Read argsize (in DPRAM)

2) argument들을 읽는다.(DPRAM에서)2) Read the arguments (in DPRAM)

3) 목적하는 작업을 수행한다.3) Perform the desired task.

4) 리턴 결과를 DPRAM에 기록한다.4) Write the return result to DPRAM.

이상의 설명에서와 같이 본 발명에 따른 일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법은 Job Pointer변수를 이용함으로써 특정 슬레이브 CPU의 번호를 기억할 필요가 없고, 작업의 성격에 알맞는 변수이름을 정의하여 작업을 수행하므로 객체지향적인 프로그래밍을 할 수 있으며, 리턴인자는 작업의 완료시에 자동으로 지정된 변수에 읽어들이므로 종래와 같이 리턴 인자를 불러오기 위해 일일이 프로그램해야 하는 번거로움이 없을 뿐만 아니라, 응용프로그램의 소스(source) 코드의 길이를 줄여 프로그램을 한층 단순화시킬 수 있다.As described above, the parallel processing method in the one-to-many master-slave operation unit according to the present invention does not need to remember the number of a specific slave CPU by using a Job Pointer variable, and defines a variable name suitable for the nature of the job. This allows you to do object-oriented programming, and the return argument is automatically read into the designated variable upon completion of the task, so you don't have to program it in order to get the return argument as usual. You can further simplify your program by reducing the length of your program's source code.

Claims (2)

대상 시스템에 관련되는 변수들에 초기값을 설정하는 단계, 마스터 CPU로부터 특정 슬레이브 CPU에 소정의 작업을 지시하는 단계, 지시받은 작업을 수행하고 결과를 DPRAM에 기록한 후, 마스터 CPU로 인터럽트를 걸어주는 단계, 및 상기 슬레이브 CPU에 지시한 작업이 완료되면 작업지시 구조체에 대한 포인터 변수(job pointer)를 0(zero)화 하는 단계를 포함하여 된 것을 특징으로 하는 일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법.Setting an initial value to variables related to the target system, instructing a specific slave CPU from a predetermined task, performing a designated task, writing a result to DPRAM, and interrupting the master CPU. In the one-to-many master-slave operation unit, characterized in that it comprises the step of zeroing a pointer variable (job pointer) for the work instruction structure when the job instructed to the slave CPU is completed. Parallel processing method. 제 1항에 있어서, 상기 마스터 CPU가 슬레이브 CPU에게 지시할 작업의 내용과 리턴되는 결과 및 작업의 완료여부를 하나의 구조체 및 그를 가리키는 변수데이타로 저장하여 그 작업의 지시를 위한 함수에 인자로서 포함시켜 호출하는 방식을 지닌 모듈의 구동프로그램의 일부로 포함하는 방식으로 된 것을 특징으로 하는 일대다 마스터-슬레이브 방식 연산장치에서의 병렬처리 방법.The method of claim 1, wherein the master CPU stores the contents of the task to be instructed to the slave CPU, the result to be returned, and whether the task is completed as a structure and variable data indicating the same and included in the function for the instruction of the task. A parallel processing method in a one-to-many master-slave type computing device, characterized in that it is included as part of a drive program of a module having a method of calling.
KR1019940023457A 1994-09-15 1994-09-15 The method of parallel processing for one to master slave KR0123855B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1019940023457A KR0123855B1 (en) 1994-09-15 1994-09-15 The method of parallel processing for one to master slave

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1019940023457A KR0123855B1 (en) 1994-09-15 1994-09-15 The method of parallel processing for one to master slave

Publications (2)

Publication Number Publication Date
KR960011720A KR960011720A (en) 1996-04-20
KR0123855B1 true KR0123855B1 (en) 1997-12-09

Family

ID=19392927

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1019940023457A KR0123855B1 (en) 1994-09-15 1994-09-15 The method of parallel processing for one to master slave

Country Status (1)

Country Link
KR (1) KR0123855B1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5995742A (en) * 1997-07-25 1999-11-30 Physical Optics Corporation Method of rapid prototyping for multifaceted and/or folded path lighting systems

Also Published As

Publication number Publication date
KR960011720A (en) 1996-04-20

Similar Documents

Publication Publication Date Title
US4924382A (en) Debugging microprocessor capable of switching between emulation and monitor without accessing stack area
US5361352A (en) Method for debugging in a parallel computer system and system for the same
KR0123855B1 (en) The method of parallel processing for one to master slave
KR0136111B1 (en) Apparatus and method for synhcronization of access to main memory signal groups in a multiprocessor data processing
JPH0552535B2 (en)
Jensen et al. The Honeywell Modular Microprogram Machine: M3
Huxtable et al. Dynamic supervisors-their design and construction
JPS616740A (en) Program control method in computer system
JPS61204703A (en) Developing device for engine control computer system
JPS6020275A (en) Simple programming system of multiprocessor
JPS61101865A (en) Multi-microprocessor system
JP2502128B2 (en) Compiler device
JPS5965307A (en) Sequence controller
JPS61228546A (en) Executing system for memory diagnosis and program loading
JPH03218539A (en) Debug method in parallel computer system
KR950010484B1 (en) A real-time operation method for an electronic exchanger
JPH0883198A (en) Program simulation device
JPH04299734A (en) Software developing method
JPH04165433A (en) Debugging system for operating system
WALKER Multiprocessor systems in laboratory automation
JPS609294B2 (en) Tracing method in electronic computers
Bercaw Software handlers for process interfaces
Soma et al. A priority interrupt oriented hybrid executive
Unger et al. An operating system implementation and simulation language (OASIS)
JPH03266139A (en) Program debugging system

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20050830

Year of fee payment: 9

LAPS Lapse due to unpaid annual fee