1. 4

    and also were not suited to modern data science algorithms and workflows

    The line when I closed the article. If you cannot make Java work for “modern” data science algorithms and workflows than you are holding it wrong.

    1. 1

      Can you elaborate?

      1. 1

        Java and specifically the JVM is one of the most optimized platforms out there. Several companies implemented many products using these especially for big data use cases. If you cannot make Java + JVM (or Graalvm) work for data science algos + workflows what makes you think that you can make Rust do these things where you have to implement roughly 10x code because there are no libraries that you can build on.

        Google, Amazon, Netflix all publish tons of libraries that are designed for high performance computing and large scale data systems that millions of users use every single day. Can you tell the same thing about Rust?

        I love the ideas of Rust but I miss roughly 90% of the libraries that I would need to be productive in it. There is also a higher barrier of entry with the concept of lifetimes and the additional complexity these introduce.

    1. 10

      Woah. I had higher standards for conversations in a kindergarten. Laughable. Missing parenthesis are a problem? I can’t help but wonder what would they say if they stumbled upon other features of the language beyond missing parenthesis like traits, metaprogramming, typestate driven design, hygenic macros etc. They have no idea about the language and are completely disinterested. How one can even have a reasonable discussion after a joke of a statement like this. Regardless of what kind of problems Rust is causing or solving, this pathetic, annoying, dismissive, passive-agressive tone will make it very hard to progress. Even with much better driver/kernel module examples and APIs.

      1. 4

        There’s quite a bit of an impedance mismatch at the community level and it seeps through a lot in these scenarios. “Quality discourse” like this will keep happening for a while, because both communities have a lot or work to do in the “letting go of the smug dismissiveness” department. See, for example, this unofficial but pretty popular introductory document on Rust’s ownership and memory management model:

        Mumble mumble kernel embedded something something intrusive.

        It’s niche. You’re talking about a situation where you’re not even using your language’s runtime. Is that not a red flag that you’re doing something strange?

        It’s also wildly unsafe.

        But sure. Build your awesome zero-allocation lists on the stack.

        It’s a story as old as comp.lang.lisp: people who do meaningful work in a language and are otherwise completley uninvolved in language fanboy flamewars get flak because of the more visible fan discourse, which is exactly what you expect from fan discourse.

        1. 1

          Indeed. Many in the kernel community must vividly remember the history of people wanting C++ in Linux. And the swarm of Rust fanboys in 2021 must look very similar to C++ fanboys a couple of decades ago.

          Someone with an intimate knowledge of each of the languages can probably choose the right tool for the job. Meanwhile someone that only knows one language well will always prefer it – which is not unreasonable!

          My own limited experience with no_std Rust tells me it’s not nearly as easy to use as standard Rust, while my own limited experience with Linux tells me that not making mistakes in C kernel code is very difficult for mere mortals. I really hope Rust in Linux will be a great success, but only time will tell.

        2. 3

          Yeah, seriously. It sounded like petulant whining. From someone who’s programmed in one language forever, and hates the idea of change.

        1. 20

          What this means is that by default, binaries provided by many Linux distributions won’t contain instructions from modern Instruction Set Architectures (ISAs). No SSE4. No AVX. No AVX2. And more. (Well, technically binaries can contain newer instructions. But they likely won’t be in default code paths and there will likely be run-time dispatching code to opt into using them.)

          Yup, this was why I pushed so hard to get CPU feature detection and the ability to compile functions with specific target features in Rust. Before this, I was distributing ripgrep binaries compiled with SSSE3 enabled. In case you don’t know, SSSE3 appeared on x86_64 CPUs as early as 2006. But I still got at least several bug reports from folks who tried to run these binaries and got SIGILL. (At least some of them appeared to be in a VM of some sort with limited CPU feature support.) Once Rust got runtime feature detection, it was great to switch over to that. Not only can I publish portable binaries, but it also means that the binaries published by Linux distros (and Homebrew) all have this stuff enabled too. By default. Without the person compiling the program needing to know to set -mtune or what have you.

          C programs do this too. For example, if you call memchr when using glibc, it will do the same kind of CPUID detection and dispatch to SSE2 or AVX2 or whatever implementation. So the use of more recent ISAs may be a bit more prevalent than you might think because of this. And this sort of dynamic CPU feature detection is typically used specifically in code that tends to be hot. So a lot of us are probably already benefiting quite a bit.

          But, I do agree with the OP’s bigger point. The extent to which we are missing out on additional optimizations is indeed unclear. Although I will say that in my own unscientific experiments, it’s pretty rare for me to compile with -march=native and see a noticeable improvement. (My hypothesis being that the performance sensitive parts have already been written to take advantage of the new ISA extensions via dynamic CPU feature detection.)

          1. 2

            Not only can I publish portable binaries

            What does portable mean here? Conditional compilation applies during, well, compilation; my understanding is that users must recompile their programs but they don’t have to hunt compiler feature flags to enable stuff working on their machines, right?

            1. 6

              It means the binaries I publish will work on x86 cpus without AVX2. But when AVX2 is enabled, it will use different routines that make use of 256 bit vectors. No recompilation or conditional compilation needed. It just works. :)

              1. 3

                I see. Isn’t this conditional jump expensive? How much would perfomance differ between binary with dynamic detection and binary with hardcoded AVX2 (or others) instructions?

                1. 9
                  1. The programmer controls where the jump is, so you can put it at a point where it isn’t so expensive relative to the work.
                  2. The check can be cached so that you aren’t re-running the cpuid instruction.
                  3. You can run the check once the first time you call the function and then stuff the actual AVX routine into a function pointer. This prevents inlining, but you couldn’t inline an AVX routine into a program compiled with the base x86_64 ISA anyway. Example: https://github.com/BurntSushi/rust-memchr/blob/427fdc384007d0a5b00b190e8313b3c8d3694a67/src/x86/mod.rs#L31

                  glibc does this. Pretty much everyone who who writes low level open source libraries that can benefit from vectorization does this too.

                  Bottom line: yes, the branch can be expensive, but there is almost always a way to make it practically free. Last time I checked, glibc’s memchr took on the order of 1 nanosecond to run on empty input.

            2. 1

              Yeah but to be honest, I’d also like to use things like loop unrolling with AVX2 optimizations without having to manually implement the SSE #[cfg()]‘s (and is_XXX_feature_detected) myself. So your solution is nice for things where you know how and where to apply AVX2. But it sadly doesn’t help people like me who would probably still benefit from SIMD but don’t implement it manually. So hopefully at some point the compiler will add feature detection to generated SIMD instructions by itself, so we don’t have to decide on the LCD any more.

              1. 2

                Yes, it doesn’t cover all use cases. But it hits done very big and important ones.

            1. 7

              I wish all the best to lobste.rs readers (: Wesołych Świąt to everyone!

              1. 3

                szczęśliwego Nowego Roku!

              1. 14

                This is how I git, as a self-admitted near-idiot:

                • Never branch, always on m*ster.

                • Commit mainly from IntelliJ’s GUI.

                • Push either from IntelliJ or command line, can go either way.

                • On the server, git pull.

                • If there’s any trouble, mv project project.`date +%s` and re-clone.

                1. 8

                  In my opinion people tend to pay too much attention to CLI commands and steps. As long as one understands what branches and commits are, it becomes immensly easier to handle git and potential problems.

                  1. 1

                    This is what I refer to as the “xkcd git workflow”: https://xkcd.com/1597/

                    1. 1

                      I feel like even people more used to git resort to the last bullet point every now and then, I know I have :P

                      1. 3

                        https://sethrobertson.github.io/GitFixUm/fixup.html is a fantastic resource for fixing mistakes, which helps demystify got. It’s a ‘choose your own adventure’ guide where you decide what state you want to end up at and a few other facts, and it tells you what to do.

                        1. 1

                          First step

                          Strongly consider taking a backup of your current working directory and .git to avoid any possibility of losing data […]

                          Hehe, off to a good start. This basically sums it up though, that copy of a directory is a safety net in case any other steps go wrong.

                        2. 1

                          I admit I used it a lot at my university, because they didn’t taught us how git works and I didn’t took to the time to learn it on my own.

                          Now, when my local branch is mess, if I have no local changes to keep and I if know for sure that my branch is in a clean state on the remote repository, I just do:

                          git reset --hard origin/my-branch

                          With the years passing, it appears to me that you don’t end up with this “fak I have to reclone my repo” or “fak I don’t know how to fix this conflict” problems if you are meticulous with what you commit and where.

                          It take a bit more time upfront to make commit that you are proud of, but in the end it makes it very easy to understand what you have done some days/weeks/month ago (and it will save your ass when you have to find when a regression/bug happened).

                          TL;DR: git flow + self-explanatory commits = <3

                          1. 1

                            Oh man! I did this two weeks ago. I had folders numbered 1-n and in each one I had the same project cloned but in a messed up state. Granted that it was a new technology stack for me, nodejs to be precise.

                        1. 1

                          Innocent question: Is there a market for things like these?

                          1. 2

                            I feel like an idiot, but I’ve spent about 15 minutes trying to massage the config file correctly for a completely standard IMAP+SMTP setup and I’ve seen variants on Config file contains errors: data did not match any variant of untagged enum SendMail for key `composing.send_mail` so many times that I’m losing hope I’ll get there.

                            edit: got there. Needed password = { type = "raw", value = "xyz" } instead of just password = "xyz". Serde does not have the best error reporting.

                            1. 2

                              I’m sorry for the confusion, I should add explicit examples to the doc for this!

                              Serde does not have the best error reporting.

                              I will see if I can use my own errors with serde. The user shouldn’t have to know about the inner config types, but only the toml syntax.

                              1. 1

                                Yeah, implementation leakage is bad :/

                            1. 4

                              I never had much respect for alarmism. We’ve had it, in regard to climate, for decades, and I only too well remember Al Gore warning us in 2008 of an ice-free Arctic by 2013, just to give one of many examples. Greta Thunberg is the next up-and-coming generation of climate alarmists and given we do in fact have a global warming, the human factor is yet to be assessed (consider we are easing out of a small ice-age that just, out of chance, had its lowest point in the mid 1800’s when humans started measuring temperatures systematically).

                              However, I still wholeheartedly support renewable energy and resource savings, because we live on a finite planet with finite resources. We should do anything to save resources and energy, but not fall in panic over it or embrace ridiculous measures that are not sustainable in the long term. Maybe it’s needed to push the majority of people, but as a rational person I feel insulted by this.

                              Measuring everything in “CO2 emissions” is valid, but for a different reason, in my opinion, than to mitigate the effects on the atmosphere: The carbon we emit comes from fossil fuels, which are one finite resource I think should not be “wasted”. Given “CO2 emissions” directly correlate with carbon-based fuel-consumption, it may be a bit mislabeled, but generally valid.

                              In terms of web development: Stop bloating your websites with too much CSS, JavaScript and excessive markup and reduce the transferred weight, but don’t panic over it or say that a website is “killing the planet”. This is an industry-wide problem and needs to be solved at scale. When this doesn’t change, your website won’t make much of a difference compared to the few major players.

                              1. 16

                                the human factor is yet to be assessed

                                I thought that in 2020 it is a common knowledge that humans are without a doubt responsible for global climate crisis. And temperatures are measured also by other means than direct ones. That includes geological ones.

                                1. 3

                                  Indeed only a fool would say that we humans, who affect the planet in so many profound ways, have no influence on the climate. The question is: How much? An everlasting ethos, in my opinion, is resource-saving, but it needs to be balanced so we don’t throw away what we’ve achieved as a species.

                                  1. 11

                                    What is missing in this analysis by Carbon Brief? Most of the current natural phenomena actually contribute to global cooldown and work in our favour. Humanity carbon footprint managed to beat even that.

                                    1. 4

                                      Climate is extremely complex, and one can’t really predict most things. I may bring out a strawman here, but how can we be so certain about centennial climate predictions (2°C-goal until 2100, for instance) when our sophisticated climate models can’t even accurately predict next week’s weather?

                                      But as I said in my first comment, my biggest problem is the alarmism and I’m not even denying the human influence on world climate. So I’m actually on your side and demanding the same things, only with a different viewpoint.

                                      1. 9

                                        how can we be so certain about centennial climate predictions (2°C-goal until 2100, for instance) when our sophisticated climate models can’t even accurately predict next week’s weather?

                                        Because weather and climate are not the same. We can’t model turbulent flow in fluid systems, but we can predict when they change from laminar to turbulent on a piece of paper. We can’t model how chemical reactions actually work at an atomic level, but whether or not they should take place is another simple calculation. We can’t model daily changes in the stock market, but long-term finance trends are at least vaguely approachable.

                                        1. 16

                                          I’m not even denying the human influence on world climate.

                                          you said, “the human factor is yet to be assessed,” when it has been assessed again and again by many well-funded organizations. that’s denial, bucko

                                          1. 1

                                            No, it’s not denial and science is not a religion. Assessment means studying an effect, and I still do not think that the foregone conclusion of 100% human influence is substantial. It’s less than that, but not 0%, which would make me a denier.

                                            1. 1

                                              Assessment means studying an effect

                                              so by “the human factor is yet to be assessed,” did you mean that the effect has not been studied? are you not denying that the human factor has been studied?

                                              typically the category of “denial” doesn’t mean you think a claim has a 0% chance of being correct; most people are not 100% certain of anything and the concept of denial is broader than that in common speech. organizations of scientists studying climate change are very confident that it is largely human caused; if your confidence in that claim is somewhere nominally above 0%, it would still mean you think it is most likely untrue, and you would be denying it.

                                              1. 1

                                                An effect can be heavily studied but still inconclusively. From what I’ve seen and read, the human factor is obviously there and not only marginally above 0%, most probably way beyond that, but I wouldn’t zero out other factors either. If that means denial to you, then we obviously have different definitions of the word.

                                                1. 1

                                                  saying the human factor hasn’t been assessed casts doubt on it. now you are saying it is “obviously there” which is quite different.

                                            1. 5

                                              The only thing I can do, as an individual, is to adapt, prepare and overcome. In my initial comment, I already mentioned an example for wrong alarmist predictions, and they even date back to the 60’s! Moving the fence pole and saying the arctic ice will have disappeared in the next n years won’t help bring me on board. Al Gore back then cited “irrefutable” science and I remember being presented his movie in school, but his predictions all proved to be wrong.

                                              Still, we are on the same side, kel: Our footprints are unsustainably large, and I as an individual strive to reduce it whenever I can. The truth is, though, that even Germany, which only contributes 2% to global carbon emissions, doesn’t play much a role here, and the big players need systemic change.

                                              It’s funny, actually, given this pretty much rings with the individual argument of slimming down your website: When Google, Youtube, Medium, etc. don’t move along, it doesn’t make much of a difference.

                                              1. 11

                                                The only thing I can do, as an individual, is to adapt, prepare and overcome.

                                                It is both frustrating and liberating how little influence an individual has. However, in the moment you decided to post a number of comments on this site, you contribute to the public opinion forming process. I think that this gives you much more influence than immediately obvious. Discussions on sites like lobste.rs are read by many people, and every reader is potentially influenced by the opinions you or anyone else express here. And with great power comes great responsibility ;-) With that in mind, I am glad that other commenters challenged your initial comments about climate “alarmism” and prompted you to clarify them.

                                                1. 7

                                                  germany is the most powerful state in the european pole of the tripolar world economic system. it has much to say about how other countries it is economically tied to are allowed and enabled to industrialize and maintain their standard of living. germans own plenty of carbon-emitting capital in countries that don’t have the same level of regulation, and they need to be made accountable for the effect they have on the world.

                                          2. 3

                                            so we don’t throw away what we’ve achieved as a species

                                            Do you truly think silly performative ecological politics are going to “throw away” your first world niceties or are you talking about how ecological collapse will likely trigger progressively even more massive failures in supply chains as we inevitably blow through 1.5C

                                            1. 3

                                              There’s more to the world than economics, e.g. achievements in human rights and freedoms. But I don’t want to go too off-topic here (we are on Lobste.rs, after all).

                                              1. 5

                                                achievements in human rights and freedoms

                                                None of this will matter when people living in most affected areas – that are suffering from climate crisis already (thanks to droughts, lands becoming effectively uninhabitable etc.), not to mention what will happen in the following years – will come to our first world demanding a place to live. And we will point our guns at them. As one of the commenters said: “Desperate people will do desperate things”. And all of this will happen over years, decades. Painstakingly.

                                                Unfortunately some people will write it off as plain alarmism while dismissing well proven scientific position. And the position is: I want to have good news but it looks really fucking bad. I’d love to ignore all those facts just to live a happier life but I find it hard. It saddens me deeply that behind that facade of freethinking, you pretty much made up your mind for good. I do not mean to insult you. It’s just the way you speak in all your comments that makes me think that way. I hope I am wrong. Eh, shame.

                                                One could consider famous Newsroom piece about climate change as an alarmism but unfortunately it seems to be very on point.

                                        2. 9

                                          The planet will be fine. It’s the people who are fucked.

                                          George Carlin

                                          I almost want to agree with you, except that underestimating the impact of climate change has already cost society massively and climbing.

                                          Firstly, if you believe that our current rate of temperature change is historically typical, there’s an xkcd comic for you.

                                          I will go as far as to say that to consider climate change an existential threat are perhaps looking at it the wrong way. But I’m not about to start undermining their cause in this way because people tend toward apathy toward long-term threats and the cost of underestimating climate change is far greater than the risk of overestimating it. Climate change has already begun to have direct costs, both monetary and humanitarian.

                                          As an example of monetary cost, in Gore’s documentary he presents a demonstration of rising sea levels around Manhattan Island and makes a point that the September 11 memorial site will be below sea level.

                                          This might be true, but below sea level does not mean underwater. The flooding projection makes the assumption that humans are either going to do nothing about it and drown or are going to pack up New York and leave. I think neither scenario is likely.

                                          What will happen is that the rising sea level will be mitigated. The city will build huge-scale water-control mechanisms (such as levees). The cost of living on the island will rise sharply. Once in a while, this system will fail, temporarily flooding the homes of millions of people. They will bail it out and go on living.

                                          Not so bad, right? The catch is that the projected cost of this, in purely financial terms, is predicted to vastly outweigh the cost of reducing pollution now. And we don’t need to hit discrete targets to see a benefit – every gram of CO2 that we don’t emit today will reduce the amount of water in a nearly-certain future flooding event.

                                          This is beside the humanitarian cost.

                                          Climate change does not come without opportunities. Likely, the farming season in Canada and Russia will lengthen, leading to more food produced in those countries. Cool, but meanwhile in other places, the drought season will lengthen. People won’t be magically transported from one place to another; there are logistical, political, and sociological obstacles. People stuck in those regions will become increasingly desperate, and desperate people do desperate people things. With today’s weapons technology, that’s the kind of situation that really could lead to humanity’s extinction.

                                          So please be careful with the point-of-view that you present. You might not be wrong, but contributing to a culture that underestimates the oncoming danger is exactly what got us here in the first place.

                                          1. 5

                                            I’m not denying the danger or playing it down, and we can see current effects of global warming. We humans must adapt to it, or else we will perish. It would not be far-fetched to assume that this global warming might even lead to more famines that can kill millions of people.

                                            The problem I see is the focus on CO2, but resource usage has many forms. Many people find pleasure in buying EVs, while charging them with coal power and not really reducing their footprint a lot (new smartphone every year, lots of technological turnover, lots of flights, etc.). I’m sure half of the people accusing me of “playing it down” have a much larger “CO2 footprint” (I’d rather call it resource footprint) than I do.

                                          2. 9

                                            The climate has not changed like this before in human timescales. https://xkcd.com/1732/

                                            Today, denying human-induced climate change requires more than disagreeing with the scientific consensus on future predictions, it requires denying current events. The climate crisis is already here, and it already has a death toll.

                                            The good news is that you don’t need to update your understanding and stop swallowing narratives produced by fossil fuel corporations, although we could certainly use all the help we can get. You just need to get out of the way of people like Greta who are taking meaningful action to avert the climate crisis on a systemic level. If you live in the US, Sunrise Movement are extremely effective young organizers who deserve your respect. If all you have to offer is sniping from the sidelines, maybe you should rethink your contributions. Have you actually done anything to make the world a better place, or do you just complain about people who do the work?

                                            1. 5

                                              Given the many factors influencing climate itself and the models built to predict it, studies greatly diverge from each other. Big fossil fuel corporations cite the least-alarmist ones, and environmental extremists cite the most-alarmist ones. As always, the truth lies in the middle.

                                              It’s a great shame that people die from this, given it’s a negative effect of the fact that the entire industrial age (including urbanization and expansion) was built on the assumptions of a small ice age that we had until the 1850’s and 1900’s. The increasingly warm global temperature has its toll.

                                              My favourite example is the nordic spruce, which is the main tree for corporate wood production in Germany. It originally comes from the mountains, but was increasingly used during the industrialization and planted in normal plane land, which worked because the weather was still relatively cool. The few degrees of warming leads to a massive weakness of the trees, and our German forests, which are substantially made up of spruce monocultures, are infected with numerous diseases and pests because of this.

                                              Over the years I’ve read so many alarmist reports by big scientific players which proved to be completely false, which is okay. Scientists can err, especially with something as multivariate as climate. My view is that we should not only look at “CO2 emissions” as a mantra, but adapt to the changing climate (diversify forests, etc.) instead of turning this into yet another speculator’s paradise with CO2-certificates which help nothing but shift wealth.

                                              The real damning truth is the following: I live in Germany, and if one flipped a switch that would wipe Germany and all its inhabitants from the face of the earth, the global CO2 emissions would only drop by 2%. As always, it’s the big players (USA, China, etc.) that need to change systemically.

                                              Have you actually done anything to make the world a better place, or do you just complain about people who do the work?

                                              Not to sound too harsh, but I basically don’t matter, just like the individual Chinese or US person matters. Electronic vehicles won’t make a difference, because CO2 emissions are just offset to developing countries where the battery-components are mined and processed. Charging an EV in Germany means coal power, no matter how much you buy “eco” electricity, as it’s just a big shuffling on the energy market.

                                              I do my part not buying a phone or computer every year, driving a used car (Diesel), which is still more environmentally friendly than buying a new car which needs to be produced in the first place, buying regional, etc. These things, as an individual, make much more of a difference than buying a Tesla and continuing living the large lifestyle most people have gotten used to.

                                              1. 11

                                                As always, the truth lies in the middle.

                                                I want to call out this both-sides-ism. Basic shifting of the Overton Window can cause you to believe insane things if you assume that the truth always lies in the middle. Reasonable positions can seem extreme if you live in a society that, for example, has been shaped by fossil fuel billionaires for decades.

                                                It’s also wrong to ignore worst-case scenarios.

                                                There has been a great deal of discussion around the IPCC reports, which are very conservative (by which I mean cautious about only making predictions and proposals for which they have a great deal of evidence). Unlikely but catastrophic possibilities, such as the terrifying world without clouds scenario, also deserve attention. Beyond that are the “unknown unknowns”, the disaster scenarios that our scientists are not clever enough (or do not have the data) to anticipate.

                                                Global nuclear war or dinosaur killer asteroid impacts may seem unlikely today, but if we do not prepare for and take steps to avoid such cataclysms, someday we will get a very bad dice roll and reap the consequences.

                                                In other words, the obvious predictable results of global heating on our current trajectory are bad enough, and I do not consider discussing them to be alarmism, but edge cases that might be reasonably seen as alarmism I feel are underappreciated, rather than overpublicized as you seem to believe.

                                                In other words, the truth, rather than lying in the middle, might be significantly worse than any messaging from the mainstream climate movement suggests.

                                                1. 6

                                                  I’ll just say that personal consumption habits are not what I’m talking about, although I can see why you would bring them up, given the article we are commenting on is about changing personal website design.

                                                  Sustainability, and justice for those who suffer most in the climate crisis, will require changing how our society functions. It will require accounting for the true costs of our actions, and I’m not convinced that capitalism as we know it will ever hold corporations accountable for their negative externalities. It will require political change, on a local, national and global level. It will require grassroots direct action from the people. You as an individual can do little, but collectively I assure you we can change the world, for the better instead of for the worse.

                                                  1. 6

                                                    The role of the collective against the individual is of course a truism. The real costs of a product are often hard to reflect on. One good example is sustainably produced meat, which costs 6 times more than “normal” meat you can buy at the supermarket. Reducing meat consumption to once a week (instead of almost every day, which is insane) would greatly reduce the footprint of an individual, but I don’t hear greenpeace talking about reducing meat intake, even though it makes up 28% of global greenhouse gas emissions.

                                                    Instead, we are told to “change society” and accept new legislation that fundamentally change not only our economies, which deserve some reform in many places, but also individual freedoms for questionable benefit other than certain profiteers in certain sectors.

                                                    So I hope I didn’t come across as someone denying the effects of climate change. Instead, I don’t like the alarmism, which has been often debunked in the last decades, only to sell extreme political measures. A much more effective approach would be, I think, to urge people to reduce their resource footprint and allow them to make the right choices.

                                                    To give an example, maybe the EU could stop funding mass-meat-production if they really cared about this topic at all. Because this stuff really undermines the credibility of the entire climate “movement”.

                                              2. 2

                                                (consider we are easing out of a small ice-age that just, out of chance, had its lowest point in the mid 1800’s when humans started measuring temperatures systematically).

                                                Have any sources so I can read more about this? First I’ve heard of this.

                                                1. 4

                                                  Sure! There is a great paper called “Using Patterns of Recurring Climate Cycles to Predict Future Climate Changes” by Easterbrook et. al. (published in Evidence-Based Climate Science (Second Edition), 2016) which is sadly paywalled and I can’t fully share here, but there’s a great figure in it that shows temperature-readings from tree-rings in China.

                                                  Between 800 and 1200, we had the global medieval warm period, which allowed people for instance to grow wine in England and is the reason why Greenland is called “green” land (because it wasn’t covered in ice when the vikings discovered around 900-1000). The temperatures were normal between 1200 and 1600, but were then followed by a “Little Ice Age” between 1600 and 1900. In general, one can indeed see that global temperatures are rising above the average over the last 2000 years, but it’s nothing unusual.

                                                  To give one more example: Glaciers receding in Norway, due to the currently observable global warming, reveal tree logs and trading paths roughly from the Roman ages used between 300 and 1500. If you look at the aforementioned figure, this pretty much coincides with the extremely warm period beginning around 300. Even though it went below around 700, it never really go into a cold area which would’ve let the glacier “recover”, explaining that it has been used until 1500 when the next cold period (the Little Ice Age) started.

                                                  I hope this was helpful to you!

                                                  1. 6

                                                    It sounds like you’re arguing that the current global temperature rise is not due to humans, or is just a natural temperature cycle coming to an end, which is extremely wrong. The slight cooling period you’re talking about did happen, but as of now both the speed and projected magnitude of the current temperature changes are unprecedented in human history.

                                                    We can argue all day about specifically how bad things are going to get given the temperature rise, and how much someone’s stupid little personal website is going to contribute to it, but the fact that the temperature rise is man-made and is changing faster than any global temperature change ever in human history is supported by enough broad scientific consensus to be pretty much indisputable.

                                                    1. 4

                                                      This is a placeholder reply so I don’t forget (immediately quite busy), but there is no evidence the pre-industrial era “little ice age” was a global phenomenon.

                                                      1. 4

                                                        That could very well be! What I cited were results from Europe and Asia, and I would not be surprised if it turned out differently in other places of the world.

                                                1. 3

                                                  23 minutes of incremental compilation? How a simple change in an actual application causes upstream dependencies to recompile? Genuinely curious.

                                                  1. 2

                                                    The application is split into multiple crates (mostly to speed up compilation). The change was in a crate that most of the others depend on. It’s probably close to the worst case for that project, but I spent a lot of time debugging and benchmarking the code in that crate so I hit it often.

                                                    1. 3

                                                      Oh I see, so these are downstream. Makes sense. These compilation times are insane.

                                                      1. 4

                                                        Yep. I’ve since heard that buying everyone threadrippers has brought the times down somewhat, but it’s still a big productivity drain.

                                                  1. -10

                                                    Imagine green-fielding a 32-bit only kernel in the year 2018

                                                    1. 11

                                                      did you have anything meaningful to contribute to the discussion, other than this lazy, vaguely antagonistic comment?

                                                      1. -2

                                                        Imagine if you will, Andrew, that you wrote Zig to only produce 32-bit binaries. How do you think people would react to your project?

                                                        1. 5

                                                          I certainly would not antagonize or make fun of him had he made the zig compiler only produce 32-bit binaries.

                                                          I think I would question such a choice, but I would do so civilly not dismissively.

                                                          Beyond that, though, an OS is much different to a compiler; and the goals of zig as a compiler are different to the goals of serenity as an OS. Using a framework like llvm (which zig does) it’s not overly difficult to support different platforms. The marginal work required to support a new architecture in an OS is not at all trivial.

                                                          1. 1

                                                            The marginal work required to support a new architecture in an OS is not at all trivial.

                                                            That’s certainly true, which is why it should have been 64-bit only. Even TempleOS is 64-bit, and that tiny OS only offers 16 colors and a cooperative scheduler.

                                                            1. 8

                                                              And making it 64-bit would have provided what, exactly? Were you planning to switch your cloud containers to Serenity OS anytime soon and are worried about compatibility? Did the author advertise it somewhere as the next-generation operating system for AI, ML, IoT and augmented reality workstations, and now you’re bummed that there’s no way the buzzwords match the architecture?

                                                              Green-fielding a 32-bit only kernel in the year 2018 sounds like fun, which looks like this is what it’s all about. Maybe it’s not exactly this year’s greatest achievement in OS design, but yeah, if we’re talking technical merit, I’d rather wrestle with this than stupid Docker, thank you very much.

                                                          2. 7

                                                            Hopefully not like a douche with a superiority complex.

                                                        2. 6

                                                          It is 32-bit because of the expertise the author has in x86 microarchitecture. SerenityOS was never intended to be business-first-or-whatever project; author started it in private as a part of his convalescence process after years of alcohol overuse.

                                                          Who the fuck are you to judge? If you’re not interested, leave and let others enjoy the thing.

                                                        1. 21

                                                          I am a big fan of having a paper notebook and a nice, hefty, metal pen. The ability to rapidly intermix text, drawings, and sketches is underrated.

                                                          EDIT: For the record, I really like Machine Era pens. Solid metal and made in the USA, with easily refillable ink cartridges.

                                                          1. 4

                                                            After trying multiple systems on my laptop or smartphone, I always fall back to my notebooks and a foutain pen. The only thing that I miss is a way to easily record some url or reference. I thought about creating my own url shortener or find a mini printer to print sticker with QR code.

                                                            Intermixing different kinds of inputs (text,drawings,sketches,ddiagrams) is the really what I miss the most when I tried any numeric system.

                                                            1. 1

                                                              I recently had the same idea about a link shortener and so I made one! It doesn’t have much in the way of documentation but it was literally a two hour project and it’s only 50 lines of Go so I think you should be able to get it running really quickly. It uses autoincrementing numbers so the links are always very short and easy to write down (also spell out to someone, remember etc.) I hope you find it useful! Here’s the repo: https://github.com/k2l8m11n2/s

                                                              1. 1

                                                                That’s nice ! What kind of input method do you use? Sending HTTP request via a web interface or CLI? I will definitely look at it longer, thanks!

                                                                1. 1

                                                                  The interface is the simplest one I could think of: you GET (or just enter in your browser) https://shortener.example.com/https://some-cool-link.example.net/fun-link-stuff and you get back a number (starting with 1) that you use like so: https://shortener.example.com/1 which redirects you to https://some-cool-link.example.net/fun-link-stuff! I hope this example was clear enough, feel free to ask if you have any questions.

                                                            2. 4

                                                              If you like hefty metal pens, but European ones, I cannot recommend enough Caran d’Ache: https://www.carandache.com/us/en/ballpoint-pen/849-popline-metallic-black-ballpoint-pen-with-holder-p-10214.htm

                                                              This kind of pen can go a long way.

                                                              1. 6

                                                                So once upon a time I spoke French reasonably well and I was trying to translate “Caran d’Ache” and now I have a headache. Turns out it’s actually a French-ish spelling of a Russian version of a Turkish word.

                                                                1. 4

                                                                  Yes! Even for native French speakers, it feels very French, except Caran doesn’t mean anything (Ache could be a city or whatever).

                                                                  Fore those wondering the meaning:

                                                                  Caran d’Ache means pencil in Russian and has its roots in the Turkish word “kara-tash” which means black stone, in reference to graphite.

                                                                  https://www.carandache.com/us/en/content/ch/fr/la_maison/landing/la_maison_-_histoire.cfm

                                                                  1. 7

                                                                    Caran d’Ache means pencil in Russian and has its roots in the Turkish word “kara-tash” which means black stone, in reference to graphite.

                                                                    Interestingly, I come from a country where fountain pen are mandatory in school. We speak arabic, and everyone called the fountain pen “cartouch”, which means bullet or cartridge. It’s also funny because the cartridge really looks like a bullet. There’s also a close relation with lead. I thought it was an anglicism but now I’m learning it might actually comes from the ottoman era.
                                                                    Language is fun.

                                                                    1. 1

                                                                      Interestingly enough, in French cartridge is also called “cartouche” which is very similar!

                                                                      I’ve tried to find more on the source of the work, but the best I could find was:

                                                                      Borrowed from Italian cartuccia, a diminutive of carta, from Latin charta, from Ancient Greek χάρτης (khártēs) — https://en.wiktionary.org/wiki/cartouche

                                                                      Which is related to the paper that was used for cartridges (in firearms).

                                                                      I wonder what’s the link with pens beside the ink cartridge…

                                                                    2. 2

                                                                      A “Crayon of ash” perhaps?

                                                                    3. 2

                                                                      Oh, right. Карандаш. But it means pencil, so it’s a little bit weird. Does French pronunciation has anything to do with the Russian one? :D

                                                                      1. 2

                                                                        I decided to leam the Cyrillic alphabet a while back because I noticed there are a lot of shared/borrowed French words in Russian and I was going on a visit to Russia. It was really handy. I know a little French, and no Russian, but I could actually read a lot of words on signs. I got the notion from ресторан = restaurant.

                                                                  2. 4

                                                                    I like rotring pens.

                                                                    1. 1

                                                                      Have you ever had a problem with them leaking? My partner uses those, as the line quality is beautiful but after a while, every one she has had has started to leak and needs to be cleaned out.

                                                                      1. 1

                                                                        No, I haven’t had trouble with mine leaking. I mostly use the ball point pen though. Nothing fancy.

                                                                    2. 3

                                                                      In some previous variant of a similar thread, one fellow lobster got me addicted to discbound notebooks [1] [2] [3]. I heartily recommend checking them out for anyone using paper for work notes. They’re an absolutely ingenious invention, I’m surprised they’re not better known and more popular. I mean, I don’t guarantee they’ll fix all your life problems and smooth your wrinkles, but they have many benefits with not many flaws, and I think everyone should know they exist, so that they can choose them as a tool at will.

                                                                      1. 1

                                                                        What type of paper do you use? Ruled? Grid? Some of my physicist coworkers use a dotted grid-style that I’ve been thinking of trying out

                                                                        1. 4

                                                                          I use a dot-grid notebook for a daily bullet journal and all my notes. I can’t go without some horizontal true north or else I start to slant everything downwards, haha. I recommend the Leuchtturm1917 or the Rhodia Dot Web notebooks if you’re curious.

                                                                          1. 1

                                                                            I’ve been using ruled Moleskine notebooks also with my variant of bullet journal. I also have the same slanting problem, but I think dots would be sufficient. I’ll check those out, thanks!

                                                                            1. 2

                                                                              I found out that dotted paper is the more versatile and my newer notebooks all have some. For example, I can easily draw a chess board when I am working on my chess or write straight or diagram almost properly without any rulers when needed.

                                                                              I have some grieves with the quality of paper is my moleskine that vary so much between notebooks especially with foutain pen ink. Some bleeds too easily, some feathers ans some are perfect with the same ink, foutain pen and nib.

                                                                          2. 2

                                                                            I prefer lined since I write more than I draw and I’m not good at writing on unruled or dotted paper.

                                                                        1. 5

                                                                          As always, excellent work. Great job Andreas (and, obviously, all contributors)!

                                                                          1. 6

                                                                            Hey thanks Glaeqen! I’m so proud of all the contributors and the great work they’ve been putting in. And of course, immediately after posting the video I thought of many more things to show.. :)

                                                                          1. 9
                                                                            Video unavailable
                                                                            This video is no longer available due to a copyright claim by Microsoft Corporation.
                                                                            
                                                                            1. 3

                                                                              That’s peculiar. How come?

                                                                            1. 1

                                                                              I’m wondering if anything there can help developers of projects like ReactOS.

                                                                              1. 16

                                                                                NO! Nononono.

                                                                                Please, for any well-meaning people, if you’ve looked at this do not contaminate the ReactOS folks.

                                                                                My understanding is they work very hard to have clean reversing efforts, and that exposure to something like this–even a whiff–would taint that work in perhaps legally-significant ways.

                                                                                1. 2

                                                                                  Well, of course I didn’t mean: copy as much as you can. But maybe there’re some parts of the system which were really tricky to figure out. Like side-effects caused by bugs in original Windows which ended up being features. Obviously I didn’t want to get ReactOS devs into trouble :(

                                                                                  1. 4

                                                                                    No, of course not–I didn’t mean to imply you did.

                                                                                    I just feel for those folks because screening new devs just got a lot harder.

                                                                                  2. 2

                                                                                    I believe they have had this problem already.

                                                                                    1. 1

                                                                                      I’m curious, do you have insight into how APIs are tested by the ReactOS team? Is everything done clean-room using specs, or do they run React on a network with Windows machines to test things like workgroups and Active Directory? I would assume that falls into fair use, but I’m no expert.

                                                                                  1. 6

                                                                                    I opened my mouth in shock at the “static_cast<decltype(x)>(x) should be a no-op but it isn’t” paragraph. C++ is… C++ is fuckin’ metal, is what it is

                                                                                    1. 4

                                                                                      It reminds me of Scott Meyers’ remark regarding, for example, six (sic!) sets of rules of type deduction in C++.

                                                                                    1. 2

                                                                                      No really, I promise this isn’t spam! This project is about owning a computer that is simple enough that you could audit it yourself!

                                                                                      Check out this snippet from the first update:

                                                                                      Even though the full source code for the Linux kernel and Firefox is published, nobody has the time to personally review every release for potential security problems; we simply trust that others have done a good job, because we have no other choice. Precursor rolls the clock back to the early 2000’s, when mobile computers were powerful enough to be useful for single tasks, while simple enough that individuals or small teams could build them from scratch.

                                                                                      1. 3

                                                                                        If it had a cell modem capable of voice and SMS, I’d buy it just on the basis of its form factor. I miss my old Nokia QWERTY phones.

                                                                                        1. 2

                                                                                          Well, Nokia still produces their classic lineup :D

                                                                                          1. 2

                                                                                            Mine are still fine, hardware-wise, and there are still plenty of used ones out there in decent shape. But the software…? I’m slightly embarrassed by the effort I put into trying to get a Symbian (S40 or S60) dev environment set up on a Windows 7 Pro VM, just so I could keep these old friends on software life support. Did a similar thing for my Blackberries, with similarly scant success. There are more fun dead-end closed technologies to bang one’s head against.

                                                                                            I had in mind something more like this similar effort. Who knows, maybe it could be the Linux to bunnie’s “Betrusted” HURD.

                                                                                        2. 1

                                                                                          Super cool project! Thanks for posting.

                                                                                        1. 2

                                                                                          Woah. This whole situation is nasty. I hope that Zig project will recover from this mess.

                                                                                          1. 1

                                                                                            I’ve already said that on Reddit but: Polish variant of the survey is messed up; picking “I use Rust” redirects to the page with questions regarding “Why am I not using Rust”. TBF, I’m surprised that survey is multilingual instead of just plain English.

                                                                                            1. 1

                                                                                              Better than commenting on Reddit or here (although it’s possible someone will see it) would be to contact the community team using the information here.

                                                                                              1. 3

                                                                                                You’re right; my laziness is becoming too apparent.

                                                                                            1. 1

                                                                                              I think I misunderstand the concept of inheritance/subtyping in Julia. It still behaves more like a functional sum type than good ol’ OO-like inheritance. I didn’t really get the comparison to Rust’s trait based polymorphism which feels much more OO than what Julia offers.

                                                                                              1. 3

                                                                                                Julia isn’t really a conventional OO language. It deliberately doesn’t offer a lot in the way of inheritance: you can only subtype one abstract type in each new type (so you inherit no structure; no fields. There’s been a fairly recent change to allow methods to be defined on abstract types, so you can inherit those implementations, but I don’t know how much that is used).

                                                                                                The Big Idea in Julia is “multiple dispatch”, which is what enables the greet functions to work, and the lack of it is why there is no direct equivalent in “single dispatch” languages like Java or C#, as you spelled out below.

                                                                                                A nice introduction to why Julia developers think multiple dispatch is useful is the talk Unreasonable Effectiveness of Multiple Dispatch. I’ve watched the JuliaCon 2019 version, there’s also a slightly longer version given a few months later.

                                                                                                1. 1

                                                                                                  There’s been a fairly recent change to allow methods to be defined on abstract types, so you can inherit those implementations, but I don’t know how much that is used

                                                                                                  This bit of my reply is wrong. We’ve been able to define methods on abstract types for a long time, but the convention is not to assume anything about the structure (fields) of the inputs (abstract types have no fields, and the method will be used for any subtype that does not have a more specific method). The recent change is to allow abstract types to be used as functors, which isn’t really relevant to this discussion.

                                                                                                2. 2

                                                                                                  I don’t know any Julia, but I do know a lot of Rust. From what’s in this article, Julia’s system feels a lot more like OO to me. It’s sort of uncomfortable to use trait objects in Rust, because (imo) they fundamentally run counter to usual Rust paradigms. I would say trait objects are probably the “most OO-like” way of doing this in Rust, but they’re really not idiomatic, especially in this example.

                                                                                                  1. 4

                                                                                                    I’m aware of the fact that Rust discourages OO - I think it’s a good thing. And trait objects are closest thing to OO available. I just don’t see OO-ness in Julia examples; probably thanks to lack of knowledge & experience.

                                                                                                    greet(self::Polarian, other::Player) = println("Hi!")
                                                                                                    greet(self::Polarian, other::Solarian) = println("Your star doesn't even consist of three separate stars? Pathetic!")
                                                                                                    

                                                                                                    AFAIU, you need to implement 4*4 => 16 of these methods for each self player type and for each other player type. For me this look almost like having a sum type match statement split across different method definitions. What does OO have to do with this? Foundation of polymorphism is the unnecessity of knowing which subtype came in as a parameter.

                                                                                                    What would be the equivalent in Java or C#?

                                                                                                    interface Player {
                                                                                                    	public string homestar();
                                                                                                    	public void greet<T>(T player) where T : Solarian;
                                                                                                    	public void greet<T>(T player) where T : Polarian; // error
                                                                                                    	public void greet<T>(T player) where T : Centurian; // error
                                                                                                    }
                                                                                                    

                                                                                                    Unless you want to extract type information via reflection in single greet(Player player) method but then you’re moving more towards matching sum type than OO.

                                                                                                    Well, maybe Julia is making use of some other variant of inheritance/polymorphism that I’m not knowledgeable about. Or I just plainly misunderstood the whole example.

                                                                                                    1. 2

                                                                                                      Ah, I see your point. It seems like a mismatch between which strategy is most sensible in each language, because in Rust using enums, you run into the same issue of having to write 16 different implementations, as hinted at in the article:

                                                                                                      impl PlayerClass {
                                                                                                          fn greet(&self, other: &PlayerClass) {
                                                                                                              use PlayerClass::*;
                                                                                                              match (self, other) {
                                                                                                                  (Cent(_), Pol(_)) => println!("Hello, fellow three-star-systemer!"),
                                                                                                                  ...
                                                                                                              };
                                                                                                          }
                                                                                                      }
                                                                                                      
                                                                                                      1. 2

                                                                                                        AFAIU, you need to implement 4*4 => 16 of these methods for each self player type and for each other player type.

                                                                                                        That’s where inheritance comes in: you can define a method (== function variant) for the more general type(s) to cover all the bases, and define further methods as desired for specialized combinations of argument types. Here’s some code that handles any possible player combination, and has some special behaviour for Centaurians. Does that help, perhaps?

                                                                                                        function greet(x::Player, y::Player)
                                                                                                          println("Greetings, fellow wanderer")
                                                                                                        end
                                                                                                        
                                                                                                        function greet(self::Centaurian, other::Player)   # the name 'self' has no special meaning to Julia
                                                                                                          println("Greetings from the two-star system!")
                                                                                                        end
                                                                                                        
                                                                                                        function greet(x::Centaurian, y:: Centaurian)
                                                                                                            println("Greetings, fellow mind-worm.")
                                                                                                        end
                                                                                                        

                                                                                                        For further reading, you may be interested in Lyndon White’s blog post JuliaLang: The Ingredients for a Composable Programming Language on way that open classes, duck typing, and run-time (or JIT-time) method dispatch are together creating a very composable ecosystem in Julia.

                                                                                                        Or if you’re interested in language details, here are the Julia docs:

                                                                                                        The Julia manual on types:

                                                                                                        Julia’s type system is dynamic, but gains some of the advantages of static type systems by making it possible to indicate that certain values are of specific types. This can be of great assistance in generating efficient code, but even more significantly, it allows method dispatch on the types of function arguments to be deeply integrated with the language. Method dispatch is explored in detail in Methods, but is rooted in the type system presented here.

                                                                                                        The Julia manual on methods:

                                                                                                        To facilitate using many different implementations of the same concept smoothly, functions need not be defined all at once, but can rather be defined piecewise by providing specific behaviors for certain combinations of argument types and counts. A definition of one possible behavior for a function is called a method.

                                                                                                        1. 1

                                                                                                          I see. Thanks for the explanation. To be fair, it still reminds me of pattern matching. I think my greatest complaint regarding this article is that Julia’s inheritance model differs from what reader might be used to and it should be stressed more.

                                                                                                      2. 1

                                                                                                        What would be an idiomatic way of writing the toy example in Rust?

                                                                                                        1. 1

                                                                                                          I think strategy 1b and 2, from the article, are reasonably idiomatic examples.

                                                                                                      3. 2

                                                                                                        Fun fact: the post’s original title was ‘Sum types in Julia and Rust’, but somebody objected that that was not technically correct, and suggested the term ‘optionality’ instead. I like the original title better, personally.

                                                                                                        Julia does not consider itself OO, so you got that right; but of course, the word ‘inheritance’ exists outside OO. In Julia, type inheritance is used for function dispatching. It means:

                                                                                                        • “If somebody calls transpose(x)
                                                                                                        • … and x has type SymmetricMatrix <: SquareMatrix <: Matrix (read A <: B as “A inherits from B”) …
                                                                                                        • … then these are the possible applicable functions variants, in order of specificity …
                                                                                                          • transpose(m::SymmetricMatrix)
                                                                                                          • transpose(m::SquareMatrix)
                                                                                                          • transpose(m::Matrix)
                                                                                                          • transpose(m)
                                                                                                        • … so dispatch to the most specific function variant that is defined.”
                                                                                                      1. 3

                                                                                                        Yees! Support for monitors with different refresh rates! Really cool.