genrez
Joined 5 years ago
Joined 5 years ago
That being said, if I am interpreting Table 2 correctly, the study is saying that consuming a large amount of surgery beverages causes your risk of having low-testosterone related problems to rise by 2.29 times compared to not drinking many sugary beverages. This is after correcting for age, race, BMI, alcoholism, and physical activity levels.
The risk increase before correcting for these things is 2.78 times, so that would seem to indicate that sugary beverages do have a pretty large effect compared to the confounders they choose, though it is still possible sugary beverage consumption is acting as a proxy for something else.
The only item which standardjs forbids that I could identify as possibly producing a decent performance improvement if used is the "with" statement. They also forbid wrapping non-objects in objects, which I guess could provide extra-expressiveness, but seems like it would usually just be a performance penalty.
I have seen people recommending obviously inefficient things like including large third-party libraries just to look up an element by class name, but standardjs looks like it is just a set of linting rules. I don't agree with all of them but I don't think there is a set of rules everyone would agree to.
Edit: I was confused about how this could work, so I dug through [1] for a bit. It appears that for each object of that class created, an arrow function will be created on that object and its this will indeed be bound to the same scope that the constructor function is bound to. This is really cleaver and I applaud whoever thought it up!
It is interesting to note that this creates a new arrow function on each object as opposed to the normal definitions which create a single function which is stored in the prototype of the class. (its easier to check this in a browser's dev console then it is to decode the spec)
This would suggest that one should use different approaches for different types of objects: It makes sense to use arrow functions for "resource" or "actor" objects, of which there are few but they may have callback functions. It makes sense to use normal method definitions for "plain old data", of which there may be many, (which would make the arrow functions too expensive) but they should not have callback functions.
side-note: Most of my JS experience is writing userscripts for myself, so I definitely do my share of 'this' shenanigans.
So it seems a bit weird to me that they advocate using arrow function syntax instead of the regular syntax. They seem to be advocating using the new class syntax instead, so I guess they don't need the constructor or method creation features of the normal syntax, but I still don't see why they would specifically advocate for arrow function syntax. Is it faster? They say it interferes with other features, but which features?
[1] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
The rest of the book talks about doing data sharing efficiently (i.e. for not embarrassingly parallel problems), including some things I don't think I ever would have run across otherwise like RCU. All the while he explains the use cases for each of the techniques. If you are interested in making the most of your processors (and I suspect you are given this post), and are up for a technical read, I'd highly recommend this book.
EDIT: By which I mean to say that he covers all the stuff you posted, and explains exactly when it is worthwhile to use the high performance and communication techniques. If you want to know just the basic stuff, read the first 3 chapters.
Given that as far as I know, room-sharing is not standard Western parenting practice, I believe they have backed up with an appeal to authority the idea that Western style parenting is harmful. Furthermore, link [1] contains a link to [3] which is an recommendation from a pediatric journal that provides links to scientific papers that suggest room-sharing reduces SIDS risk by up to 50%. (see bullet point 4 of link [3]) Thus I think the appeals to authority are backed by evidence.
Thus I think that the article could have made a stronger point if they had talked about room sharing more instead of bed sharing, but I think they do have an evidence backed point that Western parenting is potentially harmful. They avoid ruffling parent's feathers too much by understating their point.
[1]: https://www.aap.org/en-us/advocacy-and-policy/aap-health-ini... [2]: https://www.lullabytrust.org.uk/safer-sleep-advice/ [3]: https://pediatrics.aappublications.org/content/138/5/e201629...
Could theoretically be for Rust, but it sounds like Rust doesn't have the aliasing optimizations working yet. Based off [1], it looks like Swift's ABI might be able to take advantage of these things. (I don't know much about Swift) Based off [2], it looks like Zig definitely can do these sorts of optimizations. Ada also has aliasing constraints, (you need to specify to the compiler that you want a thing to be aliasable) but I don't know if any compilers use them for optimizations. I know that Fortran can do these sorts of optimizations. Both Ada nor Fortran seem to be undergoing a PR renaissance, so they might be "trendy new languages" for that purpose.
However, given that the other two articles on the author's website [3] are about Delphi and complaining about AT&T assembly syntax, I'd suspect that the author is just a system's programmer annoyed about ABIs.
[1] https://gankra.github.io/blah/swift-abi/#ownership [2] https://ziglang.org/documentation/0.2.0/#Type-Based-Alias-An... [3] https://elronnd.net/writ/