[llvm-commits] [Patch][Review Requested][Compilation Time] Use SmallDenseMap instead of DenseMap in LegalizeTypes

Duncan Sands baldrick at free.fr
Thu Jan 24 23:07:22 PST 2013


Hi Preston,

On 25/01/13 00:09, Gurd, Preston wrote:
> This is the first of 10 proposed patches to reduce compilation time.
>
> This patch aims to reduce compile time in LegalizeTypes by using SmallDenseMap,
> with an initial number of elements,  instead of DenseMap, which has zero initial
> elements, in order to avoid the copying of elements when the size changes and to
> avoid allocating space every time LegalizeTypes is run. This patch will not
> affect the memory footprint, because DenseMap will increase the element size to
> 64 when the first element is added.
>
> Patch by Wan Xiaofei.
>
> PLEASE REVIEW. Thanks!

LGTM.

Ciao, Duncan.

>
> --
>
> Preston Gurd <preston.gurd at intel.com>
>
>    Intel Waterloo
>
>    SSG/DPD/ECDL/DMP
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>




More information about the llvm-commits mailing list