HNHacker News
TopNewBestAskShowJobs

i336_

1,323 karma · joined July 25, 2015

submissionscomments
i336_··on Alleged Foxconn insiders leaked details about Apple’s forthcoming devices
From this subthread: https://www.reddit.com/r/apple/comments/6ezhwm/iama_foxconn_...

>> You are giving away evidence about you and your mates identities !

> Apple knows about us already. We had a visit earlier today. I'm legal counsel, what we are doing is legal, however frowned upon.

I am really curious how that works out.

Could this also point to a fragmented Apple that wants to share (perhaps to refine last-minute details?) but can't due to embargoes?

i336_··on An answer to the “Sell Me This Pen” interview challange
This archive link retains the images and formatting properly
i336_··on IBM 5110 PALM (Put All Logic in Microcode) CPU from 1978
The Xerox Alto had a custom CPU that used microcode extensively - the CPU actually did most system management tasks like re-blitting the entire screen for every new frame and managing disk I/O, and only when it wasn't handling these scheduled tasks did it execute an "emulation" task that actually executed arbitrary code.

More info: http://www.righto.com/2016/09/xerox-alto-restoration-day-5-s...

Start of story (the part 1 link is not easy to find): http://www.righto.com/2016/06/restoring-y-combinators-xerox-...

i336_··on Users report parallel compiling is causing segfault on Ryzen Linux
Thanks so much for this answer, I just learned a lot.

> There is no guarantee that the attempt to measure or detect faults won't hide them...

I got completely stuck on this in my original ponderings. I totally didn't think of sprinkling instrumentation instructions into the code and seeing if the bug still fired. If it did, the approach you described would certainly work very well (and, indeed, you describe it being widely used).

Major TIL with the address-based tracing hardware idea. That's an awesome approach, to do it that way... wow. :)

Building something like this would actually be a really cool challenge in designing a really fast piece of hardware. Considering the kind of access speed needed, though (particularly with the memory bus approach)... would a custom ASIC be required? :/ Or could I get away with using a (perhaps decent/pricey) FPGA?

I say this because it would be awesome to make something like this inexpensively available for people to put in their workstations. I can totally see a device like this also having some fast, nonvolatile* memory-mapped storage for things like infinite logging, as well. For example, the way Linux handles crashes is to kexec into a new kernel that hopefully fishes the log out of RAM and saves it. Very clunky. This approach also does not handle early kernel bringup - or even BIOS/EFI bringup, the libreboot folks would probably love something like this.

(*By "fast, nonvolatile" I mean something that writes straight to a large DDR-backed buffer and is then quickly yanked onto something like an NVMe disk.)

i336_··on Ask HN: Books you wish you had read earlier?
I definitely agree with you there.

Often when I feel certain ways, I don't have reference points to mentally articulate how I'm feeling - if I even have the ability to consciously distinguish the feeling and highlight it. That shuts down a lot of internal dialog and analysis before it has the chance to take place.

When I'm anxious, my thinking is clouded across the board, which makes this weakness all the more apparent.

I wonder if there are any books out there that specifically help to instil an understanding of the nuances in emotional processing.

i336_··on Rewrite Linux Kernel in Rust?
That's a fair point.

I don't quite follow why speed needs to be sacrificed to get predictable performance though.

And I don't know about writing a (whole new?!) Rust compiler (!) - if the current Rust compiler wouldn't be a good fit for this purpose, well, I definitely don't have the resources to anything about that, considering the unbelievable amount of attention to detail and wrangling that's gone into getting rustc to where it is today.

i336_··on Rewrite Linux Kernel in Rust?
Huh, interesting.

Apparently there are 35 rows in the table at http://www.felixcloutier.com/x86/MOV.html (according to Chrome and `$0.childElementCount`). I only discovered gcc.godbolt.org links to documentation via context menu just the other day!

Regarding the PDF... ouch. Wonder if any executable obfuscators have tried that approach :P (and I also wonder what sort of overhead it has.)

i336_··on Ask HN: Books you wish you had read earlier?
Thanks so much, this is now on my todo list :)

I found someone uploaded all of the videos to YouTube!

Unfortunately I don't have the disk space to download them at this exact moment (been saving for several months for a couple new disks, not quite there yet) so I've base64-encoded the following YouTube playlist URL to heighten the chances the videos stay up til I can grab them (both to archive them and also because I download videos to watch them - old computer).

data:text/plain;base64,aHR0cHM6Ly93d3cueW91dHViZS5jb20vcGxheWxpc3Q/bGlzdD1QTFcxcDdMZkhNTW5ERVQxcjh2Ymo4a1FENHNndXM1dnFZCg==

I also found https://www.youtube.com/channel/UCojOYrwehhFpaJfYG3DziHA/vid..., which has some related videos (that I think were placed on YouTube explicitly).

i336_··on Rewrite Linux Kernel in Rust?
I agree.

Writing in Rust might make the iteration/development process itself a little easier, I'll give it that.

I also like the idea about creating a system that does its best to isolate components and create a trustworthy environment. I'd probably pull the enforcement into the kernel though - not quite SELinux/grsecurity/AppArmor, more a system that completely isolates everything.

Kind of like the direction Linux is going with containerization, but developed that way from the start.

i336_··on Rewrite Linux Kernel in Rust?
QNX is also realtime.

In order to provide realtime guarantees that cover small latencies, you need infrastructure that generates as few instructions as possible. (If you have lots of instructions you can hit targets of a hundreds of microseconds since you can just wait. Start inching toward nanoseconds, though, and the scheduler's own execution will get in the way unless it's crazy compact.)

The reason I mention this is that QNX runs on a variety of embedded devices (http://qnx.symmetry.com.au/ has an interesting list, universal remotes particularly jumped out at me) which are traditionally quite slow.

What's Rust like in terms of generating code that's consistently compact?

i336_··on Rewrite Linux Kernel in Rust?
You're referring to microkernel/nanokernel architectures.

Linus famously shunned Andrew Tanenbaum's MINIX kernel design and argued in favor of a monolithic kernel, where buggy printer drivers live in the same memory space and have the same elevated privileges as the code that manages the kernel's secure crypto key ring.

Linus is also noted in this thread as not being interested in security issues.

I do agree with you about Rust not solving the hardware problem.

i336_··on Rewrite Linux Kernel in Rust?
What.

When did `mov` get 96 different instructions?

i336_··on Users report parallel compiling is causing segfault on Ryzen Linux
Direct permalink: https://www.reddit.com/r/programming/comments/6f08mb/compili...

Couldn't find the comment with that link for some reason - thanks for mentioning the username, had to get it from their account page :)

i336_··on Users report parallel compiling is causing segfault on Ryzen Linux
Computer science-y question.

Initially this question was going to be "can we log executed instructions" but I rapidly realized that not even DDR5 could keep up with such a logging system - it would slow things down too much and likely mask the bug (not to mention the TBs of space that would be needed).

Rethinking a bit, my 2nd take is to see if it's possible to somehow repeatedly synthesize workloads from (presumably smaller, more manageable amounts of) seed data.

One of the users in the AMD forum thread (I don't seem to be able to get a permalink) mentions that they're experiencing gcc crashes on Ubuntu inside VMWare on Win10! This means that the bug fits inside two kernels' preemptation/task scheduling and a hypervisor! Interesting.

What stumps me is that some users are experiencing gcc segfaults, while others are getting faults in `sh`.

...yeah this has me stumped. CPUs are so fast, and we have no idea where the problem is.

EDIT: This comment is interesting: https://www.reddit.com/r/programming/comments/6f08mb/compili...

i336_··on Ask HN: Books you wish you had read earlier?
Woops, that was unintentional.

Although... now I think about it... when I'm anxious (I have reasonably mild but fairly broadly scoped anxiety), I can become more emotional/instinctive/reactive to things, and my ability to reason can be greatly impacted as well.

So I do think there is some indirect correlation, in practice.

i336_··on Ask HN: Books you wish you had read earlier?
Some people are born communicators and find interaction with others completely intuitive.

Others are born with a brain more ready to understand math, or writing screenplays, or software engineering, or business management - and bumble their way through communication, getting a lot wrong, not knowing where the lines are between their successes and failures, and generally having a miserable time.

Books like these define specific scopes to focus on as worth investing time and energy in, with the promise that understanding in these areas will definitely bring reward, as unintuitive as this may seem [to these people].

I wouldn't mind similar ones that explain learning how to learn, on a related note.

i336_··on Ask HN: Who is hiring? (June 2017)
If you remember this tech, read this next line:

When you make an account at https://www.houndify.com/ the first thing you see is a microphone-enabled textbox you can type or talk into and play with.

--

A couple things for SoundHound to consider adding to the to-implement list:

A) "What is the temperature in the south-right-most delineation of the country north of me": "Didn't get that!"

B) "When will it next be 25C": "Didn't get that"

(I was trying to match the complexity of the voice demo... sorry)

C):

Me: "What is the temperature in celcius":

SH: Got it right

Me: "What about in fahrenheit"

SH: Got it right (I checked)

Me: "What about the town 15km northeast"

SH: "It is 76 °F in Borgou Department, Benin."

Me: ...WAT. I'm in [the suburbs of] Sydney, Australia. :P

That's mildly scary. :P

i336_··on Perl 5.26.0 released
Very very interesting thoughts, thanks very much for this comment. Would +10 if I could.

The article was an excellent read too.

I've noticed that a lot of people around the 18-25 demographic (and some outside that range) have mental health issues that (among other catastrophes) cause detrimental effects to emotional development. I was thankfully able to get off this train myself using alternative therapies about ten years ago, but one of the things I observed about myself was a tendency to hone in on one specific idea present in something I was thinking about and then redefine what I was focusing on on the basis of and in terms of that idea, in many situations irreversibly discarding any other possible interpretations. I essentially didn't have the capacity to wield concepts that required careful balance between a series of discrete ideas.

I wonder a lot about how much of the noise margin present in current research and work is caused by related developmental issues.

i336_··on How to lose $8k worth of Bitcoin in 15 minutes with Verizon and Coinbase.com
DOH.

I was going based on the thinking that the full email string would need to be known in order for it to be changed. My brain's a bit foggy right now so I can't properly think it through.

Ouch, that makes things a bit harder... but thanks for letting me know.

i336_··on The “rare write” mechanism
Oh of course - interrupts. Right. Which is what [I now understand] preeemptible means; system interrupts can intercept normal execution and cause the kernel to go do something else for a minute.

Thanks so much for explaining the read-write conditions too, I now understand this perfectly.

Thanks for the recommendation about the LWN subscription, I'll file that away as a serious consideration. For the meantime, I'm curious - does the subscriber-only content go free after a certain period, or do certain articles remain subscriber-only?

i336_··on The “rare write” mechanism
> Cook's implementation contains architecture-specific code that relies on CPU features on x86 and ARM that selectively enable and disable write access to areas of memory. Thus, the data write routines cannot be preemptible, as interrupting the kernel after it enables writing on read-only memory would result in leaving a window of vulnerability open.

Question from someone woefully lacking in kernel knowledge: what does it mean that

- these routines are not preemptible, and

- interrupting the kernel in this scenario would leave it vulnerable

?

i336_··on How to lose $8k worth of Bitcoin in 15 minutes with Verizon and Coinbase.com
The thing is, Verizon's not killing anybody by this disaster. Upper management there probably still sees cryptocurrencies as a fad toy. I'm being pragmatic.

Here is an open idea that I have long wondered about. If you think this would work, you are welcome to have it and turn it into a startup (it could work as a free service, it could work on a subscription).

Make a duress system that allows people to open a fast-loading webpage or app, scroll down to Gmail, and hit "Fight!". Then they'd scroll to Coinbase and click/tap the button there too.

This service would then immediately log into your account repeatedly and change your password, along with your recovery email address and other information that, if changed, would make logging in a hassle (such as your security recovery questions). It does this as many times a second as possible, for I'm not sure how long.

My thinking is that "wat, 42 password resets in 18 seconds" is probably going to freak most well-designed services out, which will then hopefully lock your account... possibly saving it.

Better yet (I just realized), the app could lock your account, if the service allows it, after resetting your password.

--

The way I envisage the site/app working is that, you input your account details (your actual password) into a locked tome with a passphrase. When disaster strikes you unlock the tome, perhaps with your fingerprint. The reason for this is that service APIs might not universally provide enough access to "do good", if you will, and there's also the consideration that the site might be up but the API might be down (a bit like Verizon being closed!).

Also, about changing the email, gmail allows you to do things like youraddress+alias@gmail.com, so the app could simply change the email to things like youraddress+98ea6e4f216f2fb4b69fff9b3a44842c38686ca685f3f55dc48c5d3fb1107be4@gmail.com, or variants that won't freak gmail out if they have alarms on that sort of behavior.

i336_··on Perl 5.26.0 released
Oh. That's unfortunate. Thanks very much for the headsup.

I wouldn't mind learning more about this, perhaps via email (as an alternative to public discussion that might(?) start a flamewar).

i336_··on Compiler Optimizations are Awesome
Okay.

My question was along the lines of "is this a sane default or am I wandering into a minefield," your answer is pretty much what I was looking for.

> Some of the current optimizations are so advanced and specific for each particular bit of code that it might not good to generalize from those output.

If only it were possible for the compiler to concisely describe its "workings-out". I imagine compilers can generate trace information, but it's probably pages long.

> I remember ICC generating different (but similar) code for each Intel CPU generation. I suppose it has to do with the decoder limitation (4-1-1-1, 4-2, 2-2, etc.) and exhausting execution port usage...

That's amazing. Definitely keeping that in mind, thanks!

i336_··on Perl 5.26.0 released
Wow, interesting. The language has type coercion, and makes full use of it. I likey :D

Thanks for the example too!

i336_··on Perl 5.26.0 released
I see what you mean.

POSIX was basically a committee ratifying things that a bunch of systems people had come up with. So it gets to the point, it's reasonably concise, and there's little noise to wade through to do most things.

Java was slowly designed by committee, taking inspiration from other languages.

I just thought of something. Maybe it's relevant.

IBM said "let make something totally different with this 8086 system, let's make everything open and not lock it down." Apple said "let's do something different with the Macintosh, let's enforce absolute control over the hardware and software so we can perfectly unify them."

Maybe Sun got fed up with SunOS and said "let's make a language and runtime that's totally different - something so different that it resists influence by platform architecture."

i336_··on Perl 5.26.0 released
Oooh, I see. Nice!
i336_··on Perl 5.26.0 released
It's sad you're being downvoted. I've found similar sentiment elsewhere, and I'm interested to learn more.

stableperl (http://blog.schmorp.de/2015-06-06-a-stable-perl.html) is a fork of perl 5.22 with a couple of tiny reversions that re-enable access to some internal state required by certain CPAN modules.

The author talks in other blog posts (http://blog.schmorp.de/2016-12-29-griefing-the-perl-api.html, http://blog.schmorp.de/2015-11-12-tidbits-why-coro-crashes-o..., http://blog.schmorp.de/2015-12-15-tidbits-cgipm-a-data-point...) about the decline of Perl's cohesion.

It's sad to see.

--

EDIT: And now I'm being downvoted.

I have no problem with Perl, I watched the Perl 6 presentation when it was released with great interest.

Perl remains on my list of languages to learn (I know, I know...). It's up there. And that's why I said I was sad to see datapoints like the one I linked. I want Perl to keep going strong, and I hope it lasts another 20 years. I guess I added this comment because I wanted to find out if there was anything I could do.

i336_··on Perl 5.26.0 released
Yes, "stableperl" maintains a small number of backported bugfixes to Perl 5.22: http://blog.schmorp.de/2015-06-06-a-stable-perl.html

The author cites a couple of issues as the motivation behind the release.

i336_··on Perl 5.26.0 released
What do you mean by Perl functions being modeled after POSIX functions?

My only points of reference are POSIX being a UNIX system specification which defines both a C language reference and system userspace specification. I also have a vague notion of POSIX specifying the fundamental behavior of shells.

I'm just not quite sure which point of reference to apply.

← PreviousPage 2 of 34Next →