Memory module
Memory management utilities.
Files
- file bn_alignment.h
- file bn_config_ewram.h
- file bn_ewram_wait_state.h
- file bn_memory.h
- file bn_memory_alias.h
- file bn_unique_ptr.h
Namespaces
- namespace bn
- Main Butano namespace.
- namespace bn::memory
- Memory related functions.
Classes
-
template<typename Type>struct bn::default_delete
- Default deleter.
Functions
Defines
- #define BN_CFG_EWRAM_WAIT_STATE
- #define BN_EWRAM_WAIT_STATE_2
- #define BN_EWRAM_WAIT_STATE_1
Function documentation
#include <bn_alignment.h>
template<int Bytes>
bool aligned(const void* pointer)
Indicates if the given void
pointer is aligned to the given Bytes.
#include <bn_alignment.h>
template<int Bytes, typename Type>
bool aligned(const Type* pointer)
Indicates if the given Type pointer is aligned to the given Bytes.
Define documentation
#define BN_CFG_EWRAM_WAIT_STATE
#include <bn_config_ewram.h>
Specifies EWRAM access time in clock cycles.
Values not specified in BN_EWRAM_WAIT_STATE_* macros are not allowed.
#define BN_EWRAM_WAIT_STATE_2
#include <bn_ewram_wait_state.h>
EWRAM access time is 2+1 clock cycles for sequential accesses.
#define BN_EWRAM_WAIT_STATE_1
#include <bn_ewram_wait_state.h>
EWRAM access time is 1+1 clock cycles for sequential accesses.
This wait states setting is not supported by the GBA Micro. Enabling it will not crash the GBA Micro though, it will just fall back to BN_
Some GBA SPs will crash after a few frames with this setting.