llvm/llvm-project
View on GitHub ↗ ★ 41,296 LLVM
The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
319 mentions on Hacker News by 202 people: 30 stories, 289 comments · first 2019-03-20 · latest 2026-10-31
20082026
-
It seems like someone did: https://github.com/llvm/llvm-project/issues/96971 . However the performance implications of this was not well explored there
comment by saagarjha · 2026-10-31 · in Switch Lowering in GCC -
…the issue #pragma omp parallel for for (uint32_t i = 0; i < n; i += 2) { // counts PAST 13! https://github.com/llvm/llvm-project/issues/70687
comment by nh2 · 2026-10-31 · in Switch Lowering in GCC -
Well, let me google that for you. https://github.com/llvm/llvm-project/pulls?q=is%3Apr+state%3... https://github.com/llvm/llvm-project/pulls?q=is%3Apr+state%3... https://github.com/llvm/llvm-project/pulls?q=is%3Apr+state%3...
comment by _aavaa_ · 2026-10-16 · in I'm Fucking Done with Slop -
…two big ones to start. But I have a feeling that an arbitrarily large list won't change your mind. https://github.com/llvm/llvm-project https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...
comment by _aavaa_ · 2026-10-16 · in I'm Fucking Done with Slop -
As one example, LLVM still routinely does dumb stuff like this: https://github.com/llvm/llvm-project/issues/53348 Regarding ABI, calee-saved registers also often result in useless data shuffling and prevent the compiler from using them for…
comment by newpavlov · 2026-10-05 · in Beating the compiler (2024) -
…cppcoreguidelines-init-variables + cppcoreguidelines-pro-type-member-init would have flagged it. 1: https://github.com/llvm/llvm-project/commit/905a88b923433eb8...
comment by jeffbee · 2026-10-05 · in Type Safe Generic Data Structures in C (2025) -
…(albeit with worse port distribution and latency), but you get to have a canonical NaN!) Hit upon https://github.com/llvm/llvm-project/issues/217376 while playing around with proper minimumnum, failing to SMT-verify whatever version of…
comment by dzaima · 2026-09-25 · in Fearless SIMD v1.0 -
…think you understand how insane optimizations in the face of UB can be. Just go look at this issue: https://github.com/llvm/llvm-project/issues/174844?utm_sourc...
comment by titzer · 2026-09-22 · in AMD's random number generator can't generate a 0? -
…and the code achieves 18. I suspect most custom implementations would do worse than this. [0] https://github.com/llvm/llvm-project/blob/165c472d65cd62eb33... [1] https://godbolt.org/z/rGGq8aG38
comment by AlotOfReading · 2026-07-22 · in Everyone should know SIMD -
…are rare enough that it compiles giant projects like Linux and Chromium without detectable issues. https://github.com/llvm/llvm-project/issues Yea, sure, but there's waay more than Linux or Chromium
comment by tester756 · 2026-07-22 · in Claude Is Not a Compiler -
there's been some forward movement on doing this via an appropriate intrinsic in LLVM https://github.com/llvm/llvm-project/pull/166702 note that this isn't the only "trick" needed for constant-time programming though. Indexing an array…
comment by mswphd · 2026-07-08 · in NoiseLang: Where N = 5 is a Dirac delta -
I filed the bug: https://github.com/llvm/llvm-project/issues/204883
comment by xena · 2026-06-19 · in I hate compilers -
…official but there's been plenty of fixes of the years moving stuff to be deterministic, e.g https://github.com/llvm/llvm-project/commit/cdbde3aacc1260a7... The internal programming guide also says which collections to use for…
comment by ammar2 · 2026-06-18 · in I hate compilers -
cvise. Here is a link to a mini tutorial I wrote for a user in an LLVM issue: https://github.com/llvm/llvm-project/issues/108827#issuecomm...
comment by amatria · 2026-06-18 · in I hate compilers -
https://github.com/llvm/llvm-project/issues/45725 Are you familiar with pointer provenance ? This gets very deep, very fast, so if you don't know and don't want to know I can't help you, but if you do want to know try maybe:…
comment by tialaramex · 2026-06-16 · in How memory safety CVEs differ between Rust and C/C++ -
…in C https://dl.acm.org/doi/10.1145/3735950.3735953 - A merged C++ patch to the LLVM compiler: https://github.com/llvm/llvm-project/pull/70845 For more context, please visit my website: https://oestoleary.com . I'm excited to connect!
comment by leonardool · 2026-06-02 · in Ask HN: Who wants to be hired? (June 2026) -
…right now (to be released in 0.3.x, soon), and some changes just made their way into LLVM as well: https://github.com/llvm/llvm-project/pull/175800
comment by hardwaresofton · 2026-05-27 · in Theseus: Translating Win32 to WASM -
…is "can potentially not be evaluated"). [2] Both GCC and Clang still get this wrong in 2026: https://github.com/llvm/llvm-project/issues/190858
comment by fuhsnn · 2026-05-25 · in C constructs that still don't work in C++ -
…I can make the vector length a constant in my code that can change based on the compile target. https://github.com/llvm/llvm-project/issues/113422 https://github.com/llvm/llvm-project/issues/172857
comment by Validark · 2026-05-17 · in C++26 Shipped a SIMD Library Nobody Asked For -
this take is peak dunning-kruger: https://github.com/llvm/llvm-project/tree/main/llvm/test/Cod...
comment by mathisfun123 · 2026-05-07 · in Nobody Reviews Compiler Output -
…MSVC: https://visualstudio.microsoft.com/downloads/?q=build+tools#... Clang targeting MSVC ABI: https://github.com/llvm/llvm-project/releases/download/llvmo... Clang targeting MinGW ABI: https://github.com/mstorsjo/llvm-mingw/releases/tag/2…
comment by delta_p_delta_x · 2026-05-03 · in Windows API is Successful Cross-Platform API (2024) -
The linked clang PR is also very readable. https://github.com/llvm/llvm-project/pull/181288/files As the PR clearly points out, you can do this in a register but not inside vectors. I don't think fastdiv has had an update in years, which…
comment by gopalv · 2026-04-13 · in Optimization of 32-bit Unsigned Division by Constants on 64-bit Targets -
…is passed to the clang C++ compiler, the output is: > distance: 0.1 > proj_vector_y: -0.08 [0] https://github.com/llvm/llvm-project/issues/17379 [1] https://www.gnu.org/software/gcc/projects/c-status.html [2]…
comment by shakna · 2026-04-04 · in Big-Endian Testing with QEMU -
…doesn't implement anything regarding reflection right now. There is some support for parsing ( https://github.com/llvm/llvm-project/blob/main/clang/test/Pa... ) but that's it. There are some open PRs for other parts though.
comment by tbaeder · 2026-03-30 · in C++26 is done: ISO C++ standards meeting Trip Report -
> 1) https://github.com/llvm/llvm-project/issues/150263 Huh? They have no idea what they are doing. If data is unaligned, the solution is memcpy, not compiler optimizations, also their hack of 17 loads is buffer overflow. Also not ISA spec…
comment by GoblinSlayer · 2026-03-11 · in RISC-V Is Sloooow -
>Misaligned loads and stores are Zicclsm Nope. See https://github.com/llvm/llvm-project/issues/110454 which was linked in the first issue. The spec authors have managed to made a mess even here. Now they want to introduce yet another…
comment by newpavlov · 2026-03-10 · in RISC-V Is Sloooow -
In some cases RISC-V ISA spec is definitely the one to blame: 1) https://github.com/llvm/llvm-project/issues/150263 2) https://github.com/llvm/llvm-project/issues/141488 Another example is hard-coded 4 KiB page size which effectively…
comment by newpavlov · 2026-03-10 · in RISC-V Is Sloooow -
…Also baremetal where the metal is virtual. LLVM uses this term for when an OS isn't available https://github.com/llvm/llvm-project/tree/main/libc/src/stdl...
comment by benatkin · 2026-02-18 · in Minimal x86 Kernel Zig -
…> (gci Env:PATH).Value.Split(';') | sort > clang-21.exe --version clang version 21.1.2 (https://github.com/llvm/llvm-project.git b708aea0bc7127adf4ec643660699c8bcdde1273) Target: x86_64-w64-windows-gnu Thread model: posix InstalledDir:…
comment by delta_p_delta_x · 2026-02-15 · in I fixed Windows native development -
…loads/stores. Perhaps expand-memcmp should then do a round of store-to-load forwarding. Filed https://github.com/llvm/llvm-project/issues/180991 which I think is what the author should do in cases like this (rather than a blog post).
comment by ndesaulniers · 2026-02-11 · in Both GCC and Clang generate strange/inefficient code -
Compilers also like to unnecessarily copy data to stack: https://github.com/llvm/llvm-project/issues/53348 Which can be particularly annoying in cryptographic code where you want to minimize number of copies of sensitive data.
comment by newpavlov · 2026-02-11 · in Both GCC and Clang generate strange/inefficient code -
…of compiler bugs. There was a notorious LLVM pass that had more bugs than lines of code ;) https://github.com/llvm/llvm-project/issues?q=is%3Aissue This is a list for just the last few years after LLVM switched to the using github for…
comment by fooker · 2026-01-26 · in Draig, a Welsh Programming Language -
…union analysis feature request to gcc and clang, and someone generalized it into a guard builtin. https://github.com/llvm/llvm-project/issues/74205 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112840 GCC proved to be too complex for me to…
comment by matheusmoreira · 2026-01-24 · in Some C habits I employ for the modern day -
Yes, the Orc C API follows different rules from the rest of the C API ( https://github.com/llvm/llvm-project/blob/501416a755d1b85ca1... ).
comment by nikic · 2026-01-12 · in LLVM: The bad parts -
The _fltused handling is quite crude: https://github.com/llvm/llvm-project/blob/5cfd02f44a43a2e2a0... TLDR it's going to emit the reference if it's targeting MSVC and there's any float typed reference. You'd need to do something to avoid…
comment by wmobit · 2026-01-05 · in Ask HN: Help with LLVM -
…software. See LLVM for example. LLVM is the backbone of most compiler work in the world right now. https://github.com/llvm/llvm-project/issues
comment by fooker · 2026-01-04 · in KDE onboarding is good now -
…other strategies can we pursue? Move all the hot BBs near each other, right? Facebook's solution: https://github.com/llvm/llvm-project/blob/main/bolt%2FREADME... Google's: https://lists.llvm.org/pipermail/llvm-dev/2019-September/135...
comment by yablak · 2025-12-29 · in Huge Binaries -
We do; most people don't just write eBPF by hand. https://github.com/llvm/llvm-project/tree/main/llvm/lib/Targ...
comment by vitus · 2025-12-28 · in Rex is a safe kernel extension framework that allows Rust in the place of eBPF -
…here is some related code: https://github.com/gcc-mirror/gcc/blob/master/gcc/tree-chrec... https://github.com/llvm/llvm-project/blob/release/21.x/llvm/...
comment by uecker · 2025-12-24 · in When compilers surprise you -
Yeah. Pretty basic. Just 14k LOC https://github.com/llvm/llvm-project/blob/release/21.x/llvm/...
comment by f1shy · 2025-12-24 · in When compilers surprise you -
The code that does this is here, if anyone is curious: https://github.com/llvm/llvm-project/blob/release/21.x/llvm/... https://github.com/llvm/llvm-project/blob/release/21.x/llvm/...
comment by bumholes · 2025-12-24 · in When compilers surprise you -
…is nothing stopping you from writing your own targets too in LLVM and its not obscenely difficult https://github.com/llvm/llvm-project/tree/main/llvm/lib/Targ...
comment by vablings · 2025-12-12 · in The Tor Project is switching to Rust -
…The APIs more or less abstract this away from consumers like static analysis tools, though. E.g., https://github.com/llvm/llvm-project/blob/62e00a03fba029f82d... and https://github.com/llvm/llvm-project/blob/62e00a03fba029f82d...
comment by loeg · 2025-12-10 · in Super-Flat ASTs -
…LLVM or GCC, though there's a proposal to introduce such guarantees through a new builtin in LLVM https://github.com/llvm/llvm-project/pull/166702 though those could still be broken by post-build optimizers, like wasm.
comment by the8472 · 2025-12-07 · in Eurydice: a Rust to C compiler -
…indeed corresponds to a Brainfuck loop `[->+<]`---, and its SCEV implementation is truly massive: https://github.com/llvm/llvm-project/blob/main/llvm/lib/Anal...
comment by lifthrasiir · 2025-12-03 · in You can't fool the optimizer -
…bits undefined by omission only, which is why I think most people followed the GCC interpretation. https://github.com/llvm/llvm-project/issues/12579 https://groups.google.com/g/x86-64-abi/c/h7FFh30oS3s/m/Gksan...…
comment by fweimer · 2025-12-02 · in Addressing the adding situation -
…`(x&0xffff000000000000)==0xfff7000000000000` which do the exact same thing but clang is stupid [ https://github.com/llvm/llvm-project/issues/62145 ] and generates different things; and of course a big question is how many such intricacies…
comment by dzaima · 2025-11-29 · in The current state of the theory that GPL propagates to AI models -
…the default allocator in Fuchsia, and in Android since Android 11 compiler-rt/lib/scudo/standalone: https://github.com/llvm/llvm-project/tree/main/compiler-rt/l... hardened_malloc is an alternative to scudo.
comment by westurner · 2025-11-23 · in Windows ARM64 Internals: Deconstructing Pointer Authentication -
…-fsanitize=memtag sanitizer: lldb/source/Plugins/Process/Utility/MemoryTagManagerAArch64MTE.cpp : https://github.com/llvm/llvm-project/blob/main/lldb/source/P... lldb/source/Target/MemoryTagMap.cpp: https://github.com/llvm/llvm-project/blob…
comment by westurner · 2025-11-23 · in Windows ARM64 Internals: Deconstructing Pointer Authentication -
…Building the Linux kernel with LLVM: https://github.com/ClangBuiltLinux/linux/issues LLVM itself: https://github.com/llvm/llvm-project/issues?q=is%3Aissue%20s...
comment by ndesaulniers · 2025-11-08 · in Becoming a compiler engineer