Pass Registration

Macros to register a plugin’s passes.

Pass registration macros should be called at global scope (not within a function/method).

In order to avoid accidentally registering a pass twice, it is recommended to call registration macros from a *.cpp* file rather than a *.h* file.

Registration macros only add the pass to a list of passes to register. This is useful if you have passes defined in several **.cpp** files in your module. It is up to the module developer to call registerModulePasses() and deregisterModulePasses() to perform the actual registration.

See Passes for more pass related functionality.

Classes

Macros

Enumerations

Functions

Enumerations

enum class omni::graph::exec::unstable::PassType

Grouping type for different passes.

Graph transformation pass is registered with a given type and type can’t be changed after.

See Passes for more pass related functionality.

Note

We are not yet using all these states…expect changes.

Values:

enumerator ePopulate

open-up graph types

enumerator ePartitioning

change granularity of executions (including executors)

enumerator eGlobal

pass is running over entire graph. no other passes can run now

enumerator eTypeInference

resolve types

enumerator eOverrideExecution

override compute methods, executors, etc

enumerator eScheduling

memory access, pipeline stages, etc

enumerator eCount

total number of known pass types

Functions

inline void omni::graph::exec::unstable::deregisterModulePasses() noexcept

Deregisters the module’s omni::graph::exec::unstable::IPass factories with IPassRegistry.

Failure to call this function may lead to crashes during program shutdown.

This function should be called in the module’s function registered with omni::core::OMNI_MODULE_ON_MODULE_UNLOAD(). This is usually called onUnload().

When developing a Kit extension, prefer calling OMNI_KIT_EXEC_CORE_ON_MODULE_UNLOAD() rather than this function.

See Pass Registration for more information about pass registration.

Thread Safety

This function is not thread safe.

inline IPassRegistry *omni::graph::exec::unstable::getPassRegistry() noexcept

Returns the singleton pass registry.

Returns a singleton containing the pass registry.

See Pass Registration for more information about pass registration.

inline void omni::graph::exec::unstable::registerModulePasses() noexcept

Registers the module’s omni::graph::exec::unstable::IPass factories with omni::graph::exec::unstable::IPassRegistry.

This function should be called in the module’s function registered with omni::core::OMNI_MODULE_ON_MODULE_STARTED(). This is usually called onStarted().

When developing a Kit extension, prefer calling OMNI_KIT_EXEC_CORE_ON_MODULE_STARTED() rather than this function.

See Pass Registration for more information about pass registration.

Thread Safety

This function is not thread safe.