Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
higherhalf
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
higherhalf
9mo ago
Thanks, I really should've looked deeper than that.
2.
▲
by
higherhalf
9mo ago
clock_gettime() goes through vDSO, avoiding a context switch. It shows up on the flamegraph as well.
3.
▲
by
higherhalf
1y ago
Thanks, I looked it up and it's indeed quite ugly, and my shebang isn't portable. A little saddened that even 'env -S' didn't make it to POSIX.
4.
▲
by
higherhalf
1y ago
Seems a little complicated when you can do: //usr/bin/env rustc "$0" && ./config "$@"; exit Or //usr/bin/env rustc --edition 2024 "$0" &&
5.
▲
by
higherhalf
1y ago
> It doesn't allow you to import `std::iter::Iterator::collect` on its own. It's an associated function, and needs to be qualified. You probably noticed, but it should become a thing in RFC 3591: https://github.com&#
6.
▲
by
higherhalf
2y ago
What makes this a "systems programming language", especially since it has "no pointers or references"?
7.
▲
by
higherhalf
3y ago
It's not due to a move to AI-enhanced workflows. The article speculates that it's caused by companies wanting to develop AI-related products, moving some workforce and culling the unwilling, just like my employer.
8.
▲
Eyra Does the Impossible
(blog.sunfishcode.online)
3 points
by
higherhalf
3y ago
|
1 comments
9.
▲
by
higherhalf
3y ago
This can be done even simpler: global _start _start: jmp next string: db `Hello World!\n` len: equ $ - string next: mov ecx, string mov edx, len mov ebx, 1 mov eax, 4 int 80h mo
10.
▲
by
higherhalf
3y ago
Yes. Kind of. AMD processors have Upper Address Ignore (UAI) with 7 bits of ancillary data, for Intel there is Linear Address Masking (LAM) with 6 or 15 bits [1]. The latter has made it into Linux after some initial resistance [2]. [1]: ht
11.
▲
by
higherhalf
3y ago
They mention git worktrees in the next paragraph.
12.
▲
by
higherhalf
3y ago
It's a joke, as some Rust projects used to repetitively claim to be "memory safe & blazing fast", thus becoming a tongue-in-cheek phrase. I also anticipated language to be Rust, but it would be way too comical. https:&#x
13.
▲
by
higherhalf
3y ago
> But rust absolutely does not have any C/C++ compatibilty besides [..] > In zig you _can_ actually start with a c codebase and rewrite it file by file in zig and you _can_ include c headers in your zig files verbatim. Both of t
14.
▲
by
higherhalf
3y ago
Excited for threads, sockets, futexes, but not excited for fork, signals and setjmp. They didn't include POSIX stuff like shared memory, select(2), unix sockets, and had to draw a line somewhere. Why include error-prone cruft?
15.
▲
by
higherhalf
3y ago
There's also JSON5 https://json5.org
16.
▲
by
higherhalf
3y ago
There's something mildly charming about fixes to ed(1) in software released today. > Fixed ed(1) to print bytes read/written and the ? prompt to stdout, not stderr.
17.
▲
by
higherhalf
4y ago
This fits as a "list of links by topic": https://github.com/rust-embedded/awesome-embedded-rust
18.
▲
by
higherhalf
4y ago
> tmux show-environment > [..] > -WINDOWIDkj Consequence of using Vim to edit blog posts? It should be, according to author's dotfiles :-P Or maybe using tmux, because I also press kj to determine what pane I'm on sometim
19.
▲
by
higherhalf
4y ago
For me, it was the "I Am Graphics And So Can You" [1] series, where author progresses from the similar concepts up to a working renderer for DOOM 3, linked in the intro of this article [2]. [1]: https://www.fasterthan.l
20.
▲
by
higherhalf
4y ago
> [..] in kernel mode while retaining the ability to compare how the very same usermode bits run on the Linux kernel as well. That's a unique feature in the realm of educational kernels. There's also Kerla: https://g
21.
▲
by
higherhalf
4y ago
I'm latching onto a non-main argument to be pedantic, but I'd like to mention that Rust is fine for _non-embedded_ kernel development too, in my experience. As you're likely aware, Rust for embedded sucks when there's no
22.
▲
by
higherhalf
5y ago
Speaking of significantly faster linkers, I personally use mold[1], including when writing in Rust. [1]: https://github.com/rui314/mold
23.
▲
by
higherhalf
5y ago
I was wondering if memfd_secret [1] could be a part of a solution to this problem. Sounds like it. Of course, it'd require a recent kernel version, which is an obstacle. [1] https://lwn.net/Articles/865256/
24.
▲
by
higherhalf
5y ago
I fail to see a contradiction.
25.
▲
by
higherhalf
5y ago
The color legend and some basic help instructions are coming.
26.
▲
by
higherhalf
5y ago
> I'm surprised this is written in Rust and doesn't use the object crate--did the author do this in part to learn how elf works? No. When I started the project I was expecting to just read data into the ELF structs, in style of
27.
▲
by
higherhalf
5y ago
You can click on their starts and ends (the fields they are referencing) too.
28.
▲
by
higherhalf
5y ago
I sure am! I wish it was more "done" however, right now it's pretty raw.
29.
▲
by
higherhalf
5y ago
> The three nulls in the load segment (between the code and data) are included in [..] Yes, this is a bug. Thanks for reporting it to the issue tracker. > Also, I wish the arrow heads did not opaquely overlap the numbers. Adding opaci
30.
▲
by
higherhalf
5y ago
Hello, author here (I edited the bio on github to show). Don't know how I missed it on HN, must have been the grey link. First I'd like to say that right now this is just the first release, and it's a bit raw so far. That
More ›