summaryrefslogtreecommitdiff
path: root/src/shared/cplusplus/Scope.cpp
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2010-09-02 16:44:58 +0200
committerRoberto Raggi <roberto.raggi@nokia.com>2010-09-02 16:45:30 +0200
commitec64e1d7bd230a172abfc37724d16af92d5fd37d (patch)
tree08e6918041bfd9811f4fa7a36523f1bcbffcb021 /src/shared/cplusplus/Scope.cpp
parent15b0082b3a34e3a7068f5ee2dbbc9ab1046c7ba2 (diff)
downloadqt-creator-ec64e1d7bd230a172abfc37724d16af92d5fd37d.tar.gz
Tune the symbol and the literal tables.
Diffstat (limited to 'src/shared/cplusplus/Scope.cpp')
-rw-r--r--src/shared/cplusplus/Scope.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/cplusplus/Scope.cpp b/src/shared/cplusplus/Scope.cpp
index bc5eeb90bb..b500f178cb 100644
--- a/src/shared/cplusplus/Scope.cpp
+++ b/src/shared/cplusplus/Scope.cpp
@@ -105,7 +105,7 @@ private:
void rehash();
private:
- enum { DefaultInitialSize = 11 };
+ enum { DefaultInitialSize = 4 };
Scope *_owner;
Symbol **_symbols;
@@ -147,7 +147,7 @@ void SymbolTable::enterSymbol(Symbol *symbol)
symbol->_scope = _owner;
_symbols[_symbolCount] = symbol;
- if (_symbolCount >= _hashSize * 0.6)
+ if (_symbolCount * 5 >= _hashSize * 3)
rehash();
else {
const unsigned h = hashValue(symbol);