source: rtems-central/spec/rtems/barrier/req/perf-release-manual-preempt.yml @ 79cc481

Last change on this file since 79cc481 was 79cc481, checked in by Sebastian Huber <sebastian.huber@…>, on 11/24/21 at 14:33:17

spec: Add performance requirements

  • Property mode set to 100644
File size: 2.2 KB
Line 
1SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
2copyrights:
3- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
4enabled-by: true
5limits: {}
6links:
7- role: requirement-refinement
8  uid: perf-runtime
9- role: runtime-measurement-request
10  uid: ../val/perf
11non-functional-type: performance-runtime
12params: {}
13rationale: null
14references: []
15requirement-type: non-functional
16test-body:
17  brief: |
18    Release the barrier.
19  code: |
20    uint32_t count;
21
22    ctx->status = rtems_barrier_release( ctx->barrier_id, &count );
23  description: null
24test-cleanup:
25  brief: |
26    Delete the barrier and the worker.
27  code: |
28    rtems_status_code sc;
29
30    DeleteTask( ctx->worker_id );
31
32    sc = rtems_barrier_delete( ctx->barrier_id );
33    T_rsc_success( sc );
34
35    RestoreRunnerPriority();
36  description: null
37test-prepare:
38  brief: |
39    Create a manual release barrier.  Create and start a worker task.
40  code: |
41    rtems_status_code sc;
42
43    sc = rtems_barrier_create(
44      OBJECT_NAME,
45      RTEMS_BARRIER_MANUAL_RELEASE,
46      0,
47      &ctx->barrier_id
48    );
49    T_rsc_success( sc );
50
51    SetSelfPriority( PRIO_NORMAL );
52    ctx->worker_id = CreateTask( "WORK", PRIO_HIGH );
53    StartTask( ctx->worker_id, BarrierWaitWorker, ctx );
54  description: null
55test-setup: null
56test-teardown:
57  brief: |
58    Set the measured runtime.  Discard samples interrupted by a clock tick.
59  code: |
60    T_quiet_rsc_success( ctx->status );
61
62    *delta = ctx->end - ctx->begin;
63
64    return tic == toc;
65  description: null
66text: |
67  Let ``U` and `V`` be two tasks with the same home scheduler.  Let :math:`B`
68  be a time point measured by ``U`` right before a call to
69  ${../if/release:/name} which preempts the caller.  Let :math:`E` be a time
70  point measured by ``V`` right after a call to ${../if/wait:/name} returns
71  successfully due to the ${../if/release:/name} call associated with
72  :math:`B`.  While the execution environment is ${.:/environment}, while the
73  barrier is a manual release barrier, while the measurement sample is :math:`E
74  - B`, when exactly ${../val/perf:/params/sample-count} samples are collected,
75  the ${.:/limit-kind} shall be ${.:/limit-condition}.
76type: requirement
Note: See TracBrowser for help on using the repository browser.