Inform compiler null vectors from a template class can be combined?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Everyone,

I have a template class. The class has a static const data member
that's a effectively a string of 0's (a null vector). The length of
the vector depends on a template parameter T. Different T's will
produce different null vectors (that only differ by length).

I want to inform the compiler that it can use the largest vector it
produces for all of them.

Is it possible to inform GCC to do that? If so, how? Or is this a
common pattern, and I should go read on a subject? (If so, what is the
term I should search on)?

(The extra gyrations is a simple optimization to reduce memory and
cache pressures).

Thanks in advance.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux