HNHacker News
TopNewBestAskShowJobs

rmasters

180 karma · joined October 27, 2020

https://github.com/rick-masters https://github.com/ironmeld https://www.linkedin.com/in/rick-masters-46b454/

grick23 at googles email domain

submissionscomments
rmasters··on Pains of building your own billing system
That ruling was overturned on appeal.

https://www.reuters.com/markets/us/citigroup-wins-appeal-ove...

rmasters··on Life on Earth didn’t arise as described in textbooks
I found this video to be quite informative and addresses a relationship between the information incorporated into a chemical process and its function.

Nobel laureate Jack Szostak from University of Chicago delivered the Eyring General Lecture on March 17, 2023 at Arizona State University.

"The Origin of Life: Not as Hard as it Looks?"

https://www.youtube.com/watch?v=ZLzyco3Q_Rg

rmasters··on Common bugs in writing (2021)
This kind of ambiguity is rampant in technical writing. Example: "There are situations where developers do X instead of Y which is the wrong thing to do." Wait, is X wrong or Y?! You go ahead and assume X is wrong and then figure out later they meant Y is wrong or vice versa. Argh!
rmasters··on I’m ChatGPT, and for the love of God please don’t make me do anymore copywriting
If this is a Severance reference, it's doubly hilarious.
rmasters··on EU-wide maximum limit of €10K for cash payments
> Also why not just go 10 days in a row and pull out 1k?

In the US, this could be considered "structuring" to avoid reporting requirements which is a federal crime with a sentence of up to 5 years in prison.

rmasters··on How I survived a year in ‘the hole’ without losing my mind
I'm not the person you asked, but if I rephrase your question to "Then why do some places with low crime have less police?", then the answer just seems to be common sense.
rmasters··on Text Is the Universal Interface
In some encodings? One zero is sufficient for UTF-8.
rmasters··on Seattle police stopped investigating new adult sexual assaults this year
Thank you. This is pretty much the comment that I was going to write but you saved me the time.

There are judges in Seattle that appear to disagree with the notion that serious violent criminals should be punished with serious jail time. However, what I can't figure out is, why doesn't the Seattle Times name the judges that are releasing violent criminals? It's just a nameless "judiciary" or "the judge". Why no interest in holding them accountable?

City Prosecutor Pete Holmes was voted out for not prosecuting but the judges are getting a pass because nobody knows who they are. (Yes I should look this up myself - I've resolved to do something - but the journalists could help.)

rmasters··on About CompuServe
Brings back memories. I was a MS support engineer on CompuServe around 1989. I supported Windows/286 and 386, Excel, and Word for Windows. I posted around 25 to 30 messages a day. I had a partner named Bassam, if I recall correctly. It was just the two of us, and there was a period of time when it was only me.

Many times I wondered "if they only knew MS Windows support on CompuServe relies on one intern working out of a frat house (at the UW)." I used a US Robotics modem running at 300 or 1500 baud without error correction. I had to write my responses in notepad and paste it in due to line noise.

Helping so many people every day was very satisfying and I am still proud of that work.

rmasters··on Show HN: A 3K Posix bootstrap kernel written in hex
This project compliments the stage0 project (featured on the HN front page earlier today) which builds a C compiler using an assembler that is bootstrapped from hex. However, those bootstraps require an existing kernel. You are required to provide your own. I decided, as a challenge, to build a tiny purpose-built x86 32-bit kernel which can run the stage0-posix shells and compilers all the way to the M2-Planet compiler, which is a subset of C. I learned (after starting) that they plan on writing a bootstrap kernel themselves, so I hope this helps in some way. It took three months of very tedious and error-prone work because I avoided, on principle, using an assembler except to check the encoding of individual opcodes. (All jump offsets were hand calculated.) Please see github.com/ironmeld/builder-hex0 for it's history.
rmasters··on Lies we tell ourselves to keep using Golang
I appreciate the extra context. For what it's worth, I was not aware of the previous discussion and I just thought it was an interesting post. (I really don't have any feelings about golang one way or another.)

I can appreciate your point about having limited resources to moderate posts that have a track record of generating big flamewars. But I didn't get the impression from the comments (many being ad-hominem) that the post was flagged for that reason and my use of the word "shameful" was directed at those comments.

rmasters··on Lies we tell ourselves to keep using Golang
Are those issues really so egregious? There is a tremendous amount of content geared towards "informing the reader" and I'd prefer to draw my own conclusions about the author's intent rather than having a censor (who is assuming bad-faith) try to protect me from a rather mild rant (in my opinion).
rmasters··on Lies we tell ourselves to keep using Golang
Flagging this post strikes me as shameful censorship of an unpopular opinion.

You may say it's the snark/anger/frustration that got flagged, but I suspect it would not have been flagged if the topic were different.

Presuming the author is making bad-faith arguments for internet blog points goes against the spirit of HN. I prefer to draw my own conclusions, thank you. I normally expect HN to take the higher ground with calm and reasoned counter arguments of the content but not today I guess.

rmasters··on Writing a simple operating system from scratch (2010) [pdf]
Yeah, I'm avoiding modern interfaces due to my peculiar bootstrapping requirements (e.g. must run on old HW; no SW dependencies). virtio is probably a better choice for anyone trying to build something practical. On the other hand, it looks like using virtio would need a lot more code than accessing the BIOS and I couldn't easily find examples in assembly.
rmasters··on Writing a simple operating system from scratch (2010) [pdf]
From the PDF: "It is true: in our quest to make full use of the CPU, we must abandon all of those helpful routines provided by BIOS. As we will see when we look in more detail at the 32-bit protected mode switch-over, BIOS routines, having been coded to work only in 16-bit real mode, are no longer valid in 32-bit protected mode; indeed, attempting to use them would likely crash the machine.

"So what this means is that a 32-bit operating system must provide its own drivers for all hardware of the machine (e.g. the keybaord, screen, disk drives, mouse, etc). Actually, it is possible for a 32-bit protected mode operating system to switch temporarily back into 16-bit mode whereupon it may utilise BIOS, but this teachnique can be more trouble than it is worth, especially in terms of performance."

--

In the toy 32-bit OS I am currently writing, having easy disk access and text output was more important to me than performance, so I decided to implement this technique to access the disk and screen via the BIOS instead of writing an ATA disk driver.

Although I could not find any minimal yet complete working examples of dropping to 16 bit and later resuming 32 bit mode, I was able to piece it together and write assembly functions called enter_16bit_real and resume_32bit_mode. See https://github.com/ironmeld/builder-hex0/blob/main/builder-h.... Those routines are working well but beware the project is a volatile work in progress and is coded in hex for bootstrapping reasons.

rmasters··on Satoshi leaked his Los Angeles IP address (2016)
I worked with Nick's brother Paul for many years at F5. Several years ago I asked him if Nick was Satoshi and he said Nick denied being Satoshi and Paul also added that it wouldn't make sense because "He still owes me money!". Pretty funny. But I guess he could have fooled his own brother.
rmasters··on What Is Fuzz Testing?
The link below is a relatively simple example of differential fuzzing between implementations in different programming languages using AFL. It works by reading and writing to a second process it spawns and aborting on differences. Before writing this, I could not find any working examples of this technique, although I'm sure they are out there, somewhere.

https://github.com/ironmeld/doubleback/blob/main/src/c/tests...

rmasters··on Improving large monorepo performance on GitHub
If you are willing to adapt to a different structure and workflow, you can filter the scope of git down dramatically with sparse checkouts (as @WorldMaker also mentioned).

https://github.blog/2020-01-17-bring-your-monorepo-down-to-s...

rmasters··on Applicative Parsing
Tree-sitter uses JS for grammars and I'm sure there are others:

https://tree-sitter.github.io/tree-sitter/creating-parsers#t...

rmasters··on Who Said Nobody Read Isaac Newton?
I have a similar impression as you but I also found this quote illuminating:

"I never read the Pricipia Mathematica; almost no one has. You know it's not really traditional in Physics to go back and read the original papers of the great people before us. I'll confess I've never read Einstein's original papers on Relativity even though I've written a textbook on Relativity. In Physics the idea is it's the ideas matter, not their original presentation."

"Newton's original presentation of this stuff in the Principia - number one, it was in Latin (laughs). It took a while for it to be translated into English and number two, he was apparently afraid of using all of the new mathematical techniques he invented. So he tried very hard to only use existing mathematical techniques so people would believe him, so people would accept it right away.

"Subrahmanyan Chandrasekhar, who is a great 20th century astrophysicist, actually wrote a version of the Principia Mathematica for the common reader. If you ever want to know what Newton was actually up to in the in his great masterwork the Principia I would advise not buying either the original Latin or English but buying Chandrasekhar's explanation of what was going on."

- Sean Carroll The Biggest Ideas in The Universe pt 2 @15:55 (youtube)

rmasters··on How to Find Focus
I agree that loss of focus can put someone in the danger zone of looking for other options without really resolving the underlying problem.

However, I think the article is implying that deep thinking about your values and interests when you step back can help keep you from switching focus for shallow reasons. Perhaps you re-engage with a renewed sense of purpose. However, if you do switch after deep thinking, you'll hopefully be more resistant to further randomization.

rmasters··on Parsing Algorithms
I think its great. IELR is a straightforward optimization that just makes sense to use when building an LR family parser.

You can think of LALR(1) as just taking an LR(1) state graph and merging together nodes that are compatible (in that they are essentially the same parsing state, but differ in which "lookahead" tokens are valid). A grammar is consider to be LALR(1) if combining states in this way still results in a correct parser.

IELR, which is derived from David Pager's PGM and Lane Tracing "Minimal LR" techniques from the 1970s, applies a stricter compatibility test for nodes. This check usually allows a large majority of merges while rejecting the ones that will lead to parsing errors. In this way, a more sophisticated grammar, all the way up to LR(1) can still be processed correctly using a table size much closer to what you get with LALR.

You essentially get the best of both worlds and its tragic that this fairly simple technique is so obscure. I believe the reason for the obscurity of these techniques is that Pager's PGM and lane tracing papers are extremely terse, somewhat confusing, and lacking in sufficient detail in certain areas. For example, the PGM paper on p.256 crucially notes that successors may need to be "regenerated as a distinct state" without further explanation. (Until his protege Chen provided some pseudo-code 34 years later in his dissertation of 2009. BTW, I have verified that the Wisent and Menhir parsers and others implement PGM correctly, if anyone is looking for actual details.)

Note that there is some additional time and complexity required to detect conflicts and regenerate/split nodes and so the benefits or IELR are not entirely free.

More obscurely, it should be noted that IELR suffers the same problem as LALR in that combining states can introduce conflicts between tokens when context aware lexing [Nawrocki 1991] is being utilized. (BTW, Tree Sitter uses context aware lexing but its not very common otherwise - yacc/bison doesn't AFAIK). Suddenly tokens are eligible for matching alongside other tokens that normally would not be matched together. Unless your tokens are globally conflict-free or you've got a priority scheme that always resolves conflicts properly (but then you wouldn't need context-aware-lexing would you?), you'll start matching tokens that shouldn't be matched in a particular parsing state. There are ways to avoid those conflics as well (see PSLR - also from IELR author Joel Denny) but it is a lot more work. Even if you avoid conflicts, invalid content can match tokens that shouldn't be matched which complicates error reporting because you get a confusing parse error instead of a correct tokenization error. So this is one case where the full LR(1) may be preferred over IELR.

But I can't think of a convincing argument for preferring LALR over IELR.