osate / osate2

Open Source AADL2 Tool Environment
http://osate.org
Eclipse Public License 2.0
36 stars 8 forks source link

Compute_Execution_Time on ports ignored by flow analysis tool #2040

Closed philip-alldredge closed 4 years ago

philip-alldredge commented 4 years ago

Summary

Compute_Execution_Time is ignored by the flow analysis tool when applied to a event data port.

Expected and Current Behavior

According to the definition of Compute_Execution_Time in the AADL standard, Compute_Execution_Time on ports should be applied to the thread when the event data port triggers the thread dispatch. I expect that the flow analysis tool to take the specified value into account when performing the analysis.

Currently, the value is ignored. The value on the thread is used if it is specified.

Steps to Reproduce

  1. Use Compute_Execution_Time on an event data port.
  2. Run flow analysis.
package compute_execution_time_issue
public
    process top
    end top;

    process implementation top.impl
        subcomponents
            t1: thread t1;
            t2: thread t2;
        connections
            top_impl_new_connection: port t1.o1 -> t2.i1;
            top_impl_new_connection2: port t1.o2 -> t2.i2;
        flows
            etef1: end to end flow t1.src1 -> top_impl_new_connection -> t2.snk1;
            etef2: end to end flow t1.snk2 -> top_impl_new_connection2 -> t2.snk2;
    end top.impl;

    thread t1
        features
            o2: out data port;
            o1: out data port;
        flows
            snk2: flow source o2;
            src1: flow source o1;
        properties
            dispatch_protocol => Periodic;
            period => 100ms;
    end t1;

    thread t2
        features
            i1: in event data port { Compute_Execution_Time => 30ms..40ms; }; -- Value is ignored
            i2: in event data port { Compute_Execution_Time => 10ms..20ms; }; -- Value is ignored
        flows
            snk2: flow sink i2;
            snk1: flow sink i1;
        properties
            dispatch_protocol => Aperiodic;

            -- This value is used for both flows. If it is not specified, the analysis tool does not use any Compute_Execution_Time value.
            Compute_Execution_Time => 60ms..80ms;

    end t2;

end compute_execution_time_issue;

Environment

lwrage commented 4 years ago

Duplicate of #1940