qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v4 00/14] tb hash improvements
@ 2016-04-30  3:33 Emilio G. Cota
  2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 01/14] compiler.h: add QEMU_ALIGNED() to enforce struct alignment Emilio G. Cota
                   ` (13 more replies)
  0 siblings, 14 replies; 31+ messages in thread
From: Emilio G. Cota @ 2016-04-30  3:33 UTC (permalink / raw)
  To: QEMU Developers, MTTCG Devel
  Cc: Alex Bennée, Paolo Bonzini, Peter Crosthwaite,
	Richard Henderson, Sergey Fedorov

Changes from v3:

- added reviewed-by tags from v3. I dropped the review tags from the
  'qht' and 'info jit' patches because they have changed quite a bit
  from v3.
- qdist: new module to print intuitive histograms, see 'info jit' below.
- qht:
  + bug fix: remove unnecessary requirement of hashes being !0; the
    only requirement is that pointers must be !NULL.
    * qht-test: hash the integers we insert with their own integer values
      instead of using tb_hash_func5. This gives us better control
      of the hash values we're testing, and anyway the values we
      test are all unique, so this doesn't matter.
  + bug fix: was not setting map->n_items to 0 in qht_reset().
  + Do not leave NULL holes after removals. Instead, swap this hole
    with the last valid item in the chain. Performance-wise this
    makes no difference when resize is on; however, without resize
    the gain is measurable.
    * A consequence of this is a slight change in MRU promotion: the
      last item in the head bucket is simply swapped with orig[pos],
      without bringing orig to head->next.
    * Added bucket corruption checks, enabled with #define QHT_DEBUG.
  + Do not set QHT_MODE_MRU_INSERT for the TB hash. With long chains it
    causes quite a performance decrease; with short chains, such as what
    we have with xxhash + auto-resize, it has no measurable performance
    impact.
  + 'info jit' stats:
    * Report the number of empty buckets
    * Do not count empty buckets when reporting avg bucket chain length;
      by doing this we get an idea of how many buckets the average lookup
      is going through.
    * Report the avg bucket chain length + a histogram for its distribution.
    * Report avg bucket chain occupancy (in %) + its distribution's histogram.
  + qht-test: add a few more test cases
  + header guard: s/define QHT_H/define QEMU_QHT_H/
  + consistently use uint32_t for keeping the result of tb_hash_func()
  + avoid false leak reports from valgrind after calling call_rcu(map)
    by placing the 'struct rcu_head' field at the top of struct qht_map.
- define QEMU_ALIGNED(X) instead of QEMU_ALIGNED(B)
- add copyright + license to include/processor.h
- add atomic_test_and_set to include/atomic.h, using __atomic_test_and_set
  when available.
- spinlock:
  + use newly-added atomic_test_and_set instead of atomic_xchg
  + remove TATAS for spin_try_lock

Thanks,

		Emilio

^ permalink raw reply	[flat|nested] 31+ messages in thread

end of thread, other threads:[~2016-05-06 22:15 UTC | newest]

Thread overview: 31+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-30  3:33 [Qemu-devel] [PATCH v4 00/14] tb hash improvements Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 01/14] compiler.h: add QEMU_ALIGNED() to enforce struct alignment Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 02/14] seqlock: remove optional mutex Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 03/14] seqlock: rename write_lock/unlock to write_begin/end Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 04/14] include/processor.h: define cpu_relax() Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 05/14] atomics: add atomic_test_and_set Emilio G. Cota
2016-05-04  5:10   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 06/14] qemu-thread: add simple test-and-set spinlock Emilio G. Cota
2016-05-04  5:10   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 07/14] exec: add tb_hash_func5, derived from xxhash Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 08/14] tb hash: hash phys_pc, pc, and flags with xxhash Emilio G. Cota
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 09/14] qdist: add module to represent frequency distributions of data Emilio G. Cota
2016-05-04  5:13   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 10/14] qdist: add test program Emilio G. Cota
2016-05-04  5:23   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 11/14] qht: QEMU's fast, resizable and scalable Hash Table Emilio G. Cota
2016-05-04  5:17   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 12/14] qht: add test program Emilio G. Cota
2016-05-04  5:22   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 13/14] tb hash: track translated blocks with qht Emilio G. Cota
2016-05-03  7:36   ` Alex Bennée
2016-05-03 17:26     ` Emilio G. Cota
2016-05-04  5:24       ` Richard Henderson
2016-05-04  9:31         ` Alex Bennée
2016-05-04 15:36         ` Emilio G. Cota
2016-05-04 17:22           ` Richard Henderson
2016-05-05 21:41             ` Emilio G. Cota
2016-05-06 22:14               ` Richard Henderson
2016-05-04  5:19   ` Richard Henderson
2016-04-30  3:33 ` [Qemu-devel] [PATCH v4 14/14] translate-all: add tb hash bucket info to 'info jit' dump Emilio G. Cota
2016-05-04  5:21   ` Richard Henderson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).