[LLVMbugs] [Bug 11718] New: ExeDepsFix seems to use exponential amount of memory on large functions
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Fri Jan 6 08:20:45 PST 2012
http://llvm.org/bugs/show_bug.cgi?id=11718
Bug #: 11718
Summary: ExeDepsFix seems to use exponential amount of memory
on large functions
Product: libraries
Version: 3.0
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: Common Code Generator Code
AssignedTo: unassignedbugs at nondot.org
ReportedBy: ddneff at hotmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
With large functions, the ExeDepsFix pass seems to use exponential amounts of
memory. A 100K instruction function with ~2k basic blocks took over 96GB of
memory (not sure exactly how much is required to complete, my machine only has
96GB). I think this may be related to using a SmallVector<MachineInstr*, 8>
for DomainValue::Instrs and then inserting duplicate instructions into this
vector. Swapping out this SmallVector for a SmallPtrSet seems to fix the
problem; I don't know if that is a great solution, but memory useage for this
use case drops from 96GB to practically nothing (assuming I didn't break the
algorithm somehow).
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list