HNHacker News
TopNewBestAskShowJobs

theincredulousk

446 karma · joined July 22, 2016

submissionscomments
theincredulousk··on Rationale: Or why am I bothering to rewrite nanomsg?
In retrospect this is probably true. Should have left it at the comment about QNX - the rest is honestly irrelevant.

Apologies to Garret for assassinating his character based on a single blog post.

theincredulousk··on Rationale: Or why am I bothering to rewrite nanomsg?
The immediate side-effects of any program and the processor are only to read, manipulate, and write data. Data is stored in a finite memory that all have states 0 and 1.

Every single thing that can be represented or manipulated by a program is just an array of 0s and 1s that are read, manipulated, and written. The values in the array are the state, and everything a program is capable of doing only moves it to a different state of memory.

Every single program ever written is a state machine, so is every microchip for that matter.

https://en.wikipedia.org/wiki/Turing_machine

theincredulousk··on Rationale: Or why am I bothering to rewrite nanomsg?
Once someone makes this that works properly with arbitrary C/C++ and threads/interrupts, I honestly believe it will be a revolution in productivity.

As mentioned below, others (esp. IDA) make it so glaringly obvious that how you were working before was way harder than it had to be.

theincredulousk··on Rationale: Or why am I bothering to rewrite nanomsg?
Of course no offense, but the author does seem to be somewhere shortly after the first peak on the Dunning-Kruger curve. Even truly embedded systems with an OS like QNX don't "melt" with 100 threads. Obviously he "doesn't know what he doesn't know" in expertise terms, and blamed a mistake on the operating systems.

That combined with the other extremely dubious reasoning - e.g. (see my other very long comment) how replacing state machines with callback functions is a good idea (tm). There is also the comment RE: "how bad Windows APIs are" and how IO-completion ports are '_actually_ pretty nice'. This is the kind of comment someone makes if their worried the "real" coders won't take them seriously if they use anything but Arch Linux.

Makes you think he is reasoning about things that he just isn't an expert in yet (embedded systems, operating system APIs, long-term framework design). Nothing wrong with that though - everyone has to build up experience somehow - but maybe a bit early to be on the front page of HN.

theincredulousk··on Rationale: Or why am I bothering to rewrite nanomsg?
This is at least partially ill-advised. Comes off as an expertly done, but same old refactoring project that could be titled "I didn't understand this and would understand it better if I were designed based on my personal preferences". This is reinforced by the probably approaching 1 that nobody needs another "six of one half dozen of the other" message queue framework, and alluding to an belief that the C++ library is somehow too bloated for embedded environments. While that was at a time true, no reasonably modern embedded system that requires multi-threading to "100s" of threads, or uses 100s of live sockets for message queue I/O, has to avoid C++ for being too heavy. This is just ZeroMQ alternative #N - not anything objectively better, and certainly not "nano" for embedded systems. The "one true messaging framework" is a unicorn - everyone feels like it should exist but nobody can make it.

But for many cases this is not necessary. A simple callback mechanism would be far better, with the FDs available only as an option for code that needs them. This is the approach that we have taken with nng.

Replacing a state machine with callbacks... something something something you're gonna have a bad time. Esp. considering the gripes are about readability, following control flow, and race conditions. Callbacks are objectively worse for all of those things. Control flow is hard to read in state machine frameworks because the primary flow is dictated by something like "nextState(thisState, action)", so you can't follow it with code lookup.

The problem here (and almost always) is lack of documentation or visualization (or picking the wrong abstraction level for the formally defined states). The beauty is that the definition is almost by default naturally easy to parse (tables of states in a header file, etc.). It takes some extra effort, it is a one shot to write something that generates graphviz state chars or something similar from the state table definition. You could write a custom dot syntax generator from a C-style table definition in what, three hours? Doxygen already does this for much more complicated stuff. Googling reveals this is nothing new: https://gist.github.com/freqlabs/24d88ad8e687891c970a69f16f1...

All that said, State Machines are (currently) the one true abstraction for a given program because that is what a computer is, and every program is, to begin with. If you're not using them explicitly, it just means you have a poorly defined/documented state machine. Maybe someday there will be a better model of computing, or a better way to model programs. For now, the human brain isn't getting any better at keeping track of computer programs, and anything more than single-threaded functional-style code is almost certainly not any "absolute" improvement in readability.

I firmly believe that visualization has become necessary due to complexity, and it is past time to embrace it. There is some stigma that visualization is for fakers - "real programmers only use a bare text editor" - or that it is for children learning programming, or non-engineering folks that need pictures because they're dumb. To be a bit hyperbolic, if we want any chance at keeping up with "the machines", we're going to need a better general-purpose, more workable abstraction than text files. There is no more canonical example of this than the issues pointed out here - state machines are the right abstraction for complex systems, but complex state machines are incredibly difficult to follow in source code.

theincredulousk··on Giving you more characters
Called it

https://news.ycombinator.com/item?id=13759157

Should have charged people for it though. They need the money.

theincredulousk··on 50+ Segmentation Faults per Hour: Continuing to Stress Ryzen
This seems like a shill article because black box testing makes almost no sense in this situation. These are seg faults not hardware lockups. Maybe get a kernel dump and gdb? You know, debugging.
theincredulousk··on Prodigy: A new tool for radically efficient machine teaching
Guess the radical efficiency didn't carry over to their web server
theincredulousk··on Machine-checked explicit state: An arrow in the heart of complex web apps
uhh so is this supposed to be web devs meet state machines?

I see they've invented a new name to label the innovation as such.

theincredulousk··on E-cigarettes ‘Potentially as Harmful as Tobacco Cigarettes’
This seems like a shill study because someone unhappy with cigarettes declining sales helped fund development of their neat-o 3D printed testing device. It is already a red-flag that they say "3D printed"... they didn't 3D print the (likely) massively expensive electro-optical sensing device, from what I can tell they 3D printed the little sample slides that go in, and that is what costs a dollar. I'm sure that will save some shekels but otherwise...

Saying "e-cigarettes" is nonsensical. There are 1000s of varieties of vaporizers and liquids. I'd wager if you take some bright, sketchy liquid from the corner vape shop and combine it with a $10 generic imported vaporizer there is going to be some significant deviation with impurities/toxins relative to e.g. JUUL or other products sold by a company that frankly has something to lose if they get sued.

As far as I understand, most of the unexpected chemicals are coming from vaporization or reactions based on the flavorings that were never designed for that. Or vaporizers that are poorly constructed and burn glue/adhesives/etc from the device as well as the liquid. So again you'd want to focus on those individual components or chemicals, and it makes no sense to generalize "e-cigarettes" by analysis of any one (for better or worse).

Also, not intuitively buying without far more evidence that vaporizing glycol/glycerine, nicotine, and water shares a rough equivalence in DNA damage potential to the raw combustion products of unfiltered cigarettes. There are some 7000 chemicals in tobacco smoke, and the list of the known carcinogens is over a page long on Wikipedia... https://en.wikipedia.org/wiki/List_of_cigarette_smoke_carcin...

theincredulousk··on WannaCry – New Variants Detected
Why would they keep releasing it, and release it in the first place, with such a simple kill-switch. Doesn't make much sense.

Reminds me of the Archer episode where Cyril plants the computer virus and was going to be the hero by "fixing" it.

theincredulousk··on Hitting Absolute Zero Has Been Declared Mathematically Impossible
The fact that it is technically possible to reach temperatures lower than absolute zero because of quirks in the math really makes this "declaration" less than meaningless to me.

Math is a description of the physical universe not a definition. As another commented, what is mathematically possible and impossible is entirely our own invention.

theincredulousk··on Ask HN: How would you turn Twitter around?
Maybe holding this arbitrary line in the sand as if it were a commandment is why Twitter apparently needs to be "turned around". 280 characters isn't now extensive prose - it isn't fundamentally changing anything. It has been 10+ years and they are still losing a tremendous amount of money, I think it is time to lose the idealism if there is a win-win for users and revenue.

At some point "condensed" thought just means reduced quality of communication. If some users want to say more, let them pay a dollar. I doubt users would be rattled to their core because some people can put two tweets in one.

Bottom line, users don't care about what Twitter's agenda is regarding character limit. Nobody decided to use Twitter because they were excited about a 140 character limit, they use it in spite of the limit. Twitter should be focusing on what the "in spite of" reasons are, because those are the reasons that define the intrinsic value of their service, not the character limit.

I believe most people use Twitter because it gives them the attention of an audience. If you can acquire the same size (or redundant, since most are on multiple platforms) audience elsewhere, then what reason is left for a user to tolerate any annoyance or quirk of the service?

theincredulousk··on The Bull Case for Snapchat
If Snapchat fits then I think it means an endless stream of next-Snapchats will also fit. All of these things are 6 of one/half dozen of the other. The limit is people arbitrarily swapping messaging apps like phone cases based on mood.
theincredulousk··on The Bull Case for Snapchat
The 50th messaging app with a friends list is the same technological advance as the iPod?
theincredulousk··on The Bull Case for Snapchat
Personally I'm not a chronic pessimist, but my view on Snapchat is the same as Twitter, and look at what is happening with them.

They are only worth their Market Cap in the sense that investors literally bought-in that much because of a hypothetical upside based on scale. What happened when they tried to sell the company? The realization sets in that the company just isn't worth that much money, nor can anyone foresee how it could be in the near future.

It is a self-sustaining situation with these companies. Nobody wants to write off that big of a loss, so the valuation is sustained.

Many others are sustained on the inflated belief that the market for Ad views is adjusted for the prevelance of fraud. How many times has it been shown that click, view and user bots are used in staggering numbers. The companies making all the money have little incentive to correct this. But of course Ads clearly work in many situations. I'm just saying these bloated valuations based on ad revenue have not been adjusted for the fraud reckoning. Google struck gold because the underlying utility of the search engine is so unquestionably powerful and ubiquitously necessary to the idea of the internet that it guarantees a truly awe-inspiring user base. The value proposition of getting that service for free makes viewing Ads a second thought - it is a reasonable deal for the user.

What do people need from Snapchat that will keep them there? Sharing pictures and text messages is rapidly, and I mean rapidly, approaching a commodity service on par with landline telephones.

Anyways, the blanket optimists are subject to the same odds. If you believe everything is going to succeed, inevitably you will be correct. Everyone has confirmation bias.

theincredulousk··on Thousands of deadly U.S. military airstrikes have gone unreported
Are you sure there is nothing difficult about that? When you're reasoning against your own hospitals, and your own children? When a nightmare of a human being keeps his own children near him as human shields?

If I'm to understand correctly, "We" are there to blow up hospitals and terrorize children, but also create propaganda to protect civilians from feeling bad?

Can you describe to me this large, tens of thousands at least, group of people that murders children on purpose but also cares about the feelings of all civilians? Specifically, without reinforcing the point that you'd be responding based on a tiny fraction of the intelligence that goes into these decisions.

theincredulousk··on The Bull Case for Snapchat
Sorry, tuned out at $100 Billion. This is doing keg-stands of your own Kool-Aid.

If you think Snapchat has the same macroeconomic value to the world as Intel, Cisco, or McDonald's... Then you've lost the ability to evaluate a technology business.

I'm not sure whether to accuse this of being shill or to systematically prove how flaky the argument is. The fact is that it doesn't save photos is as much lack of a feature as it is character. The users of this app know how to take a screenshot... It's the ICQ of a different 3 years worth of teenagers that will get stomped by the next messaging app that is different from the one other people used for the past 3 years.

Snapchat is valuable because of demographics. Unfortunately those demographics grow up quickly, and the ones that replace them will rebelliously reject what preceded them just like teenagers have done for the last 50 years.

The fact that they are worth $18bn now is nothing but a prime example of the times. Mind you I know the company I'm in. VCs invest based on their bet and the reason that valuation sticks is more marketing than it is reality.

Snapchat just isn't that valuable to the world.

theincredulousk··on Bias in the ER
I'm just glad to read a story about smart people thinking about a hard problem.

It's an excerpt from a book - I think the point is to get interested in the question not draw a conclusion ;)

theincredulousk··on Thousands of deadly U.S. military airstrikes have gone unreported
Is there any realistic expectation that there be a news story for every airstrike?

I'm not saying we're always the "good guys", but every airstrike looks bad without any context. We never get all of the intelligence that goes into ordering an airstrike, so how are we supposed to make the same judgements about collateral damage, effect, etc.? How many other airstrikes happen flawlessly?

Aside from hindsight being 20/20, it is naive to assume that the public is capable of reviewing complex, difficult decisions about military action based on anecdotal information in a 1-page news article.

theincredulousk··on RegExr: Learn, Build, and Test RegEx
second regex101. Been my goto for several years.
theincredulousk··on [dead]
Yes that's true, I can certainly imagine it as a possibility in the future.

Specifically for motorcycles, as many experienced riders would say, sport bikes especially can hardly even be used on public roads anyways. My old bike red-lined 1st gear at ~96mph, i.e. there isn't a public road where it is legal to "use" the first of 6 gears. They're made for a track. On the other hand, RE: safety, in the overwhelming majority of cases the safety risk on a motorcycle is to the rider not the other drivers on the road. Motorcycle accidents where the rider was at fault and a vehicle occupant was killed are likely less probable than death via choking on a bagel. So a outlawing human drivers in this case sounds more like taking away an individual's choice rather than controlling any legitimate risk to public safety.

As for cars, I agree that it will probably at some point make sense to separate autonomous cars from human drivers. There is not much way around the fact that you can kill other people easily in a car, and that a great number of people would justifiably want to opt-out of that risk if they had the option. Someone's enjoyment of driving won't be nearly enough to justify otherwise that when the time comes.

theincredulousk··on [dead]
I was pointing out that the author's logic is hyperbolic and naive, making it seem as if statistically minimizing risk is the only thing that matters to anyone. To your point, we also "pay" ~88,000 lives per year to allow our society to satisfy its recreational alcohol consumption needs, but that is what society has chosen.

I do agree it is a problem that we share roads, and many people don't take the risks seriously. People's poor judgement, e.g. using apps on their phone while going 70mph in a 3,000+ lb vehicle is disturbing. Motorcyclists experience things like this vividly, and often daily. Maybe fully automated cars are the only answer to that though, because relying on improving everyone's judgement, or policing it, might be the least realistic solution conceived (for anything).

Of course we want to make driving safer, and in that way autonomous capabilities are a ground breaking safety feature. Other cars probably need to be safer too, since we are a very, very long way away from even a simple majority of autonomous cars. Maybe one day we'll see the "end game" of zero-ish road fatalities, but that relatively distant possibility is not a reason to essentially outlaw driving. Keep in mind autonomous cars are also very expensive, and will be for some time. If the "outlaw" part came a bit too early, it could end up looking a lot like "People too poor to buy and maintain a brand-new car are not allowed to drive on public roads".

There are plenty more reasonable steps to be taken before that, e.g. since teenager drivers account for a disproportionate number of accidents/injuries, so maybe we don't need high-school kids driving. Or, maybe we need to require extra licensing for a housewife that wants to pilot a 5,500lb Escalade at highway speeds. Maybe people should go to jail instead of paying a tiny fine if they are caught using Social Media while driving.

The list goes on, without copping to the naive, even juvenile, conclusion that outlawing human drivers is logical because autonomous cars are safer.

theincredulousk··on [dead]
If it’s true that algorithms are statistically better than drivers then we shouldn’t let people to drive."

It is difficult to decide if this statement is idealistic, naive, or written by an algorithm. I love motorcycles, as do many millions of other people, despite the obvious safety risks. This may come as a shock, but minimizing risk isn't the sole goal of everyone's life on earth. By this logic, we shouldn't "let" people play sports because purpose built robots would be statistically better.

But there are still a lot of people that love to drive. This can be a fun recreational activity but we just don’t need those people on the road.

No, what we don't "need" are Autonomous Cars. We need food, water, and shelter. We want autonomous cars the same as any other modern technology. And by the way, marginalizing the interests of millions of people with language like "those people" typically does not go over well. And whom is "we"? Because it sounds like Rick's spaceship: https://www.youtube.com/watch?v=m0PuqSMB8uU

(There is also a highly relevant Futurama episode that satirizes this topic: https://en.wikipedia.org/wiki/2-D_Blacktop.)

theincredulousk··on The Money is Gone
The "To be continued..." format was not a great choice for narrative like this. So much content missing that it could be considered click-bait.
theincredulousk··on Ask HN: What three books impacted your career the most?
+1 on the Pragmatic Programmer.

For anyone that is ready to stop consuming themselves with all things esoteric and start writing generally good code by default.

If more devs followed the relatively simple patterns and practices in this book the phrase "legacy code" might not be a curse-word.

← PreviousPage 5 of 5