Liste des Groupes | Revenir à c arch |
MitchAlsup1 <mitchalsup@aol.com> schrieb:There I mean that the programmer wrote the code::Thomas Koenig wrote:
>Stefan Monnier <monnier@iro.umontreal.ca> schrieb:>Since each chased pointer starts back at LSQ, the cost is no different>
than an explicit Prefetch instruction, except without (a),(b) and (c)
having been applied first.
I thought the important difference is that the decision to prefetch or
not can be done dynamically based on past history.Programmers and compilers are notoriously bad at predicting>
branches (except for error branches),
Which are always predicted to have no error.
On the second or third time, certainly. Hmmm... given hot/coldFirst we are talking about predicting branches at compile time and
splitting which is fairly standard by now, do branch predictors
take this into account?
but ought to be quite good>
at predicting prefetches.
What makes you think programmers understand prefetches any better than
exceptions ??
Pointers are used in many common data structures; linked list,3Km ??
trees, ... A programmer who does not know about dereferencing
pointers should be kept away from computer keyboards, preferably
at a distance of at least 3 m.
If a pointer is loaded, chances are>
very high that are it will be dereferenced.
What if the value loaded is NULL.
Then it should be trivially predicted that it should not be prefetched.
Les messages affichés proviennent d'usenet.