[PATCH] D41695: [Metadata] Extend 'count' field of DISubrange to take a metadata node

Sander de Smalen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 5 09:00:24 PST 2018


sdesmalen added a comment.

Hi all, thanks for pointing out the possible memory size issue, I didn't realise that a ConstantAsMetadata was so much bigger than an 'int' and I can see how this would have an impact on memory usage. In practice it probably depends on the number of unique DISubrange nodes with non-distinct count values in the program, where I would hope that many DISubrange nodes could be merged due to similar ranges.

I ran an experiment to get high water-mark as suggested by @rnk to measure the impact, but did not see a significant difference on a Debug LTO build of Clang, but maybe I haven't run the experiment properly... I tried to monitor the cc1 and ld processes during the build and then getting the memory footprint for these processes. I'll try to run these experiments again to see if the results are sensible. Please let me know if you know of a better way to do these measurements.


https://reviews.llvm.org/D41695





More information about the llvm-commits mailing list