Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
veddan
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
7 ms
·
1.
▲
by
veddan
5mo ago
I think it should be possible to get rid of the Option tag without introducing any unsafe code by changing index in Gc from u32 to std::num::NonZero<u32>.
2.
▲
by
veddan
9mo ago
For LLMs, I just pulled the latest llama.cpp and built it. Haven't had any issues with it. This was quite recently though, things used be a lot worse as I understand it.
3.
▲
by
veddan
3y ago
In git a branch is a name that points to a commit. When you commit to a branch, you create a new commit and then update the branch to point to the new commit.
4.
▲
by
veddan
3y ago
I think you can do this with <meta name="googlebot-news" content="nosnippet">
5.
▲
by
veddan
3y ago
There's also JSON_ARRAYAGG. https://dev.mysql.com/doc/refman/8.0/en/aggregate-functions....
6.
▲
by
veddan
3y ago
I'm a bit behind on modern PostgreSQL so I might be wrong, but I believe MySQL has better support for what they call "online DDL" (modifying tables without blocking simultaneous queries). Last time I checked, MySQL supported
7.
▲
by
veddan
4y ago
We actually had an accidental back button hijack at a place I used to work at. It was an SPA, where if you navigated to / it would check if you were logged in. If so, you would be redirected (client-side) to /home, otherwise you w
8.
▲
An io_uring-based user-space block driver
(lwn.net)
102 points
by
veddan
4y ago
|
38 comments
9.
▲
by
veddan
5y ago
There was some work done on a RWF_UNCACHED flag a while back, but I'm not sure if it went anywhere. It was supposed to use the page cache if the page is already there, but not add it (or at least not keep it around) if it isn't.
10.
▲
by
veddan
6y ago
The ASS format has some basic animation with the \move command (moving subtitles using linear interpolation) and the \t command (changing various properties of a line with the possibility of quadric interpolation). This takes care of some c
11.
▲
by
veddan
7y ago
bcmp just tells you "equal" or "not equal", while memcmp tells you "lesser", "equal", or "greater". I don't really know, but I suppose it might be possible to make bcmp faster since you
12.
▲
by
veddan
7y ago
We recently got something similar in Sweden too: https://www.spelpaus.se/ It's a blocklist that all licensed gambling companies in Sweden are required to respect. You add yourself to the list for a certain amount of ti
13.
▲
by
veddan
9y ago
4% or 20 million, whichever is greater.
14.
▲
by
veddan
9y ago
<file.txt grep foo | sort
15.
▲
by
veddan
10y ago
There are some methods to get around this. For example, there's an ELF extension called STT_GNU_IFUNC. It allows a symbol to be resolved at load time using a custom resolver function. This avoids the problem of figuring out which code-
16.
▲
by
veddan
10y ago
Reasonably modern versions of GCC will emit various rep instructions in some cases. Some code I just compiled with GCC 6.1.1 had several snippets like this emitted for zeroing with memset: xor eax,eax ... rep stos QWORD PTR es
17.
▲
by
veddan
10y ago
Unless your program is designed to work that way, the fine-grained synchronization that StringBuffer offers over StringBuilder is almost certainly not very useful. And since Java is a memory-safe language, the only meaningful difference bet
18.
▲
by
veddan
10y ago
On Linux you can use hostapd and dhcpd.
19.
▲
by
veddan
11y ago
For many programs it's easy to decide whether they halt or not. int main(void) { for (;;); }
20.
▲
by
veddan
11y ago
I wastes memory too, having multiple copies of the same shared libraries loaded.
21.
▲
by
veddan
11y ago
In C99: #include <stdio.h> int main(void) { (* * & * * * * * & * * * * * * * * * * * * * printf)(&1["C is awesome\n"]-3/2); }
22.
▲
by
veddan
11y ago
Prefix the command with a space and bash won't save it in its history.
23.
▲
by
veddan
11y ago
Oxytocin is not an opioid. You are thinking of Oxycontin.
24.
▲
by
veddan
11y ago
Still, there are cases where fall-through can be useful: int remaining = length % 4; switch (remaining) { case 3: h ^= (data[(length & ~3) + 2] & 0xff) << 16; case 2: h ^= (data[(length & ~3) + 1]
25.
▲
by
veddan
11y ago
Going through a union is the correct way of viewing one type as another. Casting pointers to accomplish this is undefined behaviour (except for char *) and compilers do TBBA (type-based alias analysis) based on the assumption you don't
26.
▲
by
veddan
11y ago
I think that the "expression-style" return looks good for short and "expression-like" function. Good fn inc(a: u32) -> u32 { a + 1 } fn foo(a: u32, b: u32) -> u32 { let x = a + b; a * x } Bad fn
27.
▲
by
veddan
11y ago
I'm guessing he refers to atomics with relaxed memory ordering. That doesn't give much in terms of guarantees beyond atomicity and no "out-of-thin-air" values. I'm not sure of whether this is a data race under Rust&
28.
▲
by
veddan
11y ago
Sure, Rust will continue to evolve. But many changes that happened in the past were on the scale of "Java 10 decides to get rid of classes".
29.
▲
by
veddan
11y ago
Seems like this could be solved by escalating to banning a /64 after multiple bans have been issued.
30.
▲
by
veddan
11y ago
There's some extended discussion of the issue on the wiki[1]. A future full MERGE implementation might have slightly different semantics or performance characteristics than ON CONFLICT (which might also differ from other DBMS). [1] ht
More ›