set_directive_shared

Description

The set_directive_shared command specifies that a global variable, or function argument array is shared among multiple dataflow processes without any synchronization mechanism.

IMPORTANT: There is no checking for the SHARED pragma or directive, so you must ensure the functional correctness of the sharing, including during co-simulation.

Syntax

set_directive_shared <location> <variable>
  • <location> is the location (in the format function[/label]) where the variable to share is found.
  • <variable> The name of the variable that does not change during execution of the function.

Options

This command has no options.

Example

In this example, variable a is shared among processes under the p1 dataflow region:

set_directive_shared p1 a

See Also