Resource key tree method and system for recursive tree modeling programs
A recursive tree and resource technology, applied in the field of resource key tree method and system for recursive tree modeling program, can solve design and other problems, and achieve the effect of improving the scope of application and resource allocation performance
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0027] as attached Figure 1-5 Shown, airborne light of the present invention is a kind of resource key tree method for recursive tree modeling program, comprises the following steps:
[0028] S1. Modeling the resource request program as a recursive tree model;
[0029] S2. Initialize the safety detection algorithm, and use the algorithm to calculate the lower bound of the resources required by the target node to perform tasks;
[0030] S3. Calculate the difference between the available resources and the lower bound of the resource, if the difference is positive, allocate resources to the target node; if the difference is negative, reclaim the resource, to avoid deadlock;
[0031] The resource lower bound of the target node includes the minimum resource requirements of the target node and all its child nodes.
[0032] The safety detection in the above resource key tree method is to perform deadlock judgment or resource allocation according to the minimum resource that can pr...
Embodiment 2
[0047] as attached image 3 As shown, in order to solve the above technical problems, the present invention also provides a resource key tree system for recursive tree modeling programs, including the following units:
[0048] a modeling unit for modeling the resource request program as a recursive tree model;
[0049] A resource lower bound calculation unit, connected to the modeling unit, used to calculate the resource lower bound required by the target node for performing tasks and detect whether the resource request is safe;
[0050] A resource allocation unit, connected to the resource lower bound calculation unit, for calculating the difference between available resources and the resource lower bound, if the difference is positive, allocate resources to the target node; if the difference is negative, recycle resources , to avoid deadlock;
[0051] The resource lower bound of the target node includes the minimum resource requirements of the target node and all its child...
Embodiment 3
[0056] In order to better illustrate the technical solution of the present invention, the following are detailed steps during specific implementation;
[0057] as attached Figure 4As shown, the execution of the program consists of two phases, a tree output tree phase, which starts each task computation in a top-down manner (southbound), first allocating the resources it needs, and then launching its A subtask thread, this process is repeated recursively by all its subtasks until the leaf task is complete; another input tree stage is then started, stepping through the recursive process from bottom to top (northbound) until the root task is complete. Thus, a program's resource request graph can be obtained by combining the output tree and input tree stages into a recursive tree. Given this model, the parent and child nodes of each node can be defined from the perspective of the output tree and the input tree, for example Figure 4 , for node C, from the output tree stage, A i...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


