The PDI specification tree is expressed in YAML.
The specification tree root is a mapping that contains the following keys:
| key | value |
|---|---|
| "types" (optional) | a types_map |
| "data" (optional) | a data_map |
| "metadata" (optional) | a data_map |
| "plugins" (optional) | a plugin_map |
| "logging" (optional) | a logging |
| "plugin_path" (optional) | a plugin_path |
| ".*" (optional) | anything |
A array_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "array" |
| "size" | a intexpr_or_seq |
| "subtype" (optional) | a datatype |
| "subsize" (optional, deprecated) | a intexpr_or_seq |
| "start" (optional, deprecated) | a intexpr_or_seq |
| "\+.*" (optional) | anything |
A array_type_node represents a potentially multi-dimensional array where:
A byte_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "byte" |
| "\+.*" (optional) | anything |
A byte_type represents the C++ byte type. It accepts no parameter.
Example:
A char_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "char" |
| "\+.*" (optional) | anything |
A char_type represents the C char datatype; it accepts no parameter.
A character_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "character" |
| "kind" (optional) | a integer-valued $-expression |
| "\+.*" (optional) | anything |
A character_type_node represents the Fortran character datatype, where:
A data_map is a mapping that contains the following keys:
| key | value |
|---|---|
| ".*" (optional) | a datatype |
A datatype can be any of:
simple_datatype is just a string that identifies the referenced type. All others cases are dictionaries whose type key identifies the type.
A datatype represents the memory layout and interpretation for data exposed by the user in the data store.
Optional attributes can be added to any datatype. An attribute is identified by a key that starts with the + character. The value can be anything (scalar, sequence or mapping).
A datatype_with_disp is a mapping that must be a valid datatype with an additional disp key:
| key | value |
|---|---|
| "disp" | a integer-valued $-expression |
| "type" | a type identifier |
| ".*" (*datatype *) | see datatype |
A double_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "double" |
| "\+.*" (optional) | anything |
A double_type represents the C double type; it accepts no parameter.
A $-expression is a scalar whose content matches the following grammar:
The rules for evaluating an expression are close to those of BASH for example.
In addition to raw text, a STRING_LITERAL can contain references to the string value of some data in the store as well as the result of an operation by enclosing it inside a dollar-parenthesis $().
An OPERATION can include logical and arithmetic operators grouped by parenthesis. The basic terms manipulated in an operation can be integer literals or references to the integer value of some data in the store.
A REFERENCE is introduced by a dollar $ sign and optionally enclosed in curly braces {, }. Its value is that of the data or metadata with the associated name. It is always a good idea to have referenced values in the metadata section as it prevents dangling references. Value formatting can be applied using a FMT format_spec string by adding a column : followed by the format_spec after a column just before the closing bracket } (see: https://fmt.dev/latest/syntax.html#grammar-token-format_spec). A direct reference is possible as well as sub-references to:
The value-type of an EXPRESSION is as follow:
In addition, an integer can be interpreted as a string or as a boolean value where zero is interpreted as false and any other value as true.
The following strings can also be interpreted as a boolean integer values:
A float_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "float" |
| "\+.*" (optional) | anything |
A float_type represents the C float type. It accepts no parameter.
A int_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int" |
| "\+.*" (optional) | anything |
A int_type represents the C int type. It accepts no parameter.
A int16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int16" or "int16_t" |
| "\+.*" (optional) | anything |
A int16_type represents the C int16_t type from the <stdtypes.h> header. It accepts no parameter.
A int32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int32" |
| "\+.*" (optional) | anything |
A int32_type represents the C int32_t type from the <stdtypes.h> header. It accepts no parameter.
A int64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int64" |
| "\+.*" (optional) | anything |
A int64_type represents the C int64_t type from the <stdtypes.h> header. It accepts no parameter.
A int8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int8" |
| "\+.*" (optional) | anything |
A int8_type represents the C int8_t type from the <stdtypes.h> header. It accepts no parameter.
A integer_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "integer" |
| "kind" (optional) | a integer-valued $-expression |
| "\+.*" (optional) | anything |
A integer_type represents the Fortran integer datatype.
A intexpr_or_seq can be any of:
In that context, a simple $-expression is interpreted as a shortcut for a sequence containing a single $-expression.
For example, the following value:
is interpreted as if it was:
A intexpr_seq is a sequence where each element of the sequence is a integer-valued $-expression.
A int_fast16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_fast16" or "int_fast16_t" |
| "\+.*" (optional) | anything |
A int_fast16_type represents the C int_fast16_t type from the <stdint.h> header. It accepts no parameter.
A int_fast32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_fast32" or "int_fast32_t" |
| "\+.*" (optional) | anything |
A int_fast32_type represents the C int_fast32_t type from the <stdint.h> header. It accepts no parameter.
A int_fast64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_fast64" or "int_fast64_t" |
| "\+.*" (optional) | anything |
A int_fast64_type represents the C int_fast64_t type from the <stdint.h> header. It accepts no parameter.
A int_fast8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_fast8" or "int_fast8_t" |
| "\+.*" (optional) | anything |
A int_fast8_type represents the C int_fast8_t type from the <stdint.h> header. It accepts no parameter.
A int_least16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_least16" or "int_least16_t" |
| "\+.*" (optional) | anything |
A int_least16_type represents the C int_least16_t type from the <stdint.h> header. It accepts no parameter.
A int_least32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_least32" or "int_least32_t" |
| "\+.*" (optional) | anything |
A int_least32_type represents the C int_least32_t type from the <stdint.h> header. It accepts no parameter.
A int_least64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_least64" or "int_least64_t" |
| "\+.*" (optional) | anything |
A int_least64_type represents the C int_least64_t type from the <stdint.h> header. It accepts no parameter.
A int_least8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "int_least8" or "int_least8_t" |
| "\+.*" (optional) | anything |
A int_least8_type represents the C int_least8_t type from the <stdint.h> header. It accepts no parameter.
A intmax_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "intmax" or "intmax_t" |
| "\+.*" (optional) | anything |
A intmax_type represents the C intmax_t type from the <stdint.h> header. It accepts no parameter.
A intptr_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "intptr" or "intptr_t" |
| "\+.*" (optional) | anything |
A intptr_type represents the C intptr_t type from the <stdint.h> header. It accepts no parameter.
A logging can be any of:
A logging is fully supported in specification tree root and any plugin_map .
A logging_level is a scalar which determines verbosity level. It can be set to (from the most to the least verbose):
Examples:
A logging_map is a mapping that contains the following keys:
| key | value |
|---|---|
| "level" (optional) | a logging_level |
| "pattern" (optional) | a logger prefix pattern of spdlog |
| "output" (optional) | a logging_output_map |
Example:
A logging_output_map is a mapping that contains the following keys:
| key | value |
|---|---|
| "file" (optional) | a path of the file where to write logs |
| "console" (optional) | on or off |
Example:
See struct_type for more examples.
A logical_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "logical" |
| "kind" (optional) | a integer-valued $-expression |
| "\+.*" (optional) | anything |
A logical_type represents the Fortran logical datatype.
A long_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "long" |
| "\+.*" (optional) | anything |
A long_type represents the C long type. It accepts no parameter.
Example:
A long_long_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "long long" |
| "\+.*" (optional) | anything |
A long_long_type represents the C long long type. It accepts no parameter.
Example:
A plugin_map is a mapping that contains the following keys:
| key | value |
|---|---|
| ".*" (optional) | anything |
Have a look at the plugins documentation to see the specification tree they accept.
See specification tree root for an example.
A path to directory where PDI should search for plugins. It can be single path:
or array of paths (PDI will take first match):
A pointer_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "pointer" |
| "subtype" | a datatype |
| "\+.*" (optional) | anything |
A pointer_type represents a memory address where data is actually stored (a pointer) where:
A ptrdiff_t_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "ptrdiff_t" |
| "\+.*" (optional) | anything |
A ptrdiff_t_type represents the C ptrdiff_t type from the <stddef.h> header. It accepts no parameter.
Example:
A real_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "real" |
| "kind" (optional) | a integer-valued $-expression |
| "\+.*" (optional) | anything |
A real_type represents the Fortran real datatype.
A record_members_map is a mapping that contains the following keys:
| key | value |
|---|---|
| ".*" (optional) | a datatype_with_disp |
See record_type for an example.
A record_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "record" |
| "buffersize" | a integer-valued $-expression |
| "members" (optional) | a record_members_map |
| "\+.*" (optional) | anything |
A record_type represents a "record" where:
A short_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "short" |
| "\+.*" (optional) | anything |
A short_type represents the C short type. It accepts no parameter.
A simple_datatype is a scalar.
It is interpreted as a shortcut for a mapping with a single key type whose value is the provided scalar and therefore another datatype.
For example, the following value:
is interpreted as if it was:
A size_t_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "size_t" |
| "\+.*" (optional) | anything |
A size_t_type represents the C size_t type from the <stddef.h> header. It accepts no parameter.
Example:
A struct_members_omap is an ordered mapping that contains the following keys:
| key | value |
|---|---|
| ".*" (optional) | a datatype |
See struct_type for an example.
A struct_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "struct" |
| "members" (optional) | a struct_members_omap |
| "\+.*" (optional) | anything |
A struct_type represents a C "struct" or C++ "class" using the default C memory layout, where:
matches:
A tuple_elements_seq is a sequence where each element of the sequence is a datatype_with_disp where disp key is optional.
See tuple_type for an example.
A tuple_elements_seq is a sequence where each element of the sequence is either a datatype or a datatype_with_disp.
If datatypes with no explicit offset are used, the minimum offset that does not lead to overlaps is used.
See tuple_type for an example.
A tuple_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "tuple" |
| "buffersize" (optional) | a integer-valued $-expression |
| "elements" (optional) | a tuple_elements_seq |
| "\+.*" (optional) | anything |
A tuple_type represents a "tuple", where:
A types_map is a mapping that contains the following keys:
| key | value |
|---|---|
| ".*" (optional) | a datatype |
A uint16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint16" or "uint16_t" |
| "\+.*" (optional) | anything |
A uint16_type represents the C uint16_t type from the <stdint.h> header. It accepts no parameter.
A uint32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint32" or "uint32_t" |
| "\+.*" (optional) | anything |
A uint32_type represents the C uint32_t type from the <stdint.h> header. It accepts no parameter.
A uint64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint64" or "uint64_t" |
| "\+.*" (optional) | anything |
A uint64_type represents the C uint64_t type from the <stdint.h> header. It accepts no parameter.
A uint8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint8" or "uint8_t" |
| "\+.*" (optional) | anything |
A uint8_type represents the C uint8_t type from the <stdint.h> header. It accepts no parameter.
A uint_fast16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_fast16" or "uint_fast16_t" |
| "\+.*" (optional) | anything |
A uint_fast16_type represents the C uint_fast16_t type from the <stdint.h> header. It accepts no parameter.
A uint_fast32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_fast32" or "uint_fast32_t" |
| "\+.*" (optional) | anything |
A uint_fast32_type represents the C uint_fast32_t type from the <stdint.h> header. It accepts no parameter.
A uint_fast64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_fast64" or "uint_fast64_t" |
| "\+.*" (optional) | anything |
A uint_fast64_type represents the C uint_fast64_t type from the <stdint.h> header. It accepts no parameter.
A uint_fast8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_fast8" or "uint_fast8_t" |
| "\+.*" (optional) | anything |
A uint_fast8_type represents the C uint_fast8_t type from the <stdint.h> header. It accepts no parameter.
A uint_least16_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_least16" or "uint_least16_t" |
| "\+.*" (optional) | anything |
A uint_least16_type represents the C uint_least16_t type from the <stdint.h> header. It accepts no parameter.
A uint_least32_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_least32" or "uint_least32_t" |
| "\+.*" (optional) | anything |
A uint_least32_type represents the C uint_least32_t type from the <stdint.h> header. It accepts no parameter.
A uint_least64_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_least64" or "uint_least64_t" |
| "\+.*" (optional) | anything |
A uint_least64_type represents the C uint_least64_t type from the <stdint.h> header. It accepts no parameter.
A uint_least8_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uint_least8" or "uint_least8_t" |
| "\+.*" (optional) | anything |
A uint_least8_type represents the C uint_least8_t type from the <stdint.h> header. It accepts no parameter.
A uintmax_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uintmax" or "uintmax_t" |
| "\+.*" (optional) | anything |
A uintmax_type represents the C uintmax_t type from the <stdint.h> header. It accepts no parameter.
A uintptr_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "uintptr" or "uintptr_t" |
| "\+.*" (optional) | anything |
A uintptr_type represents the C uintptr_t type from the <stdint.h> header. It accepts no parameter.
A unsigned_long_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "unsigned long long" |
| "\+.*" (optional) | anything |
A unsigned_long_type represents the C unsigned long type. It accepts no parameter.
A unsigned_long_long_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "unsigned long long" |
| "\+.*" (optional) | anything |
A unsigned_long_long_type represents the C unsigned long long type. It accepts no parameter.
A unsigned_short_type is a mapping that contains the following keys:
| key | value |
|---|---|
| "type" | "unsigned short" |
| "\+.*" (optional) | anything |
A unsigned_short_type represents the C unsigned short_t type from the <stdint.h> header. It accepts no parameter.