about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorHuon Wilson <dbau.pp+github@gmail.com>2014-01-17 23:23:09 +1100
committerHuon Wilson <dbau.pp+github@gmail.com>2014-01-19 12:56:26 +1100
commit68517a2cca613d2018819d0eb38f6c0a864d1836 (patch)
treeaff340c4fdb1d38f8997479e9b5cea5990f6ea80 /src/rustllvm/RustWrapper.cpp
parentd0f6ef080bb69ce4370c04c92cc92b9a860e5725 (diff)
downloadrust-68517a2cca613d2018819d0eb38f6c0a864d1836.tar.gz
rust-68517a2cca613d2018819d0eb38f6c0a864d1836.zip
syntax: convert ast_map to use a SmallIntMap.
NodeIds are sequential integers starting at zero, so we can achieve some
memory savings by just storing the items all in a line in a vector.

The occupancy for typical crates seems to be 75-80%, so we're already
more efficient than a HashMap (maximum occupancy 75%), not even counting
the extra book-keeping that HashMap does.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions