HOME
| OPENMP API Specification: "Version 5.2 -- GIT rev 95b2e3a44"

8.5  error Directive

Name: error

Association: none

Category: utility

Properties: pure

Clauses

at, message, severity

Semantics

The error directive instructs the compiler or runtime to perform an error action. The error action displays an implementation-defined message. The severity clause determines whether the error action is abortive following the display of the message. If sev-level is fatal and action-time is compilation, the message is displayed and compilation of the current compilation unit is aborted. If sev-level is fatal and action-time is execution, the message is displayed and program execution is aborted.

Execution Model Events

The runtime-error event occurs when a thread encounters an error directive for which the at clause specifies execution.

Tool Callbacks

A thread dispatches a registered ompt_callback_error callback for each occurrence of a runtime-error event in the context of the encountering task. This callback has the type signature ompt_callback_error_t.

Restrictions

Restrictions to the error directive are as follows:

Cross References

  9.2.1  full Clause
  9.2.2  partial Clause