diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/registre.h | 5 | ||||
-rw-r--r-- | include/simulator.h | 16 |
2 files changed, 15 insertions, 6 deletions
diff --git a/include/registre.h b/include/registre.h index f5d8b5b..19b817b 100644 --- a/include/registre.h +++ b/include/registre.h @@ -7,13 +7,13 @@ Uint32 LireRegistreRG(void); Uint32 LireRegistreRD(void); Uint32 LireRegistrePC(void); Uint32 LireRegistreFLAG(void); -Uint32 LireRegistrePP(void); +Uint32 LireRegistreSP(void); void EcrireRegistreRG(Uint32 val); void EcrireRegistreRD(Uint32 val); void EcrireRegistrePC(Uint32 val); void EcrireRegistreFLAG(Uint32 val); -void EcrireRegistrePP(Uint32 val); +void EcrireRegistreSP(Uint32 val); Uint32 LireRegistre(Uint32 champ_registre); @@ -33,4 +33,5 @@ void ResetOverflow(void); void ResetZero(void); void ResetSign(void); void ResetParity(void); +void ResetRegistres(void); #endif
\ No newline at end of file diff --git a/include/simulator.h b/include/simulator.h index e2df994..852fb7d 100644 --- a/include/simulator.h +++ b/include/simulator.h @@ -8,14 +8,22 @@ #define REG_RD 33 /* Numero du registre Rd */ #define REG_PC 34 /* Numero du registre PC */ #define REG_FLAG 35 /* Numero du registre de flags */ -#define REG_PUSHPOP 36 /* Numero du registre de Push-Pop */ -#define ADD_PP (TAILLE_MEMOIRE-1) /* Emplacement de la pile */ +#define REG_STACKPTR 36 /* Numero du registre de Push-Pop */ +#define ADD_SP (TAILLE_MEMOIRE-1) /* Emplacement de la pile */ #include "types.h" Uint32 memoire_principale[TAILLE_MEMOIRE]; Uint32 registre[NB_REGISTRES_PHYSIQUES]; /* Registres classiques */ -Uint32 Err_Mem; /* en cas d'erreur l/e en mémoire principale */ -Uint32 Err_Reg; /* en cas d'erreur l/e dans un registre */ +Uint32 LireInstruction(void); +void IncrementeCompteurOrdinal(void); +Uint32 Adresse(Uint32 u, Uint32 instruction); +void Initialisation(void); +void DecodeExec(Uint32 instruction, Uint32 entrypoint); +void Traitement(Uint32 entrypoint); +void AfficheReg(void); +void Debogueur(void); + + #endif |