Add global.h, w/ EGT
This commit is contained in:
parent
8135a52d8c
commit
e8880935ac
24
src/global.h
Normal file
24
src/global.h
Normal file
@ -0,0 +1,24 @@
|
||||
/**
|
||||
********************************************************************************
|
||||
* @file global.h
|
||||
* @brief Defines global constants and types used in the assembler and emulator.
|
||||
********************************************************************************
|
||||
*/
|
||||
|
||||
#ifndef GLOBAL_H
|
||||
#define GLOBAL_H
|
||||
#include <stdint.h>
|
||||
|
||||
// Number of General Purpose Registers.
|
||||
#define REGISTER_COUNT 31
|
||||
// Size of the memory in bytes.
|
||||
#define MEMORY_SIZE 2097152
|
||||
// Length of the memory address in bits.
|
||||
#define MEMORY_ADDRESS_LENGTH 21
|
||||
// Length of the instruction in bits.
|
||||
#define INSTRUCTION_SIZE 32
|
||||
|
||||
// Define the word type to be a 64-bit unsigned integer.
|
||||
typedef uint64_t word;
|
||||
|
||||
#endif
|
||||
Loading…
Reference in New Issue
Block a user