expression templates with large values for template-depth leadto memory exhaustion

Ingo Krabbe ikrabbe@earthling.net
Thu Jun 28 00:49:00 GMT 2001


On Wed, 27 Jun 2001, Markus Werle wrote:

> Hi,
>
> is there any possibility to ask gcc to economize its
> meory consumption.
> I have ET-Code which drives gcc to request more than
> 900 MB of memory (not available here).

This can sometimes be solved by using another version of gcc. By the way I
think they work hard on reducing memory consumption. On the other hand I
find code with high template depth a bit suspect.
>
> I guess I have to reorganize my code not to evaluate erverything at
> compile time (e.g. stay behind the theoretical maximum in runtime
> performance)
>
If you can get near the theoretical maximum of runtime perfomance you are
fast enough in most cases. If you have problems of O(10) in runtime
difference you should really think about what you are doing there.

CU INGO




More information about the Gcc-help mailing list