[ros-dev] RE: [ion] 19742: - Implement RtlPrefectMemoryNonTemporal.Patch by Patrick Baggett <baggett.patrick@gmail.com> and myself.

Alex Ionescu ionucu at videotron.ca
Tue Nov 29 17:49:41 CET 2005


Ge van Geldorp wrote:

>>From: ion at svn.reactos.com
>>
>>+
>>+ at RtlPrefetchMemoryNonTemporal@8:
>>+	ret         /* Overwritten by ntoskrnl/ke/i386/kernel.c if SSE is
>>    
>>
>supported (see Ki386SetProcessorFeatures() ) */
>
>Is this routine so time-critical that we want to resort to self-modifying
>code?
>  
>
Yup, and there are many more cases where NT does this:
- Syscall vs INT2e
- Cmpxch8 vs cmpxchg x2 + spinlock
- XMMI Page Zeroing vs regular Page Zeroing
- Prefetching

And I'm probably missing more. There are critical APIs that would be 
very slow should the check be done each time they are called.

Best regards,
Alex Ionescu

>GvG
>
>  
>



More information about the Ros-dev mailing list