Unlock instant, AI-driven research and patent intelligence for your innovation.

Memory managing system and task controller in multitask system

A task control and multi-task technology, applied in the direction of program control design, instruments, sewing equipment, etc., can solve the problem of deteriorating interrupt response performance and achieve the effect of reducing the available amount

Inactive Publication Date: 2005-02-23
PANASONIC CORP
View PDF0 Cites 13 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

However, the disadvantage of this method is that it deteriorates the interrupt response performance

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Memory managing system and task controller in multitask system
  • Memory managing system and task controller in multitask system
  • Memory managing system and task controller in multitask system

Examples

Experimental program
Comparison scheme
Effect test

no. 1 approach

[0026] figure 1 It is a block diagram showing a method of using a stack in a multitasking system according to the present invention. In terms of setting the location of the stack 107 that handles interrupts, the multitasking system is more efficient than figure 2 The conventional multitasking system shown is more distinctive.

[0027] exist figure 2 In the shown conventional multitasking system, three tasks 102, 104 and 106 and an interrupt handler 108 run on an operating system 109 (hereinafter referred to as OS). Stack areas 101, 103, 205, and 207 are independently prepared for tasks or programs. The task with the lowest priority among the three tasks is called the idle task 106 . When executing the idle task, it indicates a state in which the system has no task to process and an external interrupt is waiting to be entered.

[0028] exist figure 1 In the shown multitasking system according to the present invention, three tasks 102, 104 and 106 and an interrupt hand...

no. 2 approach

[0048] The multitasking system described in the first embodiment of the present invention can include Figure 10 It can also be implemented in the idle task of other processing shown in the flow chart, or it can only include Figure 9 Implemented in the idle task of the simple infinite loop shown. Figure 10 , as shown in step S1001, the idle task program executes a process of jumping the operation mode of the CPU to the low power consumption mode. Here, after the CPU jumps to the low power consumption mode, subsequent instructions are not executed until an interrupt is received. When an interrupt request enters the CPU and the low power consumption mode is released, the CPU returns to normal operation mode and executes Figure 7 OS interrupt input processing shown in the flowchart in .

[0049] The r0 register is used as a CPU register when the operation mode of the CPU transitions to the low power consumption mode. In this case, the value of the r0 register needs to be s...

no. 3 approach

[0057] The first embodiment and the second embodiment are described by paying attention to idle tasks. However, the same approach can be applied to normal tasks other than idle tasks when the CPU registers used by the tasks are identified with certainty. Also, the CPU registers used by a task are not statically determined. Even in this case, the method described in the second embodiment can be applied to CPU registers whose data can be overwritten as well as CPU registers whose data does not need to be overwritten by retaining information in variables of task processing or the like. Furthermore, when a high-level language such as C language is used, the method described in the second embodiment can be employed such that the compiler stores information related to CPU registers in the form of variables or SP difference information storage registers provided on the CPU.

[0058] Figure 13 It represents the task controller of the present invention for realizing the above-mentio...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

When an interrupt is generated during the operation of an idle task, after the value of a CPU register is stored in a current stack area, and then, the current stack area is switched to a stack area exclusively used for processing an interrupt. At this time, stacks have a structure in which the stack area is superposed on the stack area exclusively used for processing the interrupt. When the interrupt is generated during an idle process, the stack for processing the interrupt is used so as to overwrite the area in which the value of the CPU register is stored. Thus, an amount of use of RAM is reduced by commonly using a stack used in an interrupt process with a stack used in an idle process in a multitask system.

Description

technical field [0001] The invention relates to a method for managing software stack memory, in particular, the invention relates to a program structure for reducing the available amount of stack memory when executing a multi-task system. Background technique [0002] With the complexity of the control in the program, a multitasking system that can process two or more tasks as work units at a time by a computer has been widely used. The adoption of multi-tasking systems allows efficient switching and execution of multiple tasks. [0003] image 3 Schematically shows an example of RAM in use in a common multitasking system. image 3 Areas denoted by reference numerals in , indicate stack memory areas (hereinafter referred to as stacks) used in respective tasks. In particular, on RAM, multiple stacks with multiple tasks 1, 2, ... and task n are constructed, a stack for idle tasks, and a stack only for handling interrupts executed by the multitasking system stack. [0004] T...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/46G06F9/48
CPCG06F9/4812G06F9/461D05C11/18
Inventor 小玉将义小林圭太
Owner PANASONIC CORP