Ginkgo  Generated from pipelines/1330831941 branch based on master. Ginkgo version 1.8.0
A numerical linear algebra library targeting many-core architectures
Public Member Functions | List of all members
gko::AllocationError Class Reference

AllocationError is thrown if a memory allocation fails. More...

#include <ginkgo/core/base/exception.hpp>

Inheritance diagram for gko::AllocationError:
[legend]
Collaboration diagram for gko::AllocationError:
[legend]

Public Member Functions

 AllocationError (const std::string &file, int line, const std::string &device, size_type bytes)
 Initializes an allocation error. More...
 
- Public Member Functions inherited from gko::Error
 Error (const std::string &file, int line, const std::string &what)
 Initializes an error. More...
 
virtual const char * what () const noexcept override
 Returns a human-readable string with a more detailed description of the error.
 

Detailed Description

AllocationError is thrown if a memory allocation fails.

Constructor & Destructor Documentation

◆ AllocationError()

gko::AllocationError::AllocationError ( const std::string &  file,
int  line,
const std::string &  device,
size_type  bytes 
)
inline

Initializes an allocation error.

Parameters
fileThe name of the offending source file
lineThe source code line number where the error occurred
deviceThe device on which the error occurred
bytesThe size of the memory block whose allocation failed.

The documentation for this class was generated from the following file: