4 ms·
Question: do people find that sort of animation easier to grok than showing the interleaving visually, as I do at https://outerproduct.net/boring/2023-01-27_tra
by moonchild 3y ago
Question: do people find that sort of animation easier to grok than showing the interleaving visually, as I do at https://outerproduct.net/boring/2023-01-27_trans-locks.html#table https://outerproduct.net/boring/2023-01-27_trans-locks.html#...? I prefer the latter, because it lets me see everything at once, but may switch to the former presentation style if other people prefer it.
- jesse__ 3y agoFWIW coming from some random stranger on the internet, I like the animations. They're short enough that even though all the information isn't on the screen at once, I can remember/interpret the whole thing after it's run once. I could also imagine for demonstrating longer-running bugs (of more than just a few instructions) a user-controlled slider might be nice.
- taeric 3y agoThe answer is almost certainly yes. For both directions of the question. Few things have a single visualization that is the best.
- TechBro8615 3y agoNot that it would apply in this particular case, but my all-time favorite visualization of concurrency is this 2016 blog post called "Visualizing Concurrency in Go" [0]. So good. [0] https://divan.dev/posts/go_concurrency_visualize/ https://divan.dev/posts/go_concurrency_visualize/
- rektide 3y agoUsing time to represent time is a pretty helpful & intuitive strategy, very nicely on display in this example & the submission. It does require some waiting around to see how things develop (versus the at-a-glance approach) but it really feels so very graspable & clear to me.
- tavianator 3y agoI think for anything more complicated than my examples, animations would be worse than your explicit interleavings. That said, I don't really think interleavings are the best way to show weak memory effects either, since they give the impression that there is some global order that is the same in all threads. I'm not sure how to do a nice visualization of the reality though. One idea: show the interleaving of atomic operations, and based on that, show what values each other read might see. Maybe even let the user change the interleaving by dragging stuff around, and show how it changes which other values can be observed.