|Home > Iris APIs > Memory API > Errors|
Reading and writing memory can fail for various reasons, including data aborts, translation errors, unsupported
byteWidth values, or reading past the end of the memory space.
Such errors do not cause the
memory_write() function to return an error, but instead are reported in the
error member of the
MemoryWriteResult return value.
Reads and writes specify a start address, an access width for each element (
byteWidth), and a number of elements (
count). The start address must be within the range supported by the memory space, in other words between
maxAddr of the memory space, or
E_address_out_of_range is returned. However, the end address can be beyond the end of the memory space. In other words,
is not required to be within
maxAddr. Reads and writes must return an error in the
error member of the result for all elements that exceed the memory space address range.
Target instances that do not expose any memory must return
E_function_not_supported_by_instance for the