Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
jcranmer
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
jcranmer
4d ago
> But for a compiler to target, it's just so painful. It's so different from almost all other ways CPUs work. There's a reason both CPU and compilers prefer to avoid x87 when possible and use regular SIMD (SSE/AVX) in
2.
▲
by
jcranmer
5d ago
> Elsewhere on HA you’ll find my extended rant about how strange it is that we don't have a language that elegantly abstracts computation over threads, SIMD, GPUs etc. Compilers can do this sort of thing now, just not optimally. Aut
3.
▲
by
jcranmer
5d ago
VLCCs are too large to fit through the Suez Canal. I don't know how much of Saudi export is using VLCCs versus Suezmax or smaller tankers, but I've heard that much of the Red Sea oil export is currently going through Bab al-Mandab
4.
▲
by
jcranmer
6d ago
Newspapers are not above printing rumors. See, e.g., Barak Ravid regularly reporting in Axios the impending ceasefire negotiation progress in the Iran War, which largely have failed to come to pass.
5.
▲
by
jcranmer
6d ago
> The advantage of being compatible to other languages is because if we would use a common ABI that many other languages also use: Ada, Go, D, etc. I have looked it up and I can already tell you that Go is not using the ABI you would be
6.
▲
by
jcranmer
7d ago
As a point of evidence in favor of this viewpoint: Multi-dozen car pileups aren't particularly rare, with the common cause for a lot of these being "one car hits an icy patch, hits another car, car behind them tries but fails to s
7.
▲
by
jcranmer
7d ago
An example showing nonequivalency is this: https://godbolt.org/z/PxP4vrfM1 Showing things that are optimized by fully inlining into one function don't actually demonstrate equivalency, because you end up omitting
8.
▲
by
jcranmer
7d ago
Okay, so you accept that nested functions have a different ABI than C++ lambdas. And it looks like you accept that neither ABI is going to change. So long as the two features have different ABIs, they cannot be compatible with one another.
9.
▲
by
jcranmer
7d ago
C++, C#, Java, JavaScript, Rust, Go, Julia, Nim, Zig. I'm shocked that you didn't even pick up Rust, given how frequently I mention it on the WG14 reflector.
10.
▲
by
jcranmer
7d ago
I can write the signature of the generated function of a C++ lambda as a C function. I cannot write the signature of a generated GCC nested function as a C function. If your argument is that ABI doesn't matter, then by all means, propo
11.
▲
by
jcranmer
7d ago
Yes, it does. The lambda still needs to follow the C++ object model in case someone might use it like a regular C++ object. It's possible to change the ABI with escape analysis that proves you know all of the uses of the lambda to chan
12.
▲
by
jcranmer
7d ago
No, there is an amount of legal reality built into it. With copyright and patents, once you obtain the intellectual property, you keep it for the rest of the term no matter what you do. But with trademarks, your actions (or inaction) can ca
13.
▲
by
jcranmer
7d ago
In the nested function, the variable x is passed in edi, and the pointer to the nested stack frame is passed in r10. In the lambda, the variable x is passed in esi, and the 'this' pointer for the lambda is passed in rdi. The funct
14.
▲
by
jcranmer
8d ago
> Generally this is a bit nicer than having explicit lambdas, but I thought the 'best-case' scenario would be if GCC saw into the stack layout of the calling function and could manipulate the calling functions stored stack vari
15.
▲
by
jcranmer
8d ago
The author has been trying to push for the inclusion of nested functions into the C standard, and a lot of the resistance comes from the existence of trampolines and all of the issues that causes. His response to those issues is... to basic
16.
▲
by
jcranmer
9d ago
I have yet to find a graph that shows the market share all the way back to the 1980s, but the market share isn't stagnant--Pepsi's market share has dramatically fallen (about half since 2000), while Coke's share has been pret
17.
▲
by
jcranmer
10d ago
Microsoft did attempt the EEE strategy against Java with Visual J++, but Sun slapped that attempt down and Visual J++ was always a pretty minor footnote. The end result of this effort was C#. I should note that the much more successful EEE
18.
▲
by
jcranmer
13d ago
Private equity gets a bad rap in large part because the stories they're most famous for are the "PE buys a failing company, and the company subsequently finally fails," with the "failing" word conspicuously absent i
19.
▲
by
jcranmer
14d ago
> Template resolution solved that in the past, but C++ today allows auto in so many places that I'm uncertain that it can be done without some flow based support (if constexpr comes to mind). C++ requires determining the type of eve
20.
▲
by
jcranmer
14d ago
Despite its name, NRVO isn't an optimization performed by the optimizer, it's something done by the frontend of the compiler before it generates the code for the optimizer to run on. The frontend is extremely reluctant to do anyth
21.
▲
by
jcranmer
14d ago
I'm sorry, this comment is completely wrong. NRVO does not affect the ABI of the function. It cannot affect the ABI, for whether or not it kicks in depends on the body of the function, and affecting the ABI would make it impossible to
22.
▲
by
jcranmer
15d ago
Job concentration predates the automobile by some amount. The concept of suburbs largely originates from the development of streetcars (very much not free!), although the suburban sprawl associated with US cities nowadays arises from the pr
23.
▲
by
jcranmer
16d ago
One of the things about Turing-completeness is that it is very easy to become accidentally Turing-complete, since the conditions you need for completeness are very weak. (Famously, C++ template instantiation is unintentionally Turing-comple
24.
▲
by
jcranmer
16d ago
I haven't followed the contracts discussion particularly closely, but my understanding of the situation is this: Contracts has the problem that everybody has a slightly different idea of what they want from the feature. What exists tod
25.
▲
by
jcranmer
16d ago
1006 is 90 years before the First Crusade...
26.
▲
by
jcranmer
17d ago
A C++ lambda (as essentially is the case for a Rust lambda as well) is just an unnameable class object with an overloaded call operator, which makes the closure function body itself just a regular member function ABI-wise. You're not c
27.
▲
by
jcranmer
18d ago
A nested function requires an extra parameter for the nested stack pointer, which is passed in a dedicated register on most ABIs. You can't spell this kind of function type in C. To make a C-callable function pointer, the compiler need
28.
▲
by
jcranmer
18d ago
> And at one point the list produces a subtotal of "24510 years, 3 months, and 3 1/2 days" for the 23 kings of the first dynasty of Kish, so the durations are hardly meant to be just some vague large number. Note that the
29.
▲
by
jcranmer
19d ago
The Sumerians used a sexagesimal notation system; the two lengths would be 5.10.0 and 5.50.0 (which together add up to 11.0.0, FWIW), while all of the other king lengths are 8.0.0, 10.0.0, or 12.0.0.
30.
▲
by
jcranmer
19d ago
> Why exactly can a CPU contain RAM electronic circuitry, but RAM can't contain CPU electronic circuitry, if both, at the lowest level, the level of the minaturized transistor, the minaturized electronic circuit, are created from th
More ›