Mail Archives: djgpp-workers/2001/08/20/10:24:54
> > > Other suggestion:
> > >
> > > move 'char desc_map[how_deep]' inside
> > > if (workaround_descriptor_leaks)
> > > block.
> >
> > Can't do this since there are two workaround_descriptor_leaks blocks,
> > one to set the map, then we exit it (to call direct_exec), then a
> > second one to use the map.
>
> We can is we duplicate call to direct_exec_tail_1() inside that block.
> The advatage is that we can set different initial values for
> default_depth on Win9X (where scan is rather fast) and for
> WinNT,2k,... where it is expected to be much slower.
I would rather just increase the map size for all - after all we are
talking about 50 or 100 bytes on the stack. Just because the map
is allocated doesn't mean we have to use it for NT.
> So the initial value should perhaps be smaller for WinNT. It can safely
> be larger for Win9X.
Maybe. If the hybrid search works, it won't hurt NT too much.
One tuning factor is bad. Two are worse :-)
> > I think you are convincing me to make the limit larger. One
> > possible optimization is to use the lar scanning for NT also.
> > If a selector was never touched it passes the lar test which
> > is fast.
>
> It works only once per selector. So I think there is
> little use of it.
But let's say I'm scanning 100 selectors. If only the first 12 of them
have been touched, I save 88 DPMI calls on the map creation and 88 DPMI
calls on the release. This might be the magic that makes it almost as
fast on NT an allows us to to larger scans.
- Raw text -