Skip to content

Commit

Permalink
Using a theorical memeroy model, on a 16 bits bus, we can expect long…
Browse files Browse the repository at this point in the history
… write cycle take twice the time of a word/byte acess
  • Loading branch information
Francois CARON committed Dec 1, 2024
1 parent ad67637 commit 8bc434f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions yabause/src/sys/memory/src/memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -918,6 +918,7 @@ void FASTCALL SH2MappedMemoryWriteByte(SH2_struct *context, u32 addr, u8 val)
{
int id = addr >> 29;
if (context == NULL) id =1;
context->cycles += 1;
SH2WriteNotify(context, addr, 1);
switch (id)
{
Expand Down Expand Up @@ -987,6 +988,7 @@ void FASTCALL SH2MappedMemoryWriteWord(SH2_struct *context, u32 addr, u16 val)
{
int id = addr >> 29;
if (context == NULL) id =1;
context->cycles += 1;
SH2WriteNotify(context, addr, 2);
switch (id)
{
Expand Down Expand Up @@ -1058,6 +1060,7 @@ void FASTCALL SH2MappedMemoryWriteLong(SH2_struct *context, u32 addr, u32 val)
{
int id = addr >> 29;
if (context == NULL) id =1;
context->cycles += 2;
SH2WriteNotify(context, addr, 4);
switch (id)
{
Expand Down

0 comments on commit 8bc434f

Please sign in to comment.