Skip to content

Instantly share code, notes, and snippets.

@ryoqun
Created October 4, 2012 17:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ryoqun/3834961 to your computer and use it in GitHub Desktop.
Save ryoqun/3834961 to your computer and use it in GitHub Desktop.
Run options:
# Running tests:
_add_remove_loop_outer
_add_remove_loop_outer: 0
[{:meth=>:_add_remove_loop_outer, :time=>"20.496842s", :loop_count=>5, :key_count=>6142}, 620, -1311, 87, -423, -80, -227, 460, -244, -93, -18, -214, 1487, -649, 397, -144, -899, 408, -603, -95, -1375, 335, 34, 2009, 986, 427, -985, 1130, 1656, 956, 226, -470, -798, 147, 169, -455, 192, -183, -402, 310, 474]
_add_remove_loop_outer
[{:meth=>:_add_remove_loop_outer, :time=>"11.912187s", :loop_count=>25, :key_count=>307}, 179, 1258, -81, -224, 25, -152, -463, 409, 816, -1353, 457, -4, -88, -333, 75, 144, -386, 86, 808, -451, 92, -230, 49, 105, 161, 377, -198, -754, 941, -270, -36, -540, -910, 513, -294, 275, 401, -123, -156, -125]
_add_remove_loop_outer
[{:meth=>:_add_remove_loop_outer, :time=>"17.268905s", :loop_count=>150, :key_count=>190}, -180, 730, 120, 498, 1241, 59, -681, -118, -173, -171, -215, 641, 294, 156, 303, 865, -1294, -294, 620, 423, -111, 1143, 1919, -293, -344, -118, 1120, -603, 177, -1079, -608, -169, -798, -564, 455, -1122, -198, -281, -67, -1283]
_add_remove_loop_outer
[{:meth=>:_add_remove_loop_outer, :time=>"4.319256s", :loop_count=>750, :key_count=>9}, 204, -41, 100, 161, -31, -52, -9, -2, 57, 35, -169, 313, -9, 17, -43, 155, -73, -11, -149, 152, 32, -261, -189, -7, -49, 36, -275, -122, 26, -5, -225, -113, 174, 17, 140, -25, 215, 88, -80, 18]
_add_remove_loop_outer
_add_remove_loop_outer: 0
[{:meth=>:_add_remove_loop_outer, :time=>"38.976908s", :loop_count=>1000, :key_count=>1}, -332, -114, -1004, -142, 1658, 1716, 215, 426, -457, 311, 348, 1465, -938, -307, 456, 1060, 1093, -318, 1623, 17, -1581, 50, -174, -531, -673, -597, -1797, -824, 193, -1589, 902, 1139, -219, -346, -1222, -863, 1949, -449, 713, -857]
._add_remove_to_zero_loop_outer
_add_remove_to_zero_loop_outer: 0
_add_remove_to_zero_loop_outer: 4405
[{:meth=>:_add_remove_to_zero_loop_outer, :time=>"53.98337s", :loop_count=>5, :key_count=>6142}, -4, 1, -5, -2, -3, -1, -3, 8, 2, 6, -4, -7, 2, 4, -1, 7, -3, 3, -3, 4, 1, 1, -7, -4, 1, 1, 0, 0, 0, 5, -5, 2, -2, 4, 8, -12, -7, 3, 12, -2]
_add_remove_to_zero_loop_outer
[{:meth=>:_add_remove_to_zero_loop_outer, :time=>"13.688661s", :loop_count=>25, :key_count=>307}, -6, -5, -2, 6, 2, 1, -4, -1, 2, 3, 3, -5, -2, 0, 5, 0, 1, 0, -6, -1, 9, 3, 1, 0, -2, -1, -6, 0, -2, 4, -4, 10, 7, -1, -7, -1, 3, 4, -1, -7]
_add_remove_to_zero_loop_outer
_add_remove_to_zero_loop_outer: 0
_add_remove_to_zero_loop_outer: 4677
[{:meth=>:_add_remove_to_zero_loop_outer, :time=>"48.505628s", :loop_count=>150, :key_count=>190}, -9, -12, 3, -15, 7, 2, 0, 0, -4, -1, 6, -7, -3, -6, -6, -3, -2, 8, 5, 6, 6, -2, -12, 0, 10, 2, -5, 0, 4, 6, 8, 14, -1, 1, 2, -5, 8, 6, -13, 2]
_add_remove_to_zero_loop_outer
[{:meth=>:_add_remove_to_zero_loop_outer, :time=>"11.272999s", :loop_count=>750, :key_count=>9}, 26, -20, 8, -8, -6, 8, -9, -2, 16, 3, -14, 5, -1, -3, -5, -3, 0, -8, -9, -15, 4, -16, 5, -3, 4, 0, 10, 1, 14, -7, -8, 2, -1, 16, -4, 20, 13, -12, -2, 1]
_add_remove_to_zero_loop_outer
_add_remove_to_zero_loop_outer: 0
_add_remove_to_zero_loop_outer: 4744
_add_remove_to_zero_loop_outer: 10060
_add_remove_to_zero_loop_outer: 15308
_add_remove_to_zero_loop_outer: 21442
_add_remove_to_zero_loop_outer: 27174
_add_remove_to_zero_loop_outer: 32321
[{:meth=>:_add_remove_to_zero_loop_outer, :time=>"147.119287s", :loop_count=>1000, :key_count=>1}, -524, 1026, -367, 2171, 655, -543, -416, 790, 322, -541, 1844, 4425, 633, -1709, -2373, -2048, -651, 1235, 509, 90, 881, 2605, -2853, 60, 89, 249, -970, 2602, 1973, -3029, 78, 230, -329, -1626, 18, -2215, -492, 801, -2753, 153]
._compute_if_absent_loop_outer
[{:meth=>:_compute_if_absent_loop_outer, :time=>"3.476924s", :loop_count=>1, :key_count=>6142}, 342, 49, 177, 130, 308, 6, 159, 85, 77, 265, 198, 305, 172, 90, 46, 29, 51, 9, 1, 8, 4, 24, 79, 58, 211, 220, 59, 219, 29, 104, 315, 139, 88, 181, 382, 441, 310, 160, 370, 242]
_compute_if_absent_loop_outer
_compute_if_absent_loop_outer: STUCK!!!!
table.size 16, size_control: 12 adder: #<ThreadSafe::Util::Adder:0x2e74 @__cells=#<Rubinius::AtomicReference:0x2e78> @__base=#<Rubinius::AtomicReference:0x2e7c> @__busy=#<Rubinius::AtomicReference:0x2e80>>[2, [#<ThreadSafe::Util::Striped64::Cell:0x2e8c>, #<ThreadSafe::Util::Striped64::Cell:0x2e90>]]
[:key, #<TestCacheTorture::HashCollisionKey:0x2e9c @hash=0 @key=35>, :value, #<TestCacheTorture::HashCollisionKey:0x2e9c @hash=0 @key=35>, :hash, 0]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2eb4 @hash=1 @key=39>, :value, #<TestCacheTorture::HashCollisionKey:0x2eb4 @hash=1 @key=39>, :hash, 1]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2ecc @hash=2 @key=263>, :value, #<TestCacheTorture::HashCollisionKey:0x2ecc @hash=2 @key=263>, :hash, 2]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2ee4 @hash=3 @key=191>, :value, #<TestCacheTorture::HashCollisionKey:0x2ee4 @hash=3 @key=191>, :hash, 3]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2efc @hash=4 @key=285>, :value, #<TestCacheTorture::HashCollisionKey:0x2efc @hash=4 @key=285>, :hash, 4]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2f14 @hash=5 @key=294>, :value, #<TestCacheTorture::HashCollisionKey:0x2f14 @hash=5 @key=294>, :hash, 5]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2f2c @hash=6 @key=0>, :value, #<TestCacheTorture::HashCollisionKey:0x2f2c @hash=6 @key=0>, :hash, 6]
nil
[:key, #<TestCacheTorture::HashCollisionKey:0x2f44 @hash=7 @key=75>, :value, #<TestCacheTorture::HashCollisionKey:0x2f44 @hash=7 @key=75>, :hash, 7]
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
nil
#<Thread:0x2f98 id=1 sleep>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment