[ros-diffs] [dgorbachev] 39723: Remove a hack from KiTrap14. Put a hack in other place.

Alex Ionescu ionucu at videotron.ca
Mon Feb 23 19:10:56 CET 2009


This new hack directly slows down every context switch instead of every page
fault -- the latter is a less important perf hit.
Best regards,
Alex Ionescu


On Mon, Feb 23, 2009 at 1:18 PM, <dgorbachev at svn.reactos.org> wrote:

> Author: dgorbachev
> Date: Mon Feb 23 16:18:28 2009
> New Revision: 39723
>
> URL: http://svn.reactos.org/svn/reactos?rev=39723&view=rev
> Log:
> Remove a hack from KiTrap14. Put a hack in other place.
>
> Modified:
>    trunk/reactos/ntoskrnl/ke/i386/ctxswitch.S
>    trunk/reactos/ntoskrnl/ke/i386/trap.s
>
> Modified: trunk/reactos/ntoskrnl/ke/i386/ctxswitch.S
> URL:
> http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ke/i386/ctxswitch.S?rev=39723&r1=39722&r2=39723&view=diff
>
> ==============================================================================
> --- trunk/reactos/ntoskrnl/ke/i386/ctxswitch.S [iso-8859-1] (original)
> +++ trunk/reactos/ntoskrnl/ke/i386/ctxswitch.S [iso-8859-1] Mon Feb 23
> 16:18:28 2009
> @@ -389,6 +389,9 @@
>
>     /* Checking NPX, disable interrupts now */
>     mov eax, [esi+KTHREAD_INITIAL_STACK]
> +
> +    /* HACK */
> +    mov ecx, [eax - 4]
>     cli
>
>     /* Get the NPX State */
>
> Modified: trunk/reactos/ntoskrnl/ke/i386/trap.s
> URL:
> http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ke/i386/trap.s?rev=39723&r1=39722&r2=39723&view=diff
>
> ==============================================================================
> --- trunk/reactos/ntoskrnl/ke/i386/trap.s [iso-8859-1] (original)
> +++ trunk/reactos/ntoskrnl/ke/i386/trap.s [iso-8859-1] Mon Feb 23 16:18:28
> 2009
> @@ -1924,10 +1924,6 @@
>  NoFixUp:
>     mov edi, cr2
>
> -    /* ROS HACK: Sometimes we get called with INTS DISABLED! WTF? */
> -    test dword ptr [ebp+KTRAP_FRAME_EFLAGS], EFLAGS_INTERRUPT_MASK
> -    je HandlePf
> -
>     /* Enable interrupts and check if we got here with interrupts disabled
> */
>     sti
>     test dword ptr [ebp+KTRAP_FRAME_EFLAGS], EFLAGS_INTERRUPT_MASK
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-diffs/attachments/20090223/54ea53ed/attachment.html 


More information about the Ros-diffs mailing list