mesa: Reduce memory usage for reg alloc with many graph nodes (part 2).
authorEric Anholt <eric@anholt.net>
Wed, 20 Feb 2013 01:01:41 +0000 (17:01 -0800)
committerEric Anholt <eric@anholt.net>
Mon, 11 Mar 2013 19:11:54 +0000 (12:11 -0700)
commit11b8df0c0141c5759025985ba99e782a2dfd720c
tree7424e0529ff34b6ad6d20388e4fdafc8cb4db708
parent6aa3afbfd6b737350351e9ea22ba9de1accda52d
mesa: Reduce memory usage for reg alloc with many graph nodes (part 2).

After the previous fix that almost removes an allocation of 4*n^2
bytes, we can use a bitset to reduce another allocation from n^2 bytes
to n^2/8 bytes.

Between the previous commit and this one, the peak heap size for an
oglconform ARB_fragment_program max instructions test on i965 goes from
4GB to 255MB.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=55825
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/program/register_allocate.c