IUSR's Ughten of Silent Requiem

To whom it may resurrect
zh en ja

献丑

https://github.com/IUSR/jvm-serializers/

一直很倚重的一个序列化、反序列化性能测试报告。发现已经1年多没有更新了,这期间很多库、框架的版本都升级了,索性自己fork来试试。主要是升级版本以及改用maven管理依赖——这个不用白不用啊,不明白为什么要自己签入一堆jar文件,又占地方又不能diff什么的,图个什么啊。

继续阅读

Biased Locking && Bulk Rebiasing

也是老东西了…以前没有整理记录的习惯,哎。

  1. Early research utilized property that mostsynchronization in Java language is uncontended.
    • not only uncontended,but unshared
    • Most objects locked / unlocked by exactly one thread inthe object’s lifetime
  2. Avoid creation of mutex/condvar per Java object. ——不是完全免费的
  3. Compare-and-swap / compare and exchange
  4. “Inflate” to full heavyweight monitor if contention detected
  5. Previous:
    • First thread locking the object reserves the lock with an atomic operation
      • Subsequent locks / unlocks by that thread use no atomic operations
      • Recursion count in object header detects IllegalMonitorStateException
      • Using non-atomic stores
    • If another thread locks the object, relativelyexpensive unreservation required
      • Involves sending signal to reservation owner thread
      • Ensures reservation owner thread not performing concurrent non-atomic stores
  6. New
    • Store-Free Biased Locking
    • Bulk rebiasing and bulk revocation
    • Epoch-based bulk rebiasing
较旧的帖子