Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
201984
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
15 ms
·
181.
▲
by
201984
2y ago
In general, can timing attacks on a vulnerable implementation be prevented if sonething else guarantees the operation takes constant time? For example, if I add a sleep after a non-constant-time operation to ensure it always takes 1s, would
182.
▲
by
201984
2y ago
(2022)
183.
▲
by
201984
2y ago
Yeah, what?!
184.
▲
by
201984
2y ago
Very cool! I enjoy seeing people writing asm, and letting us get the most out of our CPUs. I see you already tried what I thought of, which is getting rid of the jump table and making each instruction handler the same size. Do you think tha
185.
▲
by
201984
2y ago
For syscalls, I would have needed to either pull in dependencies or write FFI bindings, and neither of those options are appealing when I could simply write the program in Linux's native language. For the FAM, your example looks like i
186.
▲
by
201984
2y ago
The only dependency is a recent Linux C standard library. What are the missing symbols? On older versions of glibc you do have to add -pthread.
187.
▲
by
201984
2y ago
It is being sorted by the first column, but it also keeps subdirectories with each other. Look at the order of your top-level directories. 3.2G 0B |- .pyenv 3.4G 0B |- .rustup 9.2G 0B |- Work 16G 4.0K |- Downloads 17
188.
▲
by
201984
2y ago
Because (a) I felt like it, (b) it would be more difficult to make raw syscalls in Rust, and (c) I use[1] flexible array members to minimize allocations, whereas Rust support for those quite bad[2]. It doesn't even look possible to all
189.
▲
by
201984
2y ago
Those are single threaded, so they would have kneecapped performance pretty badly. 'du' from coreutils uses them, and you can see the drastic speed difference between that and my program in the README.
190.
▲
by
201984
2y ago
Out of curiosity, I switched it back to fstatat and compared, and found no significant difference. Must've been some other change I made at the time, although I could've sworn this was true. Could be a system update changed someth
191.
▲
by
201984
2y ago
I just saw your edit. You have WAY more stuff under your home directory than I do. I only have ~2.5M inodes on both my laptop drives combined. The difference in the buff/cache output of `free` before and after running `dut` is only 1 G
192.
▲
by
201984
2y ago
I benchmarked against dua while developing, and the results are in the README. Note that dut uses Linux-specific syscalls, so it won't run on MacOS. TL;DR: dut is 3x faster with warm caches, slightly faster on SSD, slightly slower on H
193.
▲
by
201984
2y ago
Done
194.
▲
by
201984
2y ago
Are you referring to the kmem_cache_alloc calls in the profile? If so, that's all in kernel space and there's nothing I can do about it. https://share.firefox.dev/3XT9L7P
195.
▲
by
201984
2y ago
Thanks! What you described is a neat idea, but it's not possible with any degree of accuracy AFAIK. To give you a picture of the problem, calculating the disk usage of a directory requires calling statx(2) on every file in that directo
196.
▲
by
201984
2y ago
io_uring doesn't support the getdents syscall, so there's no way to traverse the filesystem with it. I considered using it for statx(2) to get the disk usage of each file, but decided not to because (a) it would be complicated to
197.
▲
by
201984
2y ago
I haven't run into a situation like that, but if I did, I'd be doing mental math like you. `dut` would only be useful as a (quicker) replacement for `du` for telling you how large the source of a `cp -r` is.
198.
▲
by
201984
2y ago
This isn't an interactive program, so ncdu would be better for interactively going around and freeing up space. If you just want an overview, though, then dut runs much quicker than ncdu and will show large files deep down in subdirect
199.
▲
by
201984
2y ago
As long as it has permissions, it totals up everything under the directory you give it including names that start with a '.'. It won't follow symlinks though.
200.
▲
by
201984
2y ago
I've actually never heard of --reflink, so I had to look it up. `cp` from coreutils uses the FICLONE ioctl to clone the file on btrfs instead of a regular syscall. I don't handle them specifically in dut, so it will total up whate
201.
▲
Show HN: Dut – a fast Linux disk usage calculator
(codeberg.org)
396 points
by
201984
2y ago
|
148 comments
202.
▲
by
201984
2y ago
So hypothetically, if a developer publishes GPL software on Codeberg, and someone uploads it to GitHub, could the original developer file takedowns against the Github copy? I'm curious if Github's ToS make uploading GPL software y
203.
▲
by
201984
2y ago
I've never once had to recompile the kernel on my laptop for any reason. The kernel command line is set in the bios entry, which is somewhat tedious to change, but that's just an efibootmgr command. Initramfs gets rebuilt by pacma
204.
▲
by
201984
2y ago
What's the point of using this over plain EFISTUB? I use it with Arch, and whenever I want to boot to Windows, I just use the BIOS menu. I don't see what benefit a Linux-based bootloader provides.
205.
▲
by
201984
2y ago
Ugh, what a load of garbage. Is paying American salaries for your developers really that expensive? You'd think CEOs wouldn't want to cheap out on the very people that make their business possible. I gotta say, "borderless ta
206.
▲
by
201984
2y ago
Some Cortex-A53s have 16-byte cachelines, which I found out the hard way recently.
207.
▲
by
201984
2y ago
What's the difference between the link in this post ( https://v1.web-check.xyz/ ) and on your Github ( https://web-check.xyz/ )?
208.
▲
by
201984
2y ago
> https://web-check.xyz/check/http%3A%2F%2F127.0.0.1 >City: undefined, undefined, undefined Heh
209.
▲
by
201984
2y ago
However, busses and trains usually only run every 10-20 minutes compared to a road which is going constantly. I can easily see cars on roads having higher throughput.
210.
▲
by
201984
2y ago
Is this a GPT summary? It reads kinda like one
More ›