Re: [Gems-users] Miss penalty query


Date: Tue, 7 Jul 2009 14:51:16 -0400
From: Lyon Shinseky <lyon.shinseky@xxxxxxxxx>
Subject: Re: [Gems-users] Miss penalty query
Dan,

The bytes are contiguous on a page. The cache line is of 64 bytes. The idea is to measure the raw swap time of x bytes with the bytes not being in the caches. The swap operation is like reading bytes from source and writing to temp placeholder from where it goes to the destination, while the destination bytes go to the source. The initialization phase includes 3 mallocs (this part is not timed by ruby) and assigning values to the source,temp and destination bytes. This is then followed by a ruby magic call and the swap operation starts off till it ends. I am assuming that all this would've removed other effects. The page size is 8192 bytes on the simulated OS and i am assuming that after a malloc and initialization phase , i won't be seeing any unwanted faults during the swap phase which is being timed by ruby.

Thanks

Lyon

For the purposes of this discussion, how do you define a 'swap' operation? Are the operands on the same cache line, or different cache lines? Is the working area warm as far as the page tables are concerned?

Regards,
Dan

On Tue, Jul 7, 2009 at 1:31 PM, Lyon Shinseky <lyon.shinseky@xxxxxxxxx> wrote:
Hi,

I'm measuring the miss penalty of swapping 4 bytes, 16 bytes, 64 bytes, 256 bytes, 1024 bytes and 8192 bytes on ruby. I have a code which simply swaps these bytes to measure the ruby cycles taken when this data is not in ruby cache. With 4 bytes, the cycles/(user misses) is 347 cycles which is close to my memory latency (300 cycles). With 16 bytes , this goes upto 392 cycles. With 256 bytes, this goes upto 677 cycles and with 8192 bytes ,  this is 1200 cycles. I'm unable to reason about the penalty increasing as I increase the  number of bytes to swap. My expectation is that it should remain around 350 cycles . . . any thoughts ?

Lyon

_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site:https://lists.cs.wisc.edu/archive/gems-users/" to your search.





--
http://www.cs.wisc.edu/~gibson [esc]:wq!



_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site:https://lists.cs.wisc.edu/archive/gems-users/" to your search.

[← Prev in Thread] Current Thread [Next in Thread→]