Richard | 1 Jul 2010 07:12
Favicon
Gravatar

The effect of cache on performance

I stumbled across this today and found it an interesting read.
<http://queue.acm.org/detail.cfm?id=1814327>

It relates to our "virtual function calls are bad!"[*] discussion
earlier.

[*] they're not really bad, its cache misses that are bad.
--

-- 
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

      Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com

Gregory Junker | 1 Jul 2010 07:30

Re: The effect of cache on performance

I thought this was a given?

> [*] they're not really bad, its cache misses that are bad.

_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com

Richard Fabian | 1 Jul 2010 10:12
Picon
Gravatar

Re: The effect of cache on performance

Any development approach where you don't consider the effect of the cache is going to have inferior performance to one that either implicitly, or explicitly, takes advantage of the cache.


I do feel like we've been taught a lot of really good coding techniques that have ignored this issue. It doesn't mean that the code oriented techniques aren't good, for fast memory hardware our coding style and experience is invaluable.

On 1 July 2010 06:12, Richard <legalize <at> xmission.com> wrote:
I stumbled across this today and found it an interesting read.
<http://queue.acm.org/detail.cfm?id=1814327>

It relates to our "virtual function calls are bad!"[*] discussion
earlier.

[*] they're not really bad, its cache misses that are bad.
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

     Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com



--
fabs();
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com
Jon Watte | 5 Jul 2010 20:48
Picon
Gravatar

Re: The effect of cache on performance

Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.
 
Do you really think there's such a thing as "right," unless you're talking directly observable physical phenomena?
 
Sincerely,
 
jw


--
Americans might object: there is no way we would sacrifice our living standards for the benefit of people in the rest of the world. Nevertheless, whether we get there willingly or not, we shall soon have lower consumption rates, because our present rates are unsustainable.



On Thu, Jul 1, 2010 at 1:12 AM, Richard Fabian <raspo1 <at> gmail.com> wrote:
Any development approach where you don't consider the effect of the cache is going to have inferior performance to one that either implicitly, or explicitly, takes advantage of the cache.

I do feel like we've been taught a lot of really good coding techniques that have ignored this issue. It doesn't mean that the code oriented techniques aren't good, for fast memory hardware our coding style and experience is invaluable.


On 1 July 2010 06:12, Richard <legalize <at> xmission.com> wrote:
I stumbled across this today and found it an interesting read.
<http://queue.acm.org/detail.cfm?id=1814327>

It relates to our "virtual function calls are bad!"[*] discussion
earlier.

[*] they're not really bad, its cache misses that are bad.
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

     Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com



--
fabs();
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.

_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com


_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com
Jon Watte | 5 Jul 2010 20:49
Picon
Gravatar

Re: The effect of cache on performance

Do you really think there's such a thing as "right," unless you're talking directly observable physical phenomena?
 
Aaand that was supposed to be reply to Richard only. Please let's not have a metaphysical discussion on this list, OK? :-)
 
Sincerely,
 
jw

--
Americans might object: there is no way we would sacrifice our living standards for the benefit of people in the rest of the world. Nevertheless, whether we get there willingly or not, we shall soon have lower consumption rates, because our present rates are unsustainable.



On Mon, Jul 5, 2010 at 11:48 AM, Jon Watte <jwatte <at> gmail.com> wrote:
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.
 
Do you really think there's such a thing as "right," unless you're talking directly observable physical phenomena?
 
Sincerely,
 
jw


--
Americans might object: there is no way we would sacrifice our living standards for the benefit of people in the rest of the world. Nevertheless, whether we get there willingly or not, we shall soon have lower consumption rates, because our present rates are unsustainable.



On Thu, Jul 1, 2010 at 1:12 AM, Richard Fabian <raspo1 <at> gmail.com> wrote:
Any development approach where you don't consider the effect of the cache is going to have inferior performance to one that either implicitly, or explicitly, takes advantage of the cache.

I do feel like we've been taught a lot of really good coding techniques that have ignored this issue. It doesn't mean that the code oriented techniques aren't good, for fast memory hardware our coding style and experience is invaluable.


On 1 July 2010 06:12, Richard <legalize <at> xmission.com> wrote:
I stumbled across this today and found it an interesting read.
<http://queue.acm.org/detail.cfm?id=1814327>

It relates to our "virtual function calls are bad!"[*] discussion
earlier.

[*] they're not really bad, its cache misses that are bad.
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

     Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com



--
fabs();
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.

_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com



_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com
Tommy Brett | 5 Jul 2010 21:14
Picon

Re: The effect of cache on performance

If a cache miss happens in a program and no profiler is there to see it, does it really happen?

On Mon, Jul 5, 2010 at 2:49 PM, Jon Watte <jwatte <at> gmail.com> wrote:
Do you really think there's such a thing as "right," unless you're talking directly observable physical phenomena?
 
Aaand that was supposed to be reply to Richard only. Please let's not have a metaphysical discussion on this list, OK? :-)
 
Sincerely,
 
jw

--
Americans might object: there is no way we would sacrifice our living standards for the benefit of people in the rest of the world. Nevertheless, whether we get there willingly or not, we shall soon have lower consumption rates, because our present rates are unsustainable.



On Mon, Jul 5, 2010 at 11:48 AM, Jon Watte <jwatte <at> gmail.com> wrote:
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.
 
Do you really think there's such a thing as "right," unless you're talking directly observable physical phenomena?
 
Sincerely,
 
jw


--
Americans might object: there is no way we would sacrifice our living standards for the benefit of people in the rest of the world. Nevertheless, whether we get there willingly or not, we shall soon have lower consumption rates, because our present rates are unsustainable.



On Thu, Jul 1, 2010 at 1:12 AM, Richard Fabian <raspo1 <at> gmail.com> wrote:
Any development approach where you don't consider the effect of the cache is going to have inferior performance to one that either implicitly, or explicitly, takes advantage of the cache.

I do feel like we've been taught a lot of really good coding techniques that have ignored this issue. It doesn't mean that the code oriented techniques aren't good, for fast memory hardware our coding style and experience is invaluable.


On 1 July 2010 06:12, Richard <legalize <at> xmission.com> wrote:
I stumbled across this today and found it an interesting read.
<http://queue.acm.org/detail.cfm?id=1814327>

It relates to our "virtual function calls are bad!"[*] discussion
earlier.

[*] they're not really bad, its cache misses that are bad.
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

     Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com



--
fabs();
Just because the world is full of people that think just like you, doesn't mean the other ones can't be right.

_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com




_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com


_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com
Fabian Giesen | 6 Jul 2010 03:36
Picon

Re: The effect of cache on performance

On 05.07.2010 12:14, Tommy Brett wrote:
> If a cache miss happens in a program and no profiler is there to see it,
> does it really happen?

Unfortunately, the answer is YES.

One of the other cores told me. They're always snooping the bus because 
they like to gloat when someone misses the cache... sneaky bastards.

-Fabian
_______________________________________________
Sweng-Gamedev mailing list
Sweng-Gamedev <at> lists.midnightryder.com
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com


Gmane