AI Engine API User Guide (AIE-API) 2024.1
Loading...
Searching...
No Matches
detail/utils.hpp File Reference
#include <array>
#include <cassert>
#include <tuple>
#include <type_traits>
#include "config.hpp"

Classes

class  std::numeric_limits<::bfloat16 >
 

Namespaces

namespace  aie
 Base namespace for AIE operations and types.
 
namespace  std
 

Macros

#define __AIE_API_DETAIL_UTILS__HPP__
 
#define REQUIRES(a)   REQUIRES_MSG(a, "Requirement " STRINGIFY(a) " not met")
 
#define REQUIRES_CONSTANT(a)
 
#define REQUIRES_CONSTANT_MSG(a, m)
 
#define REQUIRES_MSG(a, m)   RUNTIME_ASSERT(a, m)
 
#define RUNTIME_ASSERT(e, m)   assert(e && m)
 
#define RUNTIME_ASSERT_NO_ASSUME(e, m)   assert(e && m)
 
#define STATIC_ASSERT_CONSTANT(e, m)
 
#define STATIC_ASSERT_CONSTANT_EXPRESSION(e, m)
 
#define STRINGIFY(a)   STRINGIFY_(a)
 
#define STRINGIFY_(a)   #a
 
#define UNREACHABLE_MSG(m)
 

Macro Definition Documentation

◆ __AIE_API_DETAIL_UTILS__HPP__

#define __AIE_API_DETAIL_UTILS__HPP__

◆ REQUIRES

#define REQUIRES (   a)    REQUIRES_MSG(a, "Requirement " STRINGIFY(a) " not met")

◆ REQUIRES_CONSTANT

#define REQUIRES_CONSTANT (   a)

◆ REQUIRES_CONSTANT_MSG

#define REQUIRES_CONSTANT_MSG (   a,
 
)

◆ REQUIRES_MSG

#define REQUIRES_MSG (   a,
 
)    RUNTIME_ASSERT(a, m)

◆ RUNTIME_ASSERT

#define RUNTIME_ASSERT (   e,
 
)    assert(e && m)

◆ RUNTIME_ASSERT_NO_ASSUME

#define RUNTIME_ASSERT_NO_ASSUME (   e,
 
)    assert(e && m)

◆ STATIC_ASSERT_CONSTANT

#define STATIC_ASSERT_CONSTANT (   e,
 
)

◆ STATIC_ASSERT_CONSTANT_EXPRESSION

#define STATIC_ASSERT_CONSTANT_EXPRESSION (   e,
 
)

◆ STRINGIFY

#define STRINGIFY (   a)    STRINGIFY_(a)

◆ STRINGIFY_

#define STRINGIFY_ (   a)    #a

◆ UNREACHABLE_MSG

#define UNREACHABLE_MSG (   m)
Value:
do { \
assert(false && "Unreachable; " m); \
__builtin_unreachable(); \
} while (0)