started the RAM
This commit is contained in:
@@ -0,0 +1,30 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <spider/runtime/common.hpp>
|
||||||
|
|
||||||
|
namespace spider {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A memory container.
|
||||||
|
* As a reminder, the amount of RAM
|
||||||
|
* is designed by the host.
|
||||||
|
*/
|
||||||
|
class RAM {
|
||||||
|
private:
|
||||||
|
u8* _mem;
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
RAM(u64 length);
|
||||||
|
|
||||||
|
~RAM();
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
u8& operator[](u64 i);
|
||||||
|
|
||||||
|
u8 operator[](u64 i) const;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user