According to the OpenMP 5.0 standard, names and hints of critical operation are
closely related. The following are the restrictions on them:
- Unless the effect is as if hint(omp_sync_hint_none) was specified, the critical construct must specify a name.
- If the hint clause is specified, each of the critical constructs with the same name must have a hint clause for which the hint-expression evaluates to the same value.
These restrictions will be enforced by design if the hint expression is a part
of the omp.critical.declare operation.
- Any operation with no "name" will be considered to have hint(omp_sync_hint_none).
- All the operations with the same "name" will have the same hint value.