From 75921593c0f8f33133034bc56dc94d956d2afd67 Mon Sep 17 00:00:00 2001 From: Matthew Cline Date: Tue, 10 Nov 2009 02:08:57 -0800 Subject: CrawlHashTable: reduce RAM overhead The RAM overhead for an unused CrawlHash table has been reduced from 32 to 4 (on 32 bit systems), with an increased overhead of 4 bytes for ones which are used. This leads to a 35% RAM reduction for item_def instances with an unused props field. --- crawl-ref/source/describe.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'crawl-ref/source/describe.cc') diff --git a/crawl-ref/source/describe.cc b/crawl-ref/source/describe.cc index f1e22443d4..f4a57bef67 100644 --- a/crawl-ref/source/describe.cc +++ b/crawl-ref/source/describe.cc @@ -2100,7 +2100,7 @@ void set_feature_desc_long(const std::string &raw_name, CrawlHashTable &props = env.properties; if (!props.exists(LONG_DESC_KEY)) - props[LONG_DESC_KEY].new_table(SV_STR); + props[LONG_DESC_KEY].new_table(); CrawlHashTable &desc_table = props[LONG_DESC_KEY].get_table(); -- cgit v1.2.3-54-g00ecf