Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
thxg
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
thxg
8mo ago
The original Wordle came with a pre-baked ordered list of 2315 "secret" words, off which the daily secret word was looked up (I think based on local time). The list was right there in the javascript code of the game (alongside the
2.
▲
Exploiting Undefined Behavior in C/C++: A Study on the Performance Impact
(web.ist.utl.pt)
2 points
by
thxg
1y ago
|
0 comments
3.
▲
by
thxg
2y ago
Indeed those are the "big four" solver businesses in the West, and also probably the most reliably-good solvers. But by the time Gurobi withdrew from the benchmarks (a few weeks ago), COpt was handily beating them in the LP benchm
4.
▲
by
thxg
2y ago
Regarding presolve: When they test their solver "with presolve", they use Gurobi 's presolve as a preprocessing step, then run their solver on the output. To be clear, this is perfectly fair, but from the perspective of &quo
5.
▲
by
thxg
2y ago
I agree that their results are impressive. Just to be clear, however: 1. They compare their solver with a 1e-4 error tolerance to Gurobi with 1e-6. This may seem like a detail, but in the context of how typical LPs are formulated, this is a
6.
▲
by
thxg
2y ago
I think it's partially excusable. Most LP solvers target large-scale instances, but instances that still fit in RAM. Think single-digit millions of variables and constraints, maybe a billion nonzeros at most. PDLP is not designed for t
7.
▲
by
thxg
3y ago
The article is very recent (September 2023 [1]), mentions that "rax is used to return integer values" in the SysV ABI (hence implicitly the 64-bit SysV ABI). Also confirmed in this excerpt: > Note that the top 56 bits in rax ar
8.
▲
by
thxg
3y ago
This representation of jagged array is literally the "Compressed Sparse Row" (CSR) format for sparse matrices [1]: - a single array of floats with all the nonzero matrix entries, ordered row-by-row: double values[nnz]; - a
9.
▲
by
thxg
3y ago
Ligatures are an interesting contrast to Julia programmers' habit of using actual (non-Latin) Unicode characters in their code. It seemed to me that the use of Greek letters and symbols is actively encouraged in the Julia documentation
10.
▲
by
thxg
3y ago
MemComputing mainly present themselves as optimizers: Their machine can solve real optimization problems, in practice, today. This is very good because, through that lens, we can skip the BS and go straight to the facts. The evaluation crit
11.
▲
by
thxg
3y ago
The scientific article seems to be open access [1]. Before people draw links to recent large language model breakthroughs: Although they do use techniques from computational linguistics, there are no neural networks involved. This is more l
12.
▲
by
thxg
3y ago
The video link in the article works in Chrome but not Firefox mobile (for some reason I can't comprehend). Working link in case you are interested: https://www.youtube.com/watch?v=ujjkbLZETHs
13.
▲
Notes on Fast Fourier Transforms for Implementers
(fgiesen.wordpress.com)
95 points
by
thxg
3y ago
|
5 comments
14.
▲
by
thxg
4y ago
> The best-known algorithms for NP-complete problems are essentially searching for a solution from all possible answers. The traveling salesman problem on a graph of a few hundred points would take years to run on a supercomputer. This s
15.
▲
by
thxg
4y ago
OP crafts a bmp file in paint, which when renamed to `.bat` runs the command that opens a shell window (cute!). I don't have access to a Windows machine, but isn't it possible to achieve the same by writing `cmd.exe` directly to a
16.
▲
by
thxg
4y ago
> Ah yes, portability. On Linux it can be argued that CLOCK_MONOTONIC_RAW should be used for durations. From the Linux man page: CLOCK_MONOTONIC_RAW (since Linux 2.6.28; Linux-specific) Similar to CLOCK_MONOTONIC,
17.
▲
by
thxg
4y ago
> How does it deal with dust from a household environment? At 5:55 the interviewee claims that the high back pressure allows them to blow the air through IP68 filter material. It seems dust-proofing is one of their marketing points. I do
18.
▲
by
thxg
4y ago
Examples on Compiler Explorer: By default, GCC generates FMA instructions on Haswell and later: https://godbolt.org/z/GKb7G4nW9 but it does not with -std=c99 on the command line: https://godbolt.org/z&#
19.
▲
by
thxg
4y ago
The bug is about two related floating-point concepts: contraction and excess precision. The C and C++ standards mandate that floating-point operations follow the IEEE-754 spec. For example, the result of any elementary operation (+, -, *, &
20.
▲
GCC bug #323 (third oldest unresolved bug) is about to get fixed
(gcc.gnu.org)
10 points
by
thxg
4y ago
|
3 comments
21.
▲
by
thxg
4y ago
Indeed GCC does not enable -ffast-math by default. Unfortunately, -ffast-math and -funsafe-math-optimizations (despite the name) are not the only options that prevent bit-for-bit-reproducible floating point. For example, -ffp-contract=fas
22.
▲
by
thxg
4y ago
> It is pretty crazy imho that gcc defaults to using fma Yes! Different people can make different performance-vs-correctness trade-offs, but I also think reproducible-by-default would be better. Fortunately, specifying a proper standard
23.
▲
by
thxg
4y ago
Yes, and this is not just a theoretical concern: There was an article here [1] in 2021 claiming that Apple M1's FMA implementation had "flaws". There was actually no such flaw. Instead, the author was caught off guard by the
24.
▲
by
thxg
4y ago
This needs a (2004). The article mostly targets the Intel Pentium 4. Many high-level tips still hold true (for example those that could apply to any programming language, like expressing divisions as multiplies), but quite a few things have
25.
▲
by
thxg
4y ago
One slight variation on the getaddrinfo()/freeaddrinfo() approach is what (among many others) GMP [1] and its derivatives do: For every struct or custom type, you systematically get void type_init(type *t, [...]); void type_c
26.
▲
by
thxg
4y ago
> Unfortunately compilers can't emit FMA instructions from regular floating point math without specifying (an equivalent of) `-ffast-math` ... if you specify an ISO language standard (e.g. -std=c99). By default, in GNU mode, gcc wil
27.
▲
by
thxg
4y ago
Background: Floating-point numbers form a finite set. It is thus impossible for them to represent all real numbers. The correct rounding of a real number x is the unique floating point number that is closest to x, according to a user-chos
28.
▲
Core-MATH: a pathway towards mandatory correct rounding in the next IEEE-754 std
(gitlab.inria.fr)
3 points
by
thxg
4y ago
|
1 comments
29.
▲
by
thxg
4y ago
> I would have measured the time directly inside of the Doom allocator Exactly! The author already has all the infra necessary (rdtsc for each call). Measuring time inside the game would be more accurate and simpler. Why did the author d
30.
▲
by
thxg
4y ago
That's a legitimate question. It's just floating-point jargon. Here's what it means: > I’m well aware of banker’s rounding, and rounding up, and round down, and rounding towards zero, and rounding towards signed infinity,
More ›