Exceptions
#include <poplar/exceptions.hpp>
-
namespace poplar
Poplar classes and functions.
Enums
-
enum class RecoveryAction
An enumeration that specifies how to recover from a recoverable_runtime_error.
Values:
-
enumerator IPU_RESET
Reset the IPU and reload IPU memory.
-
enumerator PARTITION_RESET
Reset the IPU partition. This retrains the IPU-links between IPUs.
-
enumerator FULL_RESET
Power cycle the system.
-
enumerator IPU_RESET
Functions
-
std::string toString(RecoveryAction recoveryAction)
Convert the recovery action to a string.
-
std::ostream &operator<<(std::ostream &os, RecoveryAction recoveryAction)
-
struct application_runtime_error : public poplar::runtime_error
- #include <exceptions.hpp>
This exception is thrown when running a program fails due to an error in the program or a misuse of an API.
-
struct control_program_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when the construction of a graph program is invalid.
-
struct file_load_error : public poplar::poplar_error
-
struct graph_connection_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown during construction of an Engine object if there is an error in the structure of graph, for example, if there are no edges to a vertex input or if there are multiple edges to a vertex input.
-
struct graph_cycle_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown during the construction of an Engine object if there are any cycles in the graph that are not broken by recurrent edges.
-
struct graph_memory_allocation_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an memory allocation fails.
-
struct graph_object_creation_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown in the construction of a GraphProgEnv object if there was an error in the creation of the graph program object file.
-
struct graph_object_load_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown in the construction of a GraphProgEnv object if there was an error in loading the graph program object file.
-
struct graph_program_compilation_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown in the construction of a GraphProgEnv object if there are any compilation errors in the graph program.
-
struct graph_recursion_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown during the construction of an Engine object if there are recursive calls.
-
struct graph_replication_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an invalid operation is carried out on a replicated graph.
-
struct index_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if the index of a subscript is out of the bounds of the field it is accessing or if a index of a tensor is invalid.
-
struct invalid_machine_model : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an invalid model of the IPU (for performance model profiling) has been specified.
-
struct invalid_option : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an unrecognised or invalid option is passed to a Poplar API.
-
struct invalid_tile_mapping : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when the tile mapping passed to the UserTilePartitioner is invalid.
-
struct link_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when the linking stage for codelets fails.
output is the output from the linker command.
-
struct memory_elem_constraints_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an invalid memory element constraint has been provided in a codelet.
-
struct missing_graph_profile : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if the graph and/or execution profile is required but the graph profile that should had been generated during compilation is not found.
-
struct missing_perf_estimate : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an Engine is constructed with profiling enabled but a vertex does not have a getPerfEstimate method specified.
-
struct missing_profile_data : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if a profile is requested after compilation but the data that is required to generate it is not present in the executable.
-
struct no_environment : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown, in the construction of a GraphProgEnv object, in mixed-mode compilation, if there is no graph-programming environment available, in particular if the program has not been compiled with the ‘popc’ command-line tool.
-
struct no_size_specified : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if the size of a field is not specified in a Graph object when an EngineBuilder object is constructed.
-
struct overflow_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an arithmetic overflow occurs within Poplar.
-
struct parse_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an input file or string cannot be parsed.
-
struct poplar_error : public runtime_error
- #include <exceptions.hpp>
Base class for Poplar exceptions.
Subclassed by poplar::control_program_error, poplar::file_load_error, poplar::graph_connection_error, poplar::graph_cycle_error, poplar::graph_memory_allocation_error, poplar::graph_object_creation_error, poplar::graph_object_load_error, poplar::graph_program_compilation_error, poplar::graph_recursion_error, poplar::graph_replication_error, poplar::index_error, poplar::invalid_machine_model, poplar::invalid_option, poplar::invalid_tile_mapping, poplar::link_error, poplar::memory_elem_constraints_error, poplar::missing_graph_profile, poplar::missing_perf_estimate, poplar::missing_profile_data, poplar::no_environment, poplar::no_size_specified, poplar::overflow_error, poplar::parse_error, poplar::profiling_disabled, poplar::runtime_error, poplar::stream_connection_error, poplar::stream_memory_allocation_error, poplar::symbol_error, poplar::tensor_creation_error, poplar::tensor_io_state_error, poplar::tensor_metadata_error, poplar::type_error, poplar::unknown_field, poplar::unknown_vertex_type
Public Functions
-
explicit poplar_error(const char *s)
-
void attachSourceLocation(const DebugContext &context)
-
const char *what() const noexcept override
-
~poplar_error() override
-
explicit poplar_error(const char *s)
-
struct profiling_disabled : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if profiling information is requested from an Engine but that Engine has not been constructed with profiling enabled.
-
struct recoverable_runtime_error : public poplar::system_runtime_error
- #include <exceptions.hpp>
This exception is thrown when when running a program fails due to a system error that is likely to be transient.
getRecoveryAction() indicates what to do to recover from this error.
Public Functions
-
inline RecoveryAction getRecoveryAction() const
Return the action required to recover from error.
-
explicit recoverable_runtime_error(RecoveryAction recoveryAction, const std::string &s)
-
explicit recoverable_runtime_error(RecoveryAction recoveryAction, const char *s)
-
~recoverable_runtime_error() override
Private Members
-
RecoveryAction recoveryAction
-
inline RecoveryAction getRecoveryAction() const
-
struct runtime_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when running a program on a system fails.
Subclassed by poplar::application_runtime_error, poplar::system_runtime_error
Public Members
-
struct ErrorInfo
Public Members
-
ErrorLocation location
An object that uniquely specifies the location of an error in a device.
If this attribute has not been set
(bool)location
will be false.
-
bool isSimulated
True if the exception has been simulated and false otherwise.
-
ErrorLocation location
-
struct ErrorInfo
-
struct stream_connection_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an invalid attempt is made to connect a data stream.
-
struct stream_memory_allocation_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when allocation of stream buffers fails.
-
struct symbol_error : public poplar::poplar_error
-
struct system_runtime_error : public poplar::runtime_error
- #include <exceptions.hpp>
This exception is thrown when running a program fails due to an error in the system it is running on.
Subclassed by poplar::recoverable_runtime_error, poplar::unknown_runtime_error, poplar::unrecoverable_runtime_error
-
struct tensor_creation_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown in the construction of a tensor if invalid arguments are provided to the tensor creation function or method.
-
struct tensor_io_state_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when an attempt is made to mark a tensor as an input or output, but the argument references a view of a tensor, rather than a whole tensor.
-
struct tensor_metadata_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown if a tensor uses a type that requires metadata and the metadata is not accessible.
-
struct type_error : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when there is an error related to the field types of vertices, for example, when the source of an edge contains an input, the types of inputs and source field between an edge do not match, or when a field cannot be subscripted.
-
struct unknown_field : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when a field name is specified that does not exist in the graph-programming environment.
-
struct unknown_runtime_error : public poplar::system_runtime_error
- #include <exceptions.hpp>
This exception is throw when execution fails due to a system error where the cause cannot be automatically determined, for example a timeout without a specific error being raised.
-
struct unknown_vertex_type : public poplar::poplar_error
- #include <exceptions.hpp>
This exception is thrown when a vertex type name is specified that does not exist in the graph programming environment.
-
struct unrecoverable_runtime_error : public poplar::system_runtime_error
- #include <exceptions.hpp>
This exception is thrown when execution fails due to a system error that is likely to persist.
The system should be taken out of operation for analysis and repair.
-
enum class RecoveryAction