How to detect task disappearance

By evaluating the duration difference between parent tasks and subtasks in a multi-processing unit system, detecting the appearance and disappearance of subtasks, and issuing alarms, data problems caused by the disappearance of non-periodic tasks are solved, and the stability of engine control is improved.

CN112840323BActive Publication Date: 2025-01-21VTESCO TECH GMBH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN201980058964.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2018-09-11
Filing Date
2019-09-10
Publication Date
2025-01-21
Estimated Expiration
2039-09-10

AI Technical Summary

Technical Problem

In multi-processing unit systems, the disappearance of non-periodic tasks may lead to data loss, inconsistency or damage, which in turn causes engine control instability, and the operating system is difficult to detect and report tasks disappearing in a timely manner when the load is too heavy.

Method used

An operating system-independent method is proposed to detect whether the appearance of a subtask disappears by evaluating the duration difference between the parent task and the subtask, and raise an alarm when the disappearance is detected. The method consists of calculating the duration between the last and penultimate occurrences of the parent task and the subtask, and comparing the two. If the duration of the subtask is significantly greater than the duration of the parent task, then it is concluded that the subtask appears and disappears. in conclusion.

Benefits of technology

It can detect the appearance and disappearance of subtasks quickly and independently of the operating system, prevent data corruption or inconsistency, and improve the stability of engine control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112840323B_ABST
    Figure CN112840323B_ABST
Patent Text Reader

Abstract

The present invention relates to a method for detecting task disappearance in an environment, wherein the environment comprises at least one repetitive parent task (TM), wherein the parent task (TM) triggers at least one child task (TF) at each occurrence in a nominal mode, the method comprising the following steps: evaluating a parent duration (DTMi) elapsed between a last occurrence (TMi) and a second to last occurrence (TMi‑1) of the parent task (TM); evaluating a child duration (DTFi) elapsed between a last occurrence (TFi) and a second to last occurrence (TFi‑1) of a child task (TF); comparing the parent duration (DTMi) and the child duration (DTFi), and if the child duration (DTFi) is greater than the parent duration (DTMi), preferably with a certain margin, then concluding that the occurrence of the child task (TF) disappears.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention generally relates to the field of engine control. In particular, the present invention is directed to a method for detecting mission disappearance. Background Art

[0002] For software such as controls for operating an internal combustion engine, it is known to divide the complete software into tasks. A task is a piece of software that is executed sequentially on a single processing unit. Thus, in a multi-processing unit system such as a multi-core processor, a task is the basic unit of software distributed over multiple units. In such software, tasks are often iterative, in that an occurrence of the task is executed each time an event occurs. ). If the recurring event is periodic, then the task is then periodic, and if the recurring event is non-periodic, then the task is non-periodic. In the case of engine control, there are two types of tasks: periodic tasks that are clocked according to a fixed period; and non-periodic tasks that are clocked by events that are recurring but not periodic. Examples of non-periodic tasks are tasks that are synchronized with the rotation of the engine, such as tasks that are related to engine speed, such as tasks that are clocked by a predetermined leading edge of a crankshaft sensor.

[0003] Splitting initially ordered software segments to distribute them on multiple processing units generates several tasks. These tasks should be executed in the same order as originally in the split software segments, even if they are executed on different processing units. To this end, consecutive tasks are usually linked: an upstream task or parent task in the sequence triggers the execution of a downstream task or child task.

[0004] The operating system manages the execution of tasks by enabling higher priority tasks to execute quickly while protecting the execution of lower priority tasks.

[0005] Certain non-periodic tasks that are synchronized with the engine will see their pseudo-period decrease as the engine speed increases. This results in an increased computational load on the processor(s) that must execute such tasks more frequently. In the case of excessive load, the operating system must take steps to regulate this load. To do this, the operating system arbitrates and may eventually delete a task. Other reasons may also be the source of task disappearance.

[0006] If the execution of linked tasks from one software segment is not robust with respect to task disappearance, the information consumed or produced by the disappeared task may become missing, inconsistent or corrupted. This may cause faults that may lead to detrimental engine control instabilities.

[0007] Depending on how it is implemented, the operating system may report its deletion. However, the monitoring and / or diagnostic functions that do the reporting are executed at a very low priority. And under heavy load, the information about the deletion / disappearance of the task is known too late to take effective countermeasures to correct the consequences of the disappearance.

[0008] Additionally, if the disappearance of a task is not due to arbitration, the operating system may not be notified of the disappearance.

[0009] One of the consequences of this problem will now be explained based on a simplified example comprising a recurring parent task TM which is executed on a processing unit C1 and which, at each occurrence of this task, triggers a child task TF which is executed on another processing unit C2 .

[0010] Typically, recurring events are marked with E. Their occurrences are explicitly indicated by an index. For ease of description, an occurrence of an event can be marked by an absolute index or a relative index. Absolute indexing uses lowercase letters in alphabetical order. Relative indexing uses the notation ij, where i represents the last occurrence, here the absolute occurrence c, and j represents the rank of the operation relative to the occurrence i. Thus, three consecutive elements are marked in an absolute way: Ea, Eb, Ec. If Ec is the last occurrence to occur, it is also the last occurrence and is marked with Ei. Similarly, the second-to-last occurrence is marked with Ei-1, the third-to-last occurrence is marked with Ei-2, and so on. For example, if the parent task is marked with TM, its second occurrence is marked with TMb, and its second-to-last occurrence is marked with TMi-1. The letter T represents the task. The letter D represents the duration. The letter t represents a time or date. The letter M explicitly indicates the "parent" and the letter F explicitly indicates the "child". The letter X represents data.

[0011] exist Figures 1 to 4 In Figure 1, time flows from left to right. The first row involves the first processing unit C1 or core, the middle row represents the shared memory M, and the third row involves the second processing unit C2 or core. Rectangles represent the occurrence of tasks. Rounded rectangles represent exchanged data. Dashed arrows represent the triggering or linking of tasks. Solid arrows represent data read and write operations.

[0012] Figure 1 The timing diagram of shows a nominal situation exemplified by means of a parent task TM and a child task TF, wherein three consecutive occurrences TMa, TMb, TMc are shown. Since TMc is the last occurrence, it is also labeled as TMi. TMb is the second to last occurrence and is also labeled as TMi-1. TMa is the third to last occurrence and is also labeled as TMi-2.

[0013] The last occurrence TMi or TMc of the parent task TM generates the last data Xi or Xc, records it in the memory M, and triggers the execution of the last occurrence TFi or TFc of the child task TF. The last TFi or TFc reads the last data Xi or Xc again to process it. Similarly, before, the second-to-last occurrence TMi-1 or TMb generates the second-to-last data Xi-1 or Xb and records it in the memory M, so that the second-to-last occurrence TFi-1 or TFb can read and process it again. Still before, the third-to-last occurrence TMi-2 or TFa generates the third-to-last data Xi-2 or Xa and records it in the memory M, so that the third-to-last occurrence TFi-2 or TFa can read and process it again.

[0014] Figure 2 The timing diagram of shows a problematic situation. Here, a subtask TF, the second occurrence TFb, disappears. As a result, the missing occurrence TFb neither reads nor processes the corresponding data Xb. Next, depending on whether there is a data protection mechanism, either the data Xb is never read and therefore never processed, as shown in the figure; or the data Xb is read and processed, but by the next occurrence of the subtask TF, the subsequent occurrence TFc. Both situations are problematic and constitute situations of data corruption or inconsistency.

[0015] It can be noted that here Figure 1 Unlike the case of , if TFc is the last occurrence of the subtask and is labeled TFi, then in the absence of TFb, its immediately preceding occurrence is the occurrence TFa, which is then the penultimate occurrence TFi-1 here.

[0016] It is important to note that the relative index still applies and only to the occurrences that actually exist, i.e., for the task, to the occurrences that were actually executed. Here, when the absolute occurrence TFb disappears, the relative index (the second to last, i-1) is transferred to the previous occurrence that was actually executed, i.e., to the occurrence TFa. Summary of the invention

[0017] The object of the present invention is to propose a method for detecting the disappearance of a task which can work independently of the operating system and which can provide a disappearance detection indication as quickly as possible.

[0018] This object is achieved by a method for detecting task disappearance in an environment, the environment comprising at least one repetitive parent task, the parent task triggering at least one child task at each occurrence in a nominal mode, the method comprising the following steps: evaluating a parent duration elapsed between the last occurrence and the second to last occurrence of the parent task, evaluating a child duration elapsed between the last occurrence and the second to last occurrence of the child task, comparing the parent duration and the child duration, concluding that the occurrence of the child task has disappeared if the child duration is greater than the parent duration (preferably with a certain margin), and issuing an alarm.

[0019] According to another feature, the disappearance of the subtask is concluded if the subtask duration is equal to the sum of the last parent duration and the second to last parent duration (preferably with a certain margin).

[0020] According to another feature, the sum of the last mother duration and the second to last mother duration is approximated by twice the last mother duration.

[0021] According to another feature, the margin is equal to p multiplied by the trigger delay, the trigger delay being equal to the duration between the parent task triggering the subtask and the subtask starting execution, where p is an integer, preferably equal to 2, and still preferably, the margin is equal to 1 ms.

[0022] According to another feature, each occurrence of a task preferably records its execution date in a shared memory in order to prepare an evaluation of the parent duration or of the child duration.

[0023] According to another feature, the parent duration is evaluated by the occurrence of the parent task and / or the child duration is evaluated by the occurrence of the child task.

[0024] According to another feature, the parent duration or the child duration is evaluated by comparing the execution date of an occurrence of the parent task or the child task with the execution date of a previous occurrence, the execution date of which is read again from a record in the memory or is known if the occurrence is the occurrence for which the calculation is performed, and the execution date of the previous occurrence is read again from a record in the memory.

[0025] According to another feature, the estimate of the parent duration DTMi and / or the estimate of the child duration DTFi are recorded after they have been calculated, preferably in a shared memory M, in order to be ready for comparison.

[0026] According to another feature, the step of comparing the parent duration and the child duration is performed by the occurrence of the subtask.

[0027] According to another feature, when the occurrence of a subtask leads to the conclusion of the disappearance of the occurrence of a subtask, the disappearance of the occurrence is the occurrence immediately preceding the previous one.

[0028] According to another feature, the parent task is non-periodic.

[0029] According to another feature, the parent task and the subtask are executed in a multi-processing unit environment, preferably on different processing units.

[0030] According to another feature, the method is implemented in an engine control, wherein the parent task is synchronized with an event related to the engine speed.

[0031] According to another feature, the parent task is a task of detecting a given angular position of the crankshaft, such as the top dead center (PMH, or TDC in English) position, and the subtasks are tasks of performing processing after such detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Other novel features and advantages of the invention will become apparent from a reading of the following description, given in an indicative and by no means limiting sense, and from a reference to the accompanying drawings, in which:

[0033] Figure 1 shows a timing diagram illustrating the nominal case,

[0034] Figure 2 shows a timing diagram illustrating a problematic situation, where the occurrence of a subtask disappears,

[0035] Figure 3 A timing diagram illustrating the solution of the problem under nominal conditions is shown,

[0036] Figure 4 A sequence diagram illustrating problem solving in a problematic situation is shown, wherein the occurrence of a subtask disappears. DETAILED DESCRIPTION

[0037] For increased clarity, the same or similar elements are marked with the same reference numerals throughout the drawings.

[0038] The invention relates to a method for detecting the disappearance of a task in an environment comprising at least one recurring parent task TM. Each occurrence TMi, TMi-1, TMi-2 of the task triggers at least one subtask TF. It should be clear that this triggering occurs in a nominal mode. In practice, the deletion of a task may also be caused by the parent task TM not triggering the subtask TF. The method of the invention also detects this situation.

[0039] In the context of engine control, it has been shown that the loss of a task can be critical. Thus, for example, in the case of a task to detect the top dead center, the disappearance of the task leads to a switch to the detection of the next top dead center, i.e. the top dead center corresponding to the next cylinder. The calculation of the cylinder number to which the combustion parameters should apply is then incorrect. As a result, for example, the amount of fuel injected is no longer optimal. Such a detrimental situation leads to the emission of pollutants and / or excessive consumption. The aim of the method is to avoid such situations and their consequences.

[0040] The detection method is characterized in that it comprises the following steps. In a first step, the parent duration DTMi that passes between the last occurrence TMi and the second to last occurrence TMi-1 of the parent task TM is evaluated. Similarly, in a second step, the child duration DTFi that passes between the last occurrence TFi and the second to last occurrence TFi-1 of the child task TF is evaluated. These two durations DTMi and DTFi are then compared. In the example Figure 3 In the nominal case shown in FIG. 1 , where no task disappears, the two durations DTMi and DTFi are substantially equal. Figure 4 In the problematic case shown in which at least one occurrence of the subtask TF disappears, the subduration DTFi is significantly greater than the parent duration DTMi. Moreover, if the subduration DTFi is greater than the parent duration DTMi (preferably with a certain margin), it is concluded that the occurrence of the subtask TF disappears.

[0041] In the event of a conclusion of disappearance, the method also includes issuing an alarm. The form of the alarm depends on the function associated with the task. This may involve recording the state in a memory of a computer (such as an engine computer), which is more particularly prepared for use by maintenance personnel; or it may also involve signaling the vehicle driver, for example by triggering an indicator light on the dashboard or an acoustic signal.

[0042] This technical feature enables early detection of the disappearance of the appearance of the subtask TF.

[0043] In order to obtain a more robust disappearance detection, the previous condition "DTFi>DTMi+margin" can be replaced by the replacement condition "DTFi≈DTMi+DTMi-1+ / -margin". In other words, if the sub-duration DTMi is equal to the sum of the last parent duration DTMi and the second to last parent duration DTMi-1, combined with a certain margin, it is concluded that the appearance of the subtask TF disappears. Such a replacement condition advantageously makes it possible to prevent the appearance of a lag from being mistakenly considered to have disappeared. The disadvantage is that the appearance of multiple consecutive disappearances cannot be detected.

[0044] The parent task TM can be periodic. In this case, the last parent duration DTMi and the penultimate parent duration DTMi-1 are equal. The parent task TM can also be non-periodic. For example, this is the case when the parent task TM indexes events related to the engine speed. In this case, the last parent duration DTMi and the penultimate parent duration DTMi-1 are different. However, the difference is still small, and they can be assumed to be equal at least within several consecutive pseudo-periods. Moreover, in both cases (periodic or non-periodic), the sum of the last parent duration DTMi and the penultimate parent duration DTMi-1 can be approximated to twice the last parent duration DTMi.

[0045] It can be noted that the model can be extended to detect the occurrence of multiple consecutive missing. Therefore, under the following conditions, the conclusion of the disappearance of the subtask TF is obtained: the sub-duration DTMi is basically equal to one of the sums of the previous parent durations plus a certain margin; or in the case of a simplified assumption, it is equal to qx DTMi plus a certain margin, where q is an integer equal to 2 or 3... or n, where n is the depth of the expected detection task disappearance (i.e., the number of consecutive disappearing tasks).

[0046] The subtask TF follows the periodic or aperiodic model of the parent task TM.

[0047] The margin can be chosen arbitrarily. Its function is to add tolerance so that the test condition is not fooled into thinking that the presence of hysteresis has disappeared.

[0048] According to a possible embodiment, the margin is equal to p times the trigger delay DD. The trigger delay DD is equal to the duration between the parent task TM triggering the subtask TF and the subtask TF starting to execute, which is determined by Figures 1 to 4 The trigger delay DD is substantially constant, independent of the period or pseudo-period between two occurrences of the parent task or the child task and the load of the processing unit. p is an integer and is preferably equal to 2. According to another preferred embodiment, the margin is equal to 1 ms.

[0049] In order to calculate the parent duration DTM or the child duration DTF, according to one possible embodiment, each occurrence TMi, TMi-1, TMi-2, TFi, TFi-1, TFi-2 of the parent or child task TM, TF records its respective execution date tMi, tMi-1, tMi-2, tFi, tFi-1, tFi-2. This record is preferably recorded in the shared memory M. The corresponding next occurrence can then read this value again and calculate the duration DTM, DTF by comparing it with its own execution date. This feature advantageously involves both the parent task TM to calculate the parent duration DTM and the child task TF to calculate the child duration DTF.

[0050] Therefore, if we refer to Figure 3 , the first occurrence TMa or TMi-2 of the parent task TM records its execution date tMi-2 or tMa in the memory M when it is executed, the next occurrence of the parent task TM - the second occurrence TMb or TMi-1 records its execution date tMi-1 or tMb in the memory M when it is executed, and the next occurrence of the parent task TM - the third occurrence TMc or TMi records its execution date tMi or tMc in the memory M when it is executed. Similarly, the first occurrence TFa or TFi-2 of the subtask TF records its execution date tFi-2 or tFa in the memory M when it is executed, the next occurrence of the subtask TF - the second occurrence TFb or TFi-1 records its execution date tFi-1 or tFb in the memory M when it is executed, and the next occurrence of the subtask TF - the third occurrence TFc or TFi records its execution date tFi or tFc in the memory M when it is executed.

[0051] According to an advantageous embodiment, the parent duration DTMi is evaluated by the occurrence TMi of the parent task TM. Advantageously, the occurrence TMi of the parent task TM evaluates its parent duration DTMi distance from the immediately preceding occurrence TMi-1 of the parent task TM. Similarly, the subduration DTFi is evaluated by the occurrence TFi of the subtask TF. Advantageously, the occurrence TFi of the subtask TF evaluates its subduration DTFi distance from the immediately preceding occurrence TFi-1 of the subtask TF.

[0052] According to one embodiment, the parent duration DTMi or the child duration DTFi is evaluated by comparing the execution date tMi, tFi of an occurrence TMi, TFi of the parent task TM or the child task (TF) with the execution date tMi-1, tFi-1 of the previous occurrence, wherein the execution date tMi, tFi of the occurrence TMi, TFi is read again from the record or is known if the occurrence TMi, TFi is the occurrence for performing the calculation, and the execution date tMi-1, tFi-1 of the previous occurrence is read again from the record.

[0053] Therefore, if we refer to Figure 3 and Figure 4 , the second-to-last parent duration DTMi-1 is advantageously evaluated by the second occurrence TMb or TMi-1 of the parent task TM. This occurrence reads again from the memory M during its execution the execution date tMi-2 or tMa recorded in the memory by the previous occurrence TMa or TMi-2. The second occurrence TMb or TMi-1 of the parent task TM that performs this evaluation advantageously knows its own execution date tMb or tMi-1 without having to read it again from the memory M. The evaluation can then be obtained by calculating the difference tMb-tMa=tMi-1-tMi-2=DTMi-1. Similarly, the last parent duration DTMi is advantageously evaluated by the third occurrence TMc or TMi of the parent task TM. This occurrence reads again from the memory during its execution the execution date tMi-1 or tMb recorded in the memory by the previous occurrence TMb or TMi-1. The third occurrence TMc or TMi advantageously knows its own execution date tMc or tMi. The estimate can then be obtained by calculating the difference tMc-tMb=tMi-tMi-1=DTMi.

[0054] refer to Figure 3, a similar process enables the second occurrence TFb or TFi-1 of the subtask TF to evaluate the subduration DTFi-1. This occurrence reads again from the memory M during its execution the execution date tFi-2 or tFa recorded in the memory by the previous occurrence TFa or TFi-2. The second occurrence TFb or TFi-1 advantageously knows its own execution date tFb or tFi-1. The evaluation can then be obtained by calculating the difference tFb-tFa=tFi-1-tFi-2=DTFi-1. Similarly, the third occurrence TFc or TFi of the subtask TF evaluates the subduration DTFi. This occurrence reads again from the memory M during its execution the execution date tFi-1 or tFb recorded in the memory by the previous occurrence TFb or TFi-1. The third occurrence TFc or TFi advantageously knows its own execution date tFc or tFi. The evaluation can then be obtained by calculating the difference tFc-tFb=tFi-tFi-1=DTFi.

[0055] refer to Figure 4 , the second occurrence TFb of the subtask TF has disappeared and the subduration DTFb or DTFi-1 cannot be evaluated. The third occurrence TFc or TFi of the subtask TF evaluates the subduration DTFi or DTFc. This occurrence reads from the memory again during its execution the execution date tFi-1—here tFa—recorded in the memory by the previous occurrence TFa or TFi-1. The third occurrence TFc or TFi advantageously knows its own execution date tFc or tFi. The evaluation can then be obtained by calculating the difference tFc-tFa=tFi-tFi-1=DTFi.

[0056] Thus, for each occurrence of a parent task TM or a subtask TF, its parent duration DTM or subduration DTF relative to the preceding occurrence is calculated.

[0057] According to another advantageous feature, each occurrence of a parent task TM records its parent duration DTM after evaluating said parent duration DTM, preferably in a shared memory M, so that it can be read again by another occurrence. Alternatively or additionally, each occurrence of a child task TF records its child duration DTF after evaluating said child duration DTF, preferably in a shared memory M, so that it can be read again by another occurrence.

[0058] If both the parent duration DTM and the child duration DTF are recorded, any entity having access to the shared memory M can read them again and compare them.

[0059] According to another feature, the comparison step is advantageously performed by the occurrence TFi of the subtask TF. The occurrence TFi reads again from the memory M the corresponding parent duration DTMi previously recorded by the corresponding occurrence TMi of the parent task TM. The occurrence TFi then has at its disposal the child duration DTFi that it has just evaluated and the parent duration DTMi with the corresponding rank that it has just read again, and can compare them. In this case, if the occurrence TFi of the subtask TF calculates the child duration DTFi and evaluates it, only the parent duration DTMi needs to be recorded and read again, the child duration DTFi being known.

[0060] Therefore, reference Figure 3 , the second occurrence TFb or TFi-1 of the subtask TF reads the corresponding parent duration DTMi-1 (with the same rank) from the memory again. This occurrence has the child duration DTFi-1 that it has evaluated, so it can compare the two corresponding parent durations DTMi-1 and child duration DTFi-1 (with the same rank). Similarly, the third occurrence TFc or TFi of the subtask TF reads the corresponding parent duration DTMi (with the same rank) from the memory again. This occurrence has the child duration DTFi that it has evaluated, so it can compare the two corresponding parent durations DTMi and child duration DTFi. Here, the comparison is affirmative.

[0061] refer to Figure 4 , the second occurrence TFb has disappeared and cannot be processed in any way. No comparison is made at this rank. The third occurrence TFc or TFi of the subtask TF reads the corresponding parent duration DTMi (with the same rank) from the memory again. This occurrence has the child duration DTFi it has evaluated and can then compare the two corresponding parent durations DTMi and child durations DTFi. Here, the comparison is negative.

[0062] When comparing the occurrences of the parent duration DTM and the child duration DTF to conclude that the occurrence of the subtask TF disappears, the disappearing occurrence is the one that immediately precedes the previous one. Figure 4 , when the last occurrence TFi or TFc of a subtask TF leads to the conclusion that the occurrence of the subtask TF disappears, the disappearing occurrence is the second to last occurrence TFi-1 or TFb before the occurrence TFi or TFc.

[0063] Thus, according to the invention, a disappearance can be detected very quickly after it has occurred.

[0064] The invention is particularly advantageous when the parent task TM and the child task TF are executed in an environment comprising a plurality of processing units C1 , C2 , preferably on different processing units C1 , C2 . Such an environment is prone to the problem of task deletion.

[0065] The present invention is applicable to engine control, preferably when the parent task TM is synchronized with an event related to the engine speed.

[0066] For example, the parent task TM is a task to detect a given angular position of the crankshaft, such as the top dead center (PMH, or TDC in English), and the subtask TF is a task to perform processing after such detection. The deletion of the occurrence of the subtask deletes the position detection and its processing. Moreover, the data that should have been cleaned up at the execution of the subtask is not cleaned up, and its previous value is harmfully retained.

[0067] The present invention has been described above by way of example. It should be appreciated that a person skilled in the art will be able to produce various implementation variations of the present invention, for example by combining the various features considered above alone or in combination, without departing from the scope of the present invention.

Claims

1. A method for detecting task disappearance in an environment, the environment comprising at least one recurring parent task, the parent task triggering at least one child task at each occurrence in a nominal mode, characterized in that: The method comprises the following steps: evaluate the parent duration that elapsed between the last and the second-to-last occurrence of the parent task, evaluate the sub-duration that elapses between the last and the second-to-last occurrence of a subtask, Compare the parent duration and the child duration. If the child duration is greater than the parent duration, it is concluded that the appearance of the child task disappears, and an alarm is issued.

2. The method according to claim 1, wherein: If the sub-duration is equal to the sum of the last parent duration and the second to last parent duration with a certain margin, it is concluded that the appearance of the subtask disappears.

3. The method according to claim 2, wherein: The sum of the last mother duration and the second-to-last mother duration is approximated by twice the last mother duration.

4. The method according to any one of claims 2 to 3, wherein: The margin is equal to p multiplied by the trigger delay, where the trigger delay is equal to the duration between the parent task triggering the subtask and the subtask starting execution, where p is an integer.

5. The method according to any one of claims 1 to 3, wherein: Each occurrence of a task records its execution date in order to prepare an estimate of the parent or child duration.

6. The method according to claim 5, wherein: The parent duration is evaluated by the occurrence of the parent task, and / or the child duration is evaluated by the occurrence of the child task.

7. The method according to claim 5, wherein: The parent duration is evaluated by comparing the execution date of an occurrence of the parent task with the execution date of a previous occurrence read again from the record in the memory, or the child duration is evaluated by comparing the execution date of an occurrence of the child task with the execution date of the previous occurrence read again from the record in the memory, wherein the execution date of the one occurrence is read again from the record in the memory or is known if the occurrence is the occurrence being calculated.

8. The method according to any one of claims 1 to 3, wherein: The parent duration and / or the child duration are recorded after the evaluation of the parent duration and / or the evaluation of the child duration in order to prepare for comparison.

9. The method according to any one of claims 1 to 3, wherein: The step of comparing the parent duration and the child duration is performed by the occurrence of the child task.

10. The method according to claim 9, wherein: When the occurrence of a subtask leads to the conclusion that the occurrence of a subtask disappears, the disappearing occurrence is the occurrence immediately preceding the previous one.

11. The method according to any one of claims 1 to 3, wherein: The parent task is non-periodic.

12. The method according to any one of claims 1 to 3, wherein: The parent task and the child tasks are executed in a multi-processing unit environment.

13. The method according to any one of claims 1 to 3, which is implemented in engine control, wherein: The parent task is synchronized with events related to engine speed.

14. The method according to claim 13, wherein: The parent task is a task of detecting a given angular position of the crankshaft, such as the top dead center position, and the child task is a task of performing processing after such detection.

Citation Information

Patent Citations

  • A method and system for preparing execution of systems management tasks on endpoints

    CN101297536A

  • Method for processing background tasks of mobile terminal and mobile terminal

    CN106125884A