Try to sort out signedness problems in hg_wordfm.[ch], and do a bunch
of other tidying too.

* All these word-based abstractions (WordFM, WordSet, WordBag) now
  operate on unsigned words (UWord), whereas they previously operated
  on signed words (Word).  This became a problem, when using unboxed
  comparisons, with the introduction of HG_(initIterAtFM), which
  allows iteration over parts of mappings.  Iterating over a mapping in
  increasing order of signed Word keys is not what callers expect when
  iterating through maps whose keys representing addresses (Addr) since
  Addr is unsigned, and causes logical problems and assertion
  failures.

* Change various size-of-things types from signed to unsigned, and
  make them consistently word sized.  For example the return type
  of HG_(sizeFM) used to be an Int, which never made any sense
  (the size can't be negative, and, on a 64-bit platform, the 
  map could have more than 2G elements, in which case an Int can't
  represent the result).  So make the return value a UWord instead.
  This should generally help avoid obscure overflow problems on 64-bit 
  platforms.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7409 a5019735-40e9-0310-863c-91ae7b9d1cf9
5 files changed