svn commit: trunk/uClibc/libc/unistd

Bernhard Fischer rep.dot.nop at gmail.com
Fri Jun 6 12:50:15 UTC 2008


On Thu, Jun 05, 2008 at 08:24:45PM -0700, vda at uclibc.org wrote:
>Author: vda
>Date: 2008-06-05 20:24:45 -0700 (Thu, 05 Jun 2008)
>New Revision: 22242
>
>Log:
>shrink getopt a bit by using smallints. Run tested (busybox testsuite)

I still think that this route is wrong.
VRP knows the exact range of values a variable is in. -fnarrow-type
should deal with this for us, really.

fnarrow-types
Common Report Var(narrow_types,0) Optimization
Narrow variables to use the smallest possible type


This would (, for non-public variables)
take e.g. VRP into account to gather the information about the smallest
type that can hold the required range and possibly convert the variable
to the smallest possible type (available on that machine).
No idea if above-new-type accesses would pose a problem for this (yes)
and if so, if those can be converted to new-type accesses (except maybe
inline asm) at most.

Put short, this should be fixed elsewhere, i.e. in the compiler with N
LOC and not in N^M LOC of the users.



More information about the uClibc mailing list