Il 05/05/2013 11:26, Holger Hans Peter Freyther ha scritto: > Disabling the prefetching is a win on arm9 (arm926ejs, e.g. TI > Davinci DM644x). This was benchmarked using the simple Bench.st > benchmark.
Can you do this from md-config.h instead? Paolo > 2013-04-28 Holger Hans Peter Freyther <[email protected]> > > * libgst/gstpriv.h: Allow to disable the DO_PREFETCH. > --- > configure.ac | 9 +++++++++ > libgst/ChangeLog | 4 ++++ > libgst/gstpriv.h | 3 ++- > 3 files changed, 15 insertions(+), 1 deletion(-) > > diff --git a/configure.ac b/configure.ac > index fbf1ce9..e0cb5e6 100644 > --- a/configure.ac > +++ b/configure.ac > @@ -655,6 +655,15 @@ if test "$enable_preemption" != no; then > [Define to enable preemptive multitasking of Smalltalk processes]) > fi > > +AC_ARG_ENABLE(prefetch, > +[ --disable-prefetch disable memory prefetch macros], , > +enable_prefetch=yes) > + > +if test "$enable_prefetch" != no; then > + AC_DEFINE(ENABLE_PREFETCH, 1, > + [Define to enable usage of __builtin_prefetch]) > +fi > + > GST_ARG_ENABLE_MODULES([Blox,TCP]) > > dnl > diff --git a/libgst/ChangeLog b/libgst/ChangeLog > index 4abaa9a..f952307 100644 > --- a/libgst/ChangeLog > +++ b/libgst/ChangeLog > @@ -1,3 +1,7 @@ > +2013-04-28 Holger Hans Peter Freyther <[email protected]> > + > + * libgst/gstpriv.h: Allow to disable the DO_PREFETCH. > + > 2013-04-25 Holger Hans Peter Freyther <[email protected]> > > * libgst/md-config.h: Add cases for the ARM architecture. > diff --git a/libgst/gstpriv.h b/libgst/gstpriv.h > index 7127438..b3d100f 100644 > --- a/libgst/gstpriv.h > +++ b/libgst/gstpriv.h > @@ -175,7 +175,8 @@ > #define PREF_T2 8 > #define PREF_NTA 12 > > -#if GNUC_PREREQ (3, 1) > +/* the prefetch is a loss on on a ARM9 (TI Davinci), hack it out */ > +#if defined(ENABLE_PREFETCH) && GNUC_PREREQ (3, 1) > #define DO_PREFETCH(x, distance, k) \ > __builtin_prefetch (((char *) (x)) \ > + (((k) & PREF_BACKWARDS ? -(distance) : (distance)) \ > _______________________________________________ help-smalltalk mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-smalltalk
