HNHacker News
TopNewBestAskShowJobs

scott_s

34,207 karma · joined March 2, 2008

Computer science research and systems software development.

http://www.scott-a-s.com

submissionscomments
scott_s··on A Defer Mechanism for C
The main use case is not forgetting to free resources. It's when you do have resource-freeing code, but it's tricky to make sure you free only the resources you know for sure you have already allocated. This is common in the Linux kernel. A great example is this function I found at random from fork.c: https://github.com/torvalds/linux/blob/master/kernel/fork.c#...

Notice that there are five different goto targets, each for a specific case of what has-and-has-not been allocated. The resources are memory, locks, and even TLB flushing. This code would probably be cleaner with defer.

scott_s··on A Defer Mechanism for C
The proposal poses object value capture as an open question. See heading "Should object values be captured?" on page 14 of the proposal: http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2542.pdf
scott_s··on A Defer Mechanism for C
Yes, see the discussion in the proposal on page 13, under the heading "Should defer statements be static or dynamic?": http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2542.pdf
scott_s··on How to Make Your Code Reviewer Fall in Love with You
I think you misread what they wrote:

> Hard agree.

scott_s··on Warner Bros. Will Send Entire 2021 Slate to HBO Max and Theaters
Despite the freedom not to, many authors still break down their novels into roughly equal length chapters.
scott_s··on Warner Bros. Will Send Entire 2021 Slate to HBO Max and Theaters
I meant that you stated the syndication threshold as the sole reason for filler, and as I tried to explain, there were other thresholds at play.
scott_s··on Warner Bros. Will Send Entire 2021 Slate to HBO Max and Theaters
I think you're discounting the in-season requirements that the networks had. They would usually require on the order of 23 episodes for a season, and sell advertiser time during those episodes months in advance. Hence the prevalence of "clip shows": we promised the network x episodes, we only really have been able to make x-1 full episodes, so let's create an episode that is mostly clips from other episodes.
scott_s··on Warner Bros. Will Send Entire 2021 Slate to HBO Max and Theaters
What you're talking about is already happening, but we still call them "tv shows." A great recent example is The Queen's Gambit. It's adapted from a novel, which "normally" would become a movie. But instead it became a 7 episode miniseries, which allowed for much more character development than a 2-hour movie. Game of Thrones is the obvious example of something that also could have instead been several movies.

I think what we're discovering is that movies, as a medium, are for narratives that can be told in under 3 hours. If your narrative requires longer, or you just want to be able to have more time to develop characters or worlds, it's better to create a show.

scott_s··on CoroBase: Database engine using C++20 coroutines to hide cache misses
Their research paper explains the work: https://arxiv.org/pdf/2010.15981.pdf
scott_s··on Artist releases album called “Ok Google Play Music” on Spotify
Also: Wake me up at 7.
scott_s··on Materialize Raises a $32M Series B
> Does materialize describe how they implement timely dataflow?

It's open source (https://github.com/TimelyDataflow/timely-dataflow), and also extensively written about both in academic research papers and documentation for the project itself. The GitHub repo has pointers to all of that. See also differential dataflow (https://github.com/timelydataflow/differential-dataflow).

scott_s··on The psychology behind ‘revenge bedtime procrastination’
I'm not ready for it to be morning yet. That's what I would think during my early days of graduate school, when I would spend over 12 hours a day on campus, juggling courses, course work, my first foray into research, as well as teaching assistant responsibilities. At night, I would often just listen to music and do some light internet browsing for an hour or two, despite being tired.
scott_s··on Undergraduate Math Student Pushes Frontier of Graph Theory
Agreed, and this one of the worst aspects of our PhD system - graduate students need to have a body of work that is theirs. Even amongst a collaboration, they need to carve out sections that are unquestionably theirs so they can defend a dissertation that is also theirs.

I am now at IBM Research. In my career here, I have experienced multiple working relationships where I feel we were able to accomplish far, far more than at least I know I could have achieved on my own. Maybe they didn't need me, but I know for certain I needed them to be so productive. That this kind of working relationship is disincentivized for graduate students is, to me, tragic.

scott_s··on ARM and Lock-Free Programming
You may find my work from grad school useful, which was a lock-free memory allocator. The paper [1] and source code [2] are easily available.

[1] Scalable Locality-Conscious Multithreaded Memory Allocation, https://www.scott-a-s.com/files/ismm06.pdf

[2] https://github.com/scotts/streamflow/

scott_s··on ARM and Lock-Free Programming
Yes, in addition to the atomics and memory ordering primitives added in the C++11 standard [1], I find the Boost lock-free structures quite reasonable [2]. (Yes, I'm aware some have an automatic aversion to Boost. But it is well-designed and I believe is a header-only library.)

[1] https://en.cppreference.com/w/cpp/atomic

[2] https://www.boost.org/doc/libs/1_74_0/doc/html/lockfree.html

scott_s··on A better Kubernetes from the ground up
Me and my colleagues came up with an abstraction called conductors for the orchestration problem. Short version is that when you have some dependence on multiple resources being in a particular state before creating or updating yet another resource, use a conductor. They observe multiple resource kinds, and operate a FSM internally. State transitions happen upon receiving an event from an observed resource. The logs of the conductor make it easy to debug dependency problems, because you can easily see that your conductor’s FSM is in a particular state, waiting to see some number of a particular resource.

The other principles we developed are “controllers” only control one resource and all resource updates for a resource kind must be serialized through a coordinator. Our paper has much more detail: A Cloud Native Platform for Stateful Streaming, https://arxiv.org/abs/2006.00064

scott_s··on “To be safe allocate 5 bytes more than you need”
This sort of requirement is met by compile time computations. I know C++11, D and Rust have them, and I imagine many more languages do as well. The need for this sort of thing clearly has not gone away, we're just moving away from a free-form, textual pre-processing stage.
scott_s··on The Vale Programming Language
The author also compares and contrasts at the end of a blog post: https://vale.dev/blog/zero-cost-refs-regions#afterword:borro...
scott_s··on Vitamin D improves survival in Covid-19 elderly patients
> This study is clearly not a fishing expedition because vitamin D has been a topic of interest in coronavirus disease for months now with multiple studies conducted.

That others have studied something does not preclude these researchers from "fishing" their data looking for a correlation. Since we don't know what process they used, we can't say. When considering the other weaknesses (such as the small number of "comparators"), it furthers my consideration of this study being weak evidence.

scott_s··on Vitamin D improves survival in Covid-19 elderly patients
My point was that the submitted article was weak evidence. That is not the same from saying their conclusions are wrong. It very well may be the case that Vitamin D supplementation is effective against COIVD-19. But the submitted article is not strong evidence for that.

As I pointed out elsewhere, a measured take: https://www.devaboone.com/post/vitamin-d-and-covid

scott_s··on One Bit Ferrite Core Memory
I had some confusion in really understanding how the core memory worked from the author's brief description, and I decided that's something I should remedy. This video has a good explanation, with good figures and animations explaining it (the how part starts at 2:45): https://www.youtube.com/watch?v=AwsInQLmjXc
scott_s··on Vitamin D improves survival in Covid-19 elderly patients
I think we should be more measured in our conclusions. See https://www.devaboone.com/post/vitamin-d-and-covid
scott_s··on Vitamin D improves survival in Covid-19 elderly patients
> Unless they were also testing these other interventions, that critique does not apply.

How do we know they weren't? Since this is not a RTC, but rather an analysis of historical data, we don't know how much they divided up this historical data looking for correlations.

scott_s··on Vitamin D improves survival in Covid-19 elderly patients
Agreed. To support what you said: the phrase "was associated with" is not a causative claim. You cannot go from that phrase to "improves."
scott_s··on Vitamin D improves survival in Covid-19 elderly patients
The current discussion here seems to be about Vitamin D in general, and ignoring the study itself.

In my reading, this study is weak evidence. This was not a randomized, controlled trial, but historical analyses of a natural experiment. In itself, that's not a problem: we can learn a lot from natural experiments. But I don't think this instance is much of an "experiment."

As I understand it, all of the residents (96 in total) of a particular nursing home receive regular Vitamin D supplementation. Of the total residents, 66 got COVID-19. Among that group, they realized that 57 of them had received their Vitamin D supplementation either within a week of being diagnosed with COVID-19, or one month prior. That is the intervention group. The remaining 9 people are the "comparator" group. They found the intervention group had better survivability.

The main three reasons I consider this study weak evidence is that the number of people in the "comparator" group is very small (9!), and they - as far as I can tell - do not explain why these people did not receive their normal Vitamin D supplementation. The "comparator" group is supposed to have had a similar baseline, but there's still, to me, a strong possibility of a confounding factor. Finally, there were four total interventions: corticosteroids, hydroxychloroquine, "dedicated antibiotics" and the observation about Vitamin D. The more things you try, the less surprising it should be that there is a correlation along one of them.

scott_s··on Postgres Observability
The problem for me is that by changing what I'm not looking at, it draws me to look at what was taken away. We are drawn to look at movement. It may be better to leave the not-relevant stuff alone, and instead highlight what the user is currently hovering over. Something as simpler as making the relevant text bold, increasing the thickness of the lines, and maybe making the text box a darker shade may help.
scott_s··on Ask HN: Wouldn't it be great to be able to follow fellow HN users?
I have wondered something similar, even though I also think that eliminating vote counts was a good thing.

A possible feature is, per-thread, giving commenters the option of viewing karma for posts, but doing so prevents them from being able to participate in the discussion. I'm not sure how much I like this idea, and it's likely too fiddly for HN's style.

scott_s··on Ask HN: Wouldn't it be great to be able to follow fellow HN users?
I maintain a folder with bookmarks of particular users' comments pages.
scott_s··on The Lonely Work of Moderating Hacker News (2019)
I have a saying on this topic: you’re not as funny as you think you are. https://hn.algolia.com/?dateRange=all&page=0&prefix=false&qu...
scott_s··on The Lonely Work of Moderating Hacker News (2019)
Agreed. And HN has something I associate with it specifically: the back-and-forth argument, maintaining consistency in positions and reasoning, looking like two people taking. But, upon inspection, many people are involved. That, I think, is an example of the de-emphasis on identity.
← PreviousPage 8 of 34Next →