Hi Toninho,
IMO, these values should be preconfigured by Harbour (at
compile time or runtime) for best values decided by the
development team's (our) best judgement and at most offered
as overrides for defaults in the form of build-time tuning
or internal cmdline options (but I'd even avoid that, too).
It's IMO not the final users job to decide on such internal
details on the .prg level.
Moreover it's specific to one of our possible MM choices,
so it cannot be made a generic Harbour setting. We should
also remember that we may want to switch MMs in the future.
Questions are:
- Which value of the three should be 10000?
- Does it enhance performance for both XP and Vista, or just Vista?
- Did you get your results using a specific app or our
speed testing tools?
- If it was an app, was it a GUI, and with which GUI framework?
Brgds,
Viktor
On 2008.11.11., at 13:07, [EMAIL PROTECTED] wrote:
Hi Toninho,
You can make some experiments with DEFAULT_GRANULARITY, f.e.:
set C_USR=-DDEFAULT_GRANULARITY=0x100000
Hi Przemek thanks for your hint,
I see that the best value for windows vista is about 10000. Thinking
in this I made 3 functions to change this dlmalloc values without need
recompile harbour.
Where is the best place to save it?
---cut---
int mallopt( int parameter_number, int parameter_value );
#define M_TRIM_THRESHOLD (-1)
#define M_GRANULARITY (-2)
#define M_MMAP_THRESHOLD (-3)
HB_FUNC( MALLOCSETGRANULARITY )
{
mallopt( M_GRANULARITY, hb_parnl( 1 ) );
}
HB_FUNC( MALLOCSETTRIMTHRESHOLD )
{
mallopt( M_TRIM_THRESHOLD, hb_parnl( 1 ) );
}
HB_FUNC( MALLOCSETMMAPTHRESHOLD )
{
mallopt( M_MMAP_THRESHOLD, hb_parnl( 1 ) );
}
---cut---
Thanks and best regards,
Toninho.
__________________________________________________
Faça ligações para outros computadores com o novo Yahoo! Messenger
http://br.beta.messenger.yahoo.com/
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour