dtrace_lookup_by_type, dtrace_symbol_type, dtrace_type_fcompile, dtrace_type_strcompile - DTrace type interface
cc [ flag... ] file... -ldtrace [ library... ] #include <dtrace.h> int dtrace_lookup_by_type(dtrace_hdl_t *dtp, const char *object, const char *name, dtrace_typeinfo_t *tip) int dtrace_symbol_type(dtrace_hdl_t *dtp, const GElf_Sym *symp, const dtrace_syminfo_t *sip, dtrace_typeinfo_t *tip) int dtrace_type_fcompile(dtrace_hdl_t *dtp, FILE *fp, dtrace_typeinfo_t *tip) int dtrace_type_strcompile(dtrace_hdl_t *dtp, const char *s, dtrace_typeinfo_t *tip)
The dtrace_lookup_by_type() function performs a lookup of the type, name in the module, object. The function returns the type information in tip, an opaque data structure.
The dtrace_symbol_type() function looks up the type information for the symbol described by the symp and sip arguments, and returns it in the tip argument.
The dtrace_type_fcompile() and dtrace_type_strcompile() functions take a D language type, either in a string, s or a in a file referred to by the fp argument. The functions add the type information to the information stored in the dtp argument, and return a reference to that type in the tip argument.
On successful completion, these functions return 0. On failure, these functions return -1 and set the DTrace error number to indicate the reason for the failure. See the dtrace_errno(3DTRACE) man page for more information.
The dtrace_lookup_by_type() function will fail if:
dtp is NULL.
The named module, object does not exist. (if a module name is given)
The type does not exist in the specified module.
The system failed to allocate memory while processing this function.
The dtrace_symbol_type() function will fail if:
The value of the dtp, symp, sip, or tip argument is NULL.
The module specified in the sip argument does not exist.
The symbol specified in the sip argument does not exist in the specified module.
There was a backend-type system error when looking up the symbol.
The dtrace_type_fcompile() and dtrace_type_strcompile() functions will fail if:
dtp, fp or s (respectively), or dtt is NULL.
The system was unable to allocate memory while processing this function.
See attributes(7) for descriptions of the following attributes:
|
libdtrace(3LIB), dtrace_errno(3DTRACE), dtrace_lookup_by_name(3DTRACE), dtrace_type_name(3DTRACE), gelf(3ELF)