Readit News logoReadit News
leeter commented on The stack circuitry of the Intel 8087 floating point chip, reverse-engineered   righto.com/2025/12/8087-s... · Posted by u/elpocko
kens · 11 days ago
Having given a zillion interviews, I expect that they weren't looking for the One True Answer, but were interested in seeing if you discussed plausible reasons in an informed way, as well as seeing what areas you focused on (e.g., do you discuss compiler issues or architecture issues). Saying "I dunno" is bad, especially after hints like "what about ..." and spouting complete nonsense is also bad.

(I'm just commenting on interviews in general, and this is in no way a criticism of your response.)

leeter · 11 days ago
I think I said something about the stack efficiency. I was a kid that barely understood out of order execution. Register renaming and the rest was well beyond me. It was also a long time ago, so recollections are fuzzy. But, I do recall is they didn't prompt anything. I suspect the only reason I got the interview is I had done some SSE programming (AVX didn't exist yet, and to give timing context AltiVec was discussed), and they figured if I was curious enough to do that I might not be garbage.

Edit: Jogging my memory I believe they were explicit at the end of the interview they were looking for a Masters candidate. They did say I was on a good path IIRC. It wasn't a bad interview, but I was very clearly not what they were looking for.

leeter commented on The stack circuitry of the Intel 8087 floating point chip, reverse-engineered   righto.com/2025/12/8087-s... · Posted by u/elpocko
leeter · 11 days ago
I remember failing an interview with the optimization team of a large fruit trademarked computer maker because I couldn't explain why the x87 stack was a bad design. TBF they were looking for someone with a masters, not someone just graduating with a BS. But, now I know... honestly, I'm still not 100% sure what they were looking for in an answer. I assume something about register renaming. memory, and cycle efficiency.
leeter commented on Netflix to Acquire Warner Bros   about.netflix.com/en/news... · Posted by u/meetpateltech
bombcar · 15 days ago
It’s only older contracts and studio holdovers that are preventing simultaneous release (which has already been done at times).
leeter · 15 days ago
I believe the Academy Awards and a few other things too also influence this. The rules to be eligible still very much favor legacy studios IIRC. But, with this that may change? Hard to say. I know that quite a few Netflix movies have had theatrical runs at random mom and pop theaters in Cali so they could meet eligibility requirements for the various awards.
leeter commented on FPGA Based IBM-PC-XT   bit-hack.net/2025/11/10/f... · Posted by u/andsoitis
dlcarrier · a month ago
The title is a bit misleading; it's running on an 8088-compatible CPU, and a 1 megabyte SRAM, with the FPGA containing the display adapter and drive controller, as well as the glue logic.
leeter · a month ago
Honestly? I expected this to be talking about the MiSTer project FPGA core[1]. That has been tuned so it's capable of running the AREA5150 demo[2] which is an insane challenge (AFAIK the timings of the v20 break that demo). Not saying this isn't cool, but it's definitely not what I was expecting.

[1] https://github.com/MiSTer-devel/PCXT_MiSTer

[2] https://www.youtube.com/watch?v=tOmcgp99fEk

leeter commented on Fallout from the AWS outage: Smart mattresses go rogue   quasa.io/media/the-strang... · Posted by u/jerlam
julianlam · 2 months ago
We could even go more basic... safe defaults when disconnected should be mandatory.

For example, if I pull the thermostat off my wall, the furnace should drop into a fallback mode that keeps the heat above freezing (I'm in Canada where this is a concern.)

I moved into a new house and did not set up the lawn irrigation system. Despite being disconnected from the cloud service, the system kept running its schedule, when I would have expected it turn off in order to conserve water.

leeter · 2 months ago
I've said for years that any smart thermostat should have a bimetallic backup that controls maximum ranges and acts in the dumbest way possible. Just max temp and min temp for AC and heat. Nothing that should ever be hit... but there nonetheless.
leeter commented on How to stop Linux threads cleanly   mazzo.li/posts/stopping-l... · Posted by u/signa11
manwe150 · 2 months ago
One of my more annoying gotchas on Windows is that despite this advice being very reasonable sounding, the runtime itself (I believe it actually happens in the kernel) essentially calls TerminateThread on all child threads before running global destructors and atexit hooks. Good luck following this advice when the kernel actively fights you when it come time to shutdown
leeter · 2 months ago
So there is a reason that in the C++ spec if a std::thread is still joinable when the destructor is called it calls std::terminate[1]. That reason being exactly this case. If the house is being torn down it's not safe to try to save the curtains[2]. Just let the house get torn down as quickly as possible. If you wanted to save the curtains (e.g. do things on the threads before they exit) you need to do it before the end of main and thus global destructors start getting called.

[1] https://en.cppreference.com/w/cpp/thread/thread/~thread.html

[2] https://devblogs.microsoft.com/oldnewthing/20120105-00/?p=86...

leeter commented on How to stop Linux threads cleanly   mazzo.li/posts/stopping-l... · Posted by u/signa11
leeter · 2 months ago
I'm reminded of Raymond Chen's many many blogs[1][2][3](there are a lot more) on why TerminateThread is a bad idea. Not surprised at all the same is true elsewhere. I will say in my own code this is why I tend to prefer cancellable system calls that are alertable. That way the thread can wake up, check if it needs to die and then GTFO.

[1] https://devblogs.microsoft.com/oldnewthing/20150814-00/?p=91...

[2] https://devblogs.microsoft.com/oldnewthing/20191101-00/?p=10...

[3] https://devblogs.microsoft.com/oldnewthing/20140808-00/?p=29...

there are a lot more, I'm not linking them all here.

leeter commented on Pwning the Nix ecosystem   ptrpa.ws/nixpkgs-actions-... · Posted by u/SuperShibe
woodruffw · 2 months ago
That's a fantastic use case that should be supported discretely!
leeter · 2 months ago
Why github didn't is beyond me. Even if something isn't merge clean doesn't mean linters shouldn't be run. I get not running deployments etc. but not even having the option is pain.
leeter commented on Pwning the Nix ecosystem   ptrpa.ws/nixpkgs-actions-... · Posted by u/SuperShibe
woodruffw · 2 months ago
This is a great example of why `pull_request_target` is fundamentally insecure, and why GitHub should (IMO) probably just remove it outright: conventional wisdom dictates that `pull_request_target` is "safe" as long as branch-controlled code is never executed in the context of the job, but these kinds of argument injections/local file inclusion vectors demonstrate that the vulnerability surface is significantly larger.

At the moment, the only legitimate uses of `pull_request_target` are for things like labeling and auto-commenting on third-party PRs. But there's no reason for these actions to have default write access to the repository; GitHub can and should be able to grant fine-grained or (even better) single-use tokens that enable those exact operations.

(This is why zizmor blanket-flags all use of `pull_request_target` and other dangerous triggers[1]).

[1]: https://docs.zizmor.sh/audits/#dangerous-triggers

leeter · 2 months ago
I don't disagree... but, there is a use case for orgs that don't allow forks. Some tools do their merging outside of github and thus allow for PRs that cannot be clean from a merge perspective. This won't trigger workflows that are pull_request. Because pull_request requires a clean merge. In those cases pull_request_target is literally the only option.

The best move would be for github to have a setting for allowing the automation to run on PRs that don't have clean merges, off by default and intended for use with linters only really. Until that happens though pull_request_target is the only game in town to get around that limitation. Much to my and other SecDevOps engineers sadness.

NOTE: with these external tools you absolutely cannot do the merge manually in github unless you want to break the entire thing. It's a whole heap of not fun.

leeter commented on DXGI debugging: Microsoft put me on a list   slugcat.systems/post/25-0... · Posted by u/todsacerdoti
codedokode · 3 months ago
As I remember, for 10 or 20 years on x86 execution starts at 32-bit address like 0xffff_0000:0000, not 0xffff:0000 which was used in 8086, am I wrong? Stumbled upon this when tried to disassemble BIOS.
leeter · 3 months ago
You are correct, I need to edit my post because they both boot up in unreal mode. The 32bit Segment limit is an unreal mode thing.

u/leeter

KarmaCake day1227August 12, 2016View Original