Methods and devices for quitting and deleting thread or process in embedded C language environment

A C language and embedded technology, applied in the field of C language, can solve problems such as occupying resources and unusable other threads or processes

Inactive Publication Date: 2011-08-24
HUAWEI TECH CO LTD
View PDF1 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The embodiment of the present invention is to provide a method and device for exiting a thread or process in an embedded C language environment, and a method and device for deleting a thread or process in an embed

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
  • Methods and devices for quitting and deleting thread or process in embedded C language environment
  • Methods and devices for quitting and deleting thread or process in embedded C language environment
  • Methods and devices for quitting and deleting thread or process in embedded C language environment

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0027] In order to make the object, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and examples.

[0028] In the embodiment of the present invention, for exceptions in the embedded system under the C language environment, targeted exception handling programs can be written according to different scenarios, and partial exception handling and recovery attempts can be performed without restarting the system for all exceptions. Continue to execute after the exception is handled, thereby improving the efficiency of code operation under normal processes and simplifying programming. The implementation of the exception handling framework (for easy understanding, it can be called an exception handling device) in the embedded system in the C language environment does not depend on the compiler, and provides users with a method for finely managing the exception ...

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

The embodiment of the invention discloses methods and devices for quitting and deleting a thread or a process in an embedded C language environment. The method for quitting the thread or the process is used in an active quit scene of the thread, and comprises the following steps of: obtaining information that the thread or the process is needed to be quitted; checking whether the abnormity thrown by the thread or the process needed to be quitted still occupies resource; if so, releasing the occupied resource; and quitting the thread or the process. Thereby, no matter the thread or the process is quitted or deleted, the resource occupied by processing the abnormity thrown by the thread or the process can be released, when other threads or processes need the resource, the resource can be used by other threads or processes without still being occupied by the abnormity thrown by the deleted or quitted thread or process.

Description

[0001] This application is a divisional application of a Chinese patent application submitted to the China Patent Office on June 3, 2008 with the application number 200810100060.5 and the title of the invention "Exception Handling Method and Device in Embedded C Language Environment". technical field [0002] The invention relates to the C language technology, in particular to the exception handling technology under the embedded C language environment. Background technique [0003] An exception is an abnormal condition that occurs when a hardware or software program is running. In the embedded C language environment, the traditional exception handling method is to restart the system when an exception is found. Taking program exceptions as an example, you can check whether an exception occurs when the program is running through the exception identification ability of the CPU. Once the CPU finds that an exception occurs when the program is running, it will call the exception h...

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
IPC IPC(8): G06F11/36
Inventor 余加强郑伟
Owner HUAWEI TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products