Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
nikic
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
31.
▲
by
nikic
4y ago
FWIW, if you're on a distro with a default GCC toolchain, it's pretty typical to use clang together with libstdc++. E.g. if you use clang on Fedora, you're using libstdc++ by default. You have to explicitly pass -stdlib=libc+
32.
▲
by
nikic
4y ago
> I'm personally not convinced and I wonder why other 10 projects didn't suffer from the same problem? This has a simple answer: The C++ projects in the test set are kimwitu++, Bullet, tramp3d-v4 and 7zip. kimwitu++ is built in
33.
▲
by
nikic
4y ago
Regarding restaurants, I think you generally get pretty good mileage out of Tabelog. A key problem for short-term visits is that highly-rated restaurants (>= 3.7) tend to fall into two categories: Either the restaurant is cheap and has a
34.
▲
by
nikic
4y ago
One problem here is that GCC emits certain warnings as part of the optimizer, which results in many false positives that are essentially impossible for the lay programmer to understand. For example, jump threading might duplicate some code
35.
▲
by
nikic
4y ago
This has no relation to Clang's permissive license. The problem here is generally that nobody has implemented the necessary support, not that they have implemented support in their private forks but did not bother to upstream it. A GPL
36.
▲
by
nikic
4y ago
As far as I know there isn't anything like that for cmovs. The cmov depends on the condition, so it will only be executed once the condition is available. Of course, execution can still continue with instructions that don't need t
37.
▲
by
nikic
4y ago
LLVM recently introduced a SelectOptimize pass, which is used for select -> branch conversion in the presence of PGO information. This should replace the current non-PGO-aware X86 cmov conversion pass. The result of this should be that w
38.
▲
The Opcache Optimizer
(npopov.com)
3 points
by
nikic
4y ago
|
0 comments
39.
▲
by
nikic
4y ago
For reference, here are the C++ support pages for GCC and Clang: https://gcc.gnu.org/projects/cxx-status.html https://clang.llvm.org/cxx_status.html
40.
▲
by
nikic
4y ago
I don't see how the license is relevant here. It's not like companies have already implemented full C++20 support in their local forks and just haven't bothered upstreaming it. But yes, a lot of LLVM users don't care abo
41.
▲
by
nikic
5y ago
This is what I get locally: time php fib.php 42 23s time python3 fib.py 42 1m1s I suspect that you're doing something very wrong, like running PHP with an active debugger or similar. If we're talking in compa
42.
▲
by
nikic
5y ago
It's hard to check whether old opcache bug reports have been resolved, because these issues tend to be non-reproducible. It's quite likely that they are, as opcache is tested much more extensively now than it was a few years ago.
43.
▲
by
nikic
5y ago
The change you have in mind is MemorySSA-based memcpy optimization, which is indeed not enabled in LLVM 12 (but is enabled in Rust).
44.
▲
by
nikic
5y ago
Wow, these release notes are completely useless. Here are some actual highlights of this release: * LLVM no longer assumes forward progress by default. This means it no longer miscompiles infinite loops in non-C++ programming languages. * L
45.
▲
by
nikic
6y ago
FWIW, the two people who are paid to work on PHP (Dmitry and myself) both only work on the PHP implementation and not other parts of the project (infra, websites etc). The infrastructure is maintained entirely by volunteers. I am personally
46.
▲
by
nikic
6y ago
As we don't really know, we went with the worst-case assumption. If it's wrong, then at least it was a nice excuse to update some old infrastructure :)
47.
▲
by
nikic
6y ago
For now I'm only handling people for which I recognize the account or can confirm recent commits.
48.
▲
by
nikic
6y ago
An important factor here is hardware access. Tier 2 targets just produce cross-compilation artifacts, tier 1 targets require actual hardware to run on. For example, a tier 1 macos aarch64 target is impossible until the hardware can be run i
49.
▲
by
nikic
6y ago
That was certainly a concern. When instrumenting PHP to detect where the behavior changes and testing various codebases, I found that this actually happens much more rarely than I would have anticipated in advance. We're talking like 2
50.
▲
by
nikic
6y ago
> I find it really weird that the match expression is strict comparison, but everywhere else it's loose comparison. Don't get me wrong, I prefer strict comparison, and prefer strongly typed languages because of it, I just feel
51.
▲
by
nikic
6y ago
PHP 8 has plenty of breaking changes ( https://github.com/php/php-src/blob/08e6c209550a268500bbdef4... ), mostly in the department of throwing errors more aggressively, and fixing some long-standing "featu
52.
▲
by
nikic
7y ago
SIMD intrinsics are unsafe, because reaching a SIMD intrinsic not supported by the host CPU is undefined behavior (in practice usually SIGILL).
53.
▲
by
nikic
7y ago
Choice of cmov vs branch is pretty tricky because profitability depends on branch probabilities, which are commonly not known. LLVM has an X86 cmov conversion pass that does this based on some cost modeling for loop-carried dependencies, bu
54.
▲
by
nikic
7y ago
If you build LLVM often, use the shared library build (BUILD_SHARED_LIBS=true). Most of the memory usage (and a large part of the time in incremental builds) comes from linking final artifacts if you do not use shared libraries.
55.
▲
by
nikic
8y ago
As usual, things aren't quite that simple. While it certainly can happen that the compiler can pessimize carefully crafted SIMD code by applying undesirable transformations, simply not optimizing intrinsics would lead to other problems
56.
▲
by
nikic
8y ago
Half the point of using SIMD intrinsics rather than embedding assembly is that register allocation and instruction scheduling are performed by the compiler. Using intrinsics certainly does not guarantee that exactly the corresponding instru
57.
▲
by
nikic
8y ago
That sounds more like an implementation issue than a design issue. If you are using UTF-8 actual decoding into Unicode code points is not necessary for most operations and Rust will not do that. It also does not imply that string operations
58.
▲
by
nikic
8y ago
Rust updates LLVM more commonly than LLVM does stable releases, so it has been using a version somewhere between LLVM 6 and LLVM 7 for a while already. I think one of the main areas that improved in LLVM 7 relative to LLVM 6 that Rust cares
59.
▲
by
nikic
8y ago
> Euler was the first person to realize this, afaik. Is there a term to describe these kind of "de-unit-ified" equations? More than once I've found myself needing to reconstruct a proper equation (with correct dimensions a
60.
▲
by
nikic
8y ago
Seeing that `i % len` in https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin... makes me uncomfortable. This is performing a non-constant modulus on every loop iteration, which seems q
More ›