diff options
Diffstat (limited to 'lib/registre.c')
-rw-r--r-- | lib/registre.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/lib/registre.c b/lib/registre.c index e77e9c1..4edb885 100644 --- a/lib/registre.c +++ b/lib/registre.c @@ -35,9 +35,9 @@ Uint32 LireRegistreFLAG(void) return (registre[REG_FLAG]); } -Uint32 LireRegistrePP(void) +Uint32 LireRegistreSP(void) { - return (registre[REG_PUSHPOP]); + return (registre[REG_STACKPTR]); } void EcrireRegistreRG(Uint32 val) @@ -60,9 +60,9 @@ void EcrireRegistreFLAG(Uint32 val) registre[REG_FLAG] = val; } -void EcrireRegistrePP(Uint32 val) +void EcrireRegistreSP(Uint32 val) { - registre[REG_PUSHPOP] = val; + registre[REG_STACKPTR] = val; } /* Lit le mot qui se trouve dans le registre 'numero_registre' */ @@ -171,3 +171,11 @@ void ResetParity(void) { registre[REG_FLAG] &= (VAL_MAX - 8); } + + +void ResetRegistres(void) +{ int i; + + for (i=0; i<NB_REGISTRES_PHYSIQUES;i++) + registre[i]=0; +}
\ No newline at end of file |