This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
ARM sim speedup
- From: Nick Clifton <nickc at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: 13 Apr 2003 09:52:56 +0100
- Subject: ARM sim speedup
Hi Guys,
I am applying the patch below to make a small speed up in the ARM
simulator. The XScale_check_memacc() function was being called for
most memory accesses, even when the simulator was not simulating an
XScale. This resulted in an unnecessary function call, and hence a
slow-down when simulating non XScale binaries.
Cheers
Nick
2003-04-13 Nick Clifton <nickc at redhat dot com>
* armvirt.c (GetWord): Only call XScale_check_memacc if in XScale
mode.
(PutWord): Likewise.
Index: sim/arm/armvirt.c
===================================================================
RCS file: /cvs/src/src/sim/arm/armvirt.c,v
retrieving revision 1.8
diff -c -3 -p -w -r1.8 armvirt.c
*** sim/arm/armvirt.c 27 May 2002 14:12:00 -0000 1.8
--- sim/arm/armvirt.c 13 Apr 2003 08:50:48 -0000
*************** GetWord (ARMul_State * state, ARMword ad
*** 64,70 ****
ARMword **pagetable;
ARMword *pageptr;
! if (check)
XScale_check_memacc (state, &address, 0);
page = address >> PAGEBITS;
--- 64,70 ----
ARMword **pagetable;
ARMword *pageptr;
! if (check && state->is_XScale)
XScale_check_memacc (state, &address, 0);
page = address >> PAGEBITS;
*************** PutWord (ARMul_State * state, ARMword ad
*** 100,106 ****
ARMword **pagetable;
ARMword *pageptr;
! if (check)
XScale_check_memacc (state, &address, 1);
page = address >> PAGEBITS;
--- 100,106 ----
ARMword **pagetable;
ARMword *pageptr;
! if (check && state->is_XScale)
XScale_check_memacc (state, &address, 1);
page = address >> PAGEBITS;