A
Ajai Jose
Hi ,
I work on an ARM processor based embedded system. Code is mainly in
C language. The project has a huge source base. We are supposed to
optimise it. Most datastructures are declared as static and which
directly go into the Zero Initialised region. We need to cut the size
of this ZI region by at least 30%.
The one way i see of doing this is by removing these static arrays
and passing a pointer to the data structure whenever required. but
since these global arrays are used through out the code. A re-write
seems inevitable!
two questions I had.
1. Am I right in doing this(passing pointer instead of making the data
structure static) ?
2. Is there any alternative to this ?
Thanks in Advance,
Ajai.
I work on an ARM processor based embedded system. Code is mainly in
C language. The project has a huge source base. We are supposed to
optimise it. Most datastructures are declared as static and which
directly go into the Zero Initialised region. We need to cut the size
of this ZI region by at least 30%.
The one way i see of doing this is by removing these static arrays
and passing a pointer to the data structure whenever required. but
since these global arrays are used through out the code. A re-write
seems inevitable!
two questions I had.
1. Am I right in doing this(passing pointer instead of making the data
structure static) ?
2. Is there any alternative to this ?
Thanks in Advance,
Ajai.