[PATCH RESEND] clean up bb_pwd.c
Tito
farmatito at tiscali.it
Wed Dec 3 13:31:47 UTC 2008
On Wednesday 03 December 2008 11:32:10 you wrote:
> On Wednesday 03 December 2008 09:02, Tito wrote:
> > On Wednesday 03 December 2008 08:50:11 Tito wrote:
> > > On Tuesday 02 December 2008 23:57:34 you wrote:
> > > > On Monday 24 November 2008 14:48, Tito wrote:
> > Hi Denys,
> > just out of curiosity, I noticed you changed
> >
> > /* Parse any options */
> > getopt32(argv, "p:st:", &str_p, &str_t);
> >
> > if (option_mask32 & 0x2) /* -s */
> >
> > to:
> >
> > /* Parse any options */
> > opt = getopt32(argv, "p:st:", &str_p, &str_t);
> >
> > if (opt & 0x2) /* -s */
> >
> > in logger.c. I'm just wondering why?
> > Is there a reason to revert it?
> > I'm asking because i've changed
> > strings.c to use option_mask32 some time ago.
>
> The result of getopt32() is in a CPU register.
> Since we use it basically right away, it's far easier
> to access it from there than from a global variable.
>
> If accesses are far away, getopt32() result
> gets spilled on stack, and accesses are no longer
> so cheap (strings.c case), using global option_mask32
> may be cheaper.
> --
> vda
>
Hi Denys,
your explanation is to difficult to me as i'm self-taught
and sometimes i miss some fundamentals.
For the sake of simplicity can i assume that when
bloat-o-meter says there is a saving in size it is ok
to change opt to option_mask32 and otherwise
not.
Ciao,
Tito
More information about the busybox
mailing list