--- Log opened Mon May 18 00:00:24 2020 12:50 < adiabat> ja: Cool! Also left some comments, can merge with a couple aesthetic changes 12:52 < adiabat> rjected: have you looked at speed differences with safeAssignData() ? 12:53 < adiabat> if it's not much slower, I don't see a problem with doing the mutex. Though there *shouldn't* be any overwriting there, I guess there still is 12:54 < adiabat> maybe it'd be better to figure out where the overwrites are coming from and get rid of them before this happens, as redundant hashing is pretty expensive 13:12 < rjected> adiabat: I can write a benchmark pretty easily, I'll get back to you on that 13:12 < rjected> Yeah for sure reducing redundant hashing is a good idea 13:15 < rjected> Another idea would be converting to an atomic.Value or something in sync/atomic but it all depends on the proportion of read vs write, zero-mutex read is nice if we do it a lot 13:16 < rjected> versus whatever happens behind the scenes when you Load an atomic value 13:41 < adiabat> it should be write only, then block, then read... 13:41 < adiabat> at least the way it works now is row at a time 13:42 < adiabat> if you really wanted to use more cores / threads you could make it not block at the end of a row, but have mutexes for each position 13:43 < adiabat> so if a higher hash needed to be computed it would wait on the lower hashes to be finished... that seems hard though 13:43 < adiabat> and it's probably good enough parallelism doing it row at a time and blocking at the end of every row for all hashes to finish 13:50 < ja> adiabat: i put the panic there because go is not smart enough to realize that all branches are covered by the previous cases 13:51 < adiabat> ja: right but you can just leave it blank 13:51 < ja> adiabat: no, the compiler says "missing return". i could 'return nil' with a comment saying that it is impossible 13:52 < ja> but think i will just do '!delRemains && rootPresent' and then have the default branch return nil 13:52 < ja> it's smaller and more explicit 13:52 < adiabat> yeah that seems like it be easier to read 13:53 < adiabat> the == case is cool, but actually might be confusing 13:57 < ja> adiabat: ok, i force pushed, i didn't improve the comments, i think you'd be better at that 13:59 < ja> oh shit 13:59 < ja> something missing 14:00 < ja> ok fixed now, it was a duplication of delRemains 14:57 < adiabat> ah ok --- Log closed Tue May 19 00:00:26 2020