[Gems-users] Write from ruby to simics


Date: Wed, 17 Dec 2008 20:38:12 +0100
From: Lois Orosa Nogueira <lois.orosa@xxxxxx>
Subject: [Gems-users] Write from ruby to simics
Hi list,

I'm trying to save in ruby part of the Versions of data in Transactions . I read from simics some blocks in this way:


 for (int i = 0; i < g_DATA_BLOCK_BYTES; i += 4){
entry[i/4] = SIMICS_read_physical_memory( proc,physicalAddress.getAddress() + i, 4);
 }



and then, I write from ruby to simics in this way (to the same address):

for (int i = 0; i < g_DATA_BLOCK_BYTES; i+=4){
SIMICS_write_physical_memory(proc, physicalAddress.getAddress() + i, entry[i/4], 4);
 }


Which is the error? I receive a Segmentation fault from simics when I do the first Write

Thanks a lot
Lois
[← Prev in Thread] Current Thread [Next in Thread→]