---
title: "C & C++ (hard)"
description: "C or C++ code, toolchains or idioms"
url: "https://swe.quest/tags/c-cpp?difficulty=hard&per=96"
---

# C & C++ (hard)

Topic in Languages: C or C++ code, toolchains or idioms

By difficulty: [Easy](https://swe.quest/tags/c-cpp.md?difficulty=easy) · [Medium](https://swe.quest/tags/c-cpp.md?difficulty=medium) · [Hard](https://swe.quest/tags/c-cpp.md?difficulty=hard)

Posts 1–37 of 37, page 1 of 1, newest first.

## 2026-09-30

- [Memory safety for Postgres extensions in C/C++](https://swe.quest/articles/memory-safety-for-postgres-extensions-in-c-c-b6883b8eb3b1e33d.md): ClickHouse · 2026-09-30 · Hard · 4 min read · PostgreSQL, Memory safety, C & C++, Memory management
  Postgres's palloc/MemoryContext allocation and setjmp/longjmp-based error handling clash with C++ new/delete, destructors and exceptions: longjmp skips destructors (undefined behavior), exceptions bypass PG\_CATCH, and an uncaught exception aborts the process and forces cluster-wide crash recovery.

## 2026-09-29

- [Inscribed Spheres](https://swe.quest/articles/inscribed-spheres-119dd641a396418e.md): Box2D · 2026-09-29 · Hard · 14 min read · Games, Algorithms, Performance engineering, C & C++
  Inscribed spheres give a cheap upper bound on the separation achievable along any axis in the separating axis test (SAT): n·d − (rA + rB), where d joins the sphere centers.

## 2026-09-10

- [To Infinity and Beyond: ThunderKittens Now on NVIDIA Vera Rubin NVL72!](https://swe.quest/articles/to-infinity-and-beyond-thunderkittens-now-on-nvidia-vera-rubin-nvl72-597516f5605fb093.md): Together AI · 2026-09-10 · Hard · 11 min read · Hardware, Performance engineering, Inference & serving, C & C++
  ThunderKittens adds support for five Vera Rubin GEMM features: a doubled 64-byte K step in tcgen05.mma, 576-column exclusive tensor memory, 328 KiB oversized shared memory, a B-side collector buffer, and early A-operand release via tcgen05.commit.sync\_restrict.

## 2026-08-24

- [Native Async/Coroutine Reads in RocksDB](https://swe.quest/articles/native-async-coroutine-reads-in-rocksdb-a16f6ef8c30162a7.md): RocksDB Blog · 2026-08-24 · Hard · 10 min read · Storage engines, Concurrency, C & C++, Performance engineering, Databases
  RocksDB 11.10.0 adds experimental native asynchronous Get/MultiGet APIs (callback-based GetAsync/MultiGetAsync and Folly-task-based CoroDB::CoGet/CoMultiGet) that suspend a read at the SST block-miss filesystem boundary and resume it on the same io\_uring-backed EventBase thread, so a small read executor can sustain high storage queue depth without one parked thread per read.

## 2026-07-18

- [SIMD for Collision](https://swe.quest/articles/simd-for-collision-0a426a9583188633.md): Box2D · 2026-07-18 · Hard · 5 min read · Performance engineering, Games, Algorithms, C & C++
  Box3D uses wide SIMD to speed up the edge-edge phase of the Separating Axis Test, testing one edge of hull A against four edges of hull B at once using structure-of-arrays data.

## 2026-07-17

- [Running unmodified Doom in the SQLite bytecode language](https://swe.quest/articles/running-unmodified-doom-in-the-sqlite-bytecode-language-75f412e9cb0f0591.md): Turso · 2026-07-17 · Hard · 12 min read · Compilers, SQLite, Runtimes & VMs, Storage engines, C & C++
  Turso compiles unmodified Doom C source to SQLite's VDBE bytecode by using LLVM as a frontend and a custom backend, vdbecc, that lowers LLVM IR to VDBE.

## 2026-06-30

- [Core dump epidemiology: fixing an 18-year-old bug](https://swe.quest/articles/core-dump-epidemiology-fixing-an-18-year-old-bug-49f918c45e5e4eb3.md): OpenAI · 2026-06-30 · Hard · 16 min read · Debugging, C & C++, Linux, Hardware, Incidents & postmortems
  Mysterious return-to-bogus-address crashes in Rockset's C++ execution layer turned out to be two unrelated bugs: silent register corruption on a single bad Azure host, and an 18-year-old race in GNU libunwind's \_Ux86\_64\_setcontext, which read the synthesized ucontext\_t after moving %rsp past it, letting a frequent SIGUSR2 CPU-time signal clobber it during exception unwinding.

## 2026-06-25

- [Announcing Silk: a silky smooth fiber runtime for ClickHouse](https://swe.quest/articles/announcing-silk-a-silky-smooth-fiber-runtime-for-clickhouse-bd3ca633b291b6b6.md): ClickHouse · 2026-06-25 · Hard · 11 min read · Concurrency, Runtimes & VMs, C & C++, Performance engineering, Linux
  Silk is a C++ stackful-fiber runtime for ClickHouse. It pins one scheduler thread per CPU, uses io\_uring as its I/O foundation, steals work in order of CPU topology cost (hyperthread sibling, then same socket, then cross-socket), and does zero heap allocation in the steady-state hot path through mmap'd stack pools, stack-resident futures and intrusive containers.

## 2026-06-20

- [Blob Direct Write With Partitioned Blob Files](https://swe.quest/articles/blob-direct-write-with-partitioned-blob-files-8acc320f71e2d848.md): RocksDB Blog · 2026-06-20 · Hard · 9 min read · Storage engines, Databases, C & C++
  RocksDB's Blob Direct Write writes values at or above min\_blob\_size straight to blob files during the write, so the WAL and memtable carry only a compact BlobIndex reference instead of the full value.

## 2026-05-22

- [Integrating the Rust Delta Kernel into ClickHouse](https://swe.quest/articles/integrating-the-rust-delta-kernel-into-clickhouse-4dfcdd8e64024cda.md): ClickHouse · 2026-05-22 · Hard · 17 min read · Analytics & OLAP, Rust, C & C++, Build systems, Data pipelines
  ClickHouse replaced its hand-written Delta Lake protocol implementation with the Rust Delta Kernel (delta-kernel-rs).

## 2026-04-09

- [Escaping the Fork: How Meta Modernized WebRTC Across 50+ Use Cases](https://swe.quest/articles/escaping-the-fork-how-meta-modernized-webrtc-across-50-use-cases-604586fd757c3181.md): Meta Engineering · 2026-04-09 · Hard · 10 min read · C & C++, Refactoring & migrations, Communications, Build systems, Version control
  Meta escaped a long-diverged internal WebRTC fork by statically linking two WebRTC versions into one binary behind a version-agnostic shim layer, which let it A/B test legacy and upstream stacks app-by-app across 50+ use cases.

## 2025-12-31

- [BitFields API: Type-Safe Bit Packing for Lock-Free Data Structures](https://swe.quest/articles/bitfields-api-type-safe-bit-packing-for-lock-free-data-structures-0725d8986cbdf5c3.md): RocksDB Blog · 2025-12-31 · Hard · 9 min read · Concurrency, C & C++, Data structures, Caching, Performance engineering
  RocksDB's BitFields API is a template-based C++ abstraction that declares multiple logical fields packed into one atomic integer, replacing hand-written shifts and masks with typed Get/Set accessors and composable "transforms".

## 2025-12-18

- [Taming PostgreSQL GUC “extra” Data](https://swe.quest/articles/taming-postgresql-guc-extra-data-7e376007c1715e0d.md): ClickHouse · 2025-12-18 · Hard · 8 min read · PostgreSQL, C & C++, Memory management, Configuration management
  PostgreSQL GUC check and assign hooks can pre-parse a custom string setting into a structured value, but only if the "extra" data follows the GUC API's memory rules.

## 2025-12-16

- [Parallelizing ClickHouse aggregation merge for fixed hash map](https://swe.quest/articles/parallelizing-clickhouse-aggregation-merge-for-fixed-hash-map-9fc83cd0ed214dc7.md): ClickHouse · 2025-12-16 · Hard · 6 min read · Query engines, Performance engineering, Concurrency, Memory management, C & C++
  ClickHouse 25.11 parallelizes the merge phase for GROUP BY on 8- and 16-bit keys, which use an array-backed FixedHashMap.

## 2025-11-19

- [chDB Kernel Upgrade Journey: Upgrading ClickHouse to v25.8.2.29](https://swe.quest/articles/chdb-kernel-upgrade-journey-upgrading-clickhouse-to-v25-8-2-29-3cca5f2ad115d794.md): ClickHouse · 2025-11-19 · Hard · 16 min read · Memory management, C & C++, Python, Analytics & OLAP, Performance engineering
  Upgrading chDB's embedded ClickHouse kernel from v25.5 to v25.8.2.29 surfaced allocator conflicts rooted in chDB's dual-library design: a stable-ABI \`\_chdb.abi3.so\` holding the ~120MB engine plus small per-Python-version pybind11 binding libraries.

## 2025-10-08

- [Parallel Compression Revamp: Dramatically Reduced CPU Overhead](https://swe.quest/articles/parallel-compression-revamp-dramatically-reduced-cpu-overhead-347cdd5afee49826.md): RocksDB Blog · 2025-10-08 · Hard · 5 min read · Storage engines, Concurrency, Performance engineering, C & C++
  RocksDB 10.7 rewrites parallel compression for SST generation around a lock-free ring buffer of in-progress blocks.

## 2025-09-25

- [IO Activity Tagging](https://swe.quest/articles/io-activity-tagging-2c1c0aefff706db2.md): RocksDB Blog · 2025-09-25 · Hard · 2 min read · Storage engines, Observability, Performance engineering, C & C++
  RocksDB automatically tags every IO operation with an \`IOActivity\` enum value (flush, compaction, DB open, Get, MultiGet, iterator, checksum verification, entity reads and others) and propagates it through \`IOOptions\` to the file system.

## 2025-04-29

- [Introducing AutoPatchBench: A Benchmark for AI-Powered Security Fixes](https://swe.quest/articles/introducing-autopatchbench-a-benchmark-for-ai-powered-security-fixes-f107d000a04ddc7d.md): Meta Engineering · 2025-04-29 · Hard · 17 min read · Evaluation, Vulnerability research, AI for coding, C & C++, Testing
  AutoPatchBench is a benchmark of 136 fuzzing-found C/C++ vulnerabilities from real projects, curated from the ARVO/OSS-Fuzz dataset, for evaluating AI program repair agents.

## 2025-03-21

- [Dynamic Tree Improvements](https://swe.quest/articles/dynamic-tree-improvements-db8f5926a23bef4f.md): Box2D · 2025-03-21 · Hard · 3 min read · Data structures, Algorithms, Games, C & C++
  Box2D's dynamic tree inserts a new proxy using a greedy, single-descent heuristic that approximates minimizing the surface area heuristic (SAH) instead of doing an exhaustive search, since incremental insertion is inherently greedy anyway.

## 2024-11-05

- [How Bun supports V8 APIs without using V8 (part 2)](https://swe.quest/articles/how-bun-supports-v8-apis-without-using-v8-part-2-d765ff746fe7a86a.md): Bun · 2024-11-05 · Hard · 18 min read · Runtimes & VMs, JavaScript, C & C++, Memory management
  Bun emulates V8's memory layout on top of JavaScriptCore so that precompiled native addons, which inline V8 functions assuming specific pointer layouts, keep working.

## 2024-09-30

- [How Bun supports V8 APIs without using V8 (part 1)](https://swe.quest/articles/how-bun-supports-v8-apis-without-using-v8-part-1-ff8148b61cb465d8.md): Bun · 2024-09-30 · Hard · 19 min read · Runtimes & VMs, C & C++, JavaScript, Memory management
  Bun, which runs on JavaScriptCore, implements a growing subset of V8's C++ embedding API so Node.js native modules like cpu-features load without V8.

## 2024-08-19

- [SIMD Matters](https://swe.quest/articles/simd-matters-f3febffdc470bd02.md): Box2D · 2024-08-19 · Hard · 8 min read · Performance engineering, Games, Algorithms, C & C++, Hardware
  Box2D 3.0 solves contact constraints with SIMD by using greedy graph coloring to group constraints so no body appears twice within a color.

## 2024-02-20

- [Aligning Velox and Apache Arrow: Towards composable data management](https://swe.quest/articles/aligning-velox-and-apache-arrow-towards-composable-data-management-afb27bd747bab328.md): Meta Engineering · 2024-02-20 · Hard · 8 min read · Query engines, Analytics & OLAP, Data structures, Open source, C & C++
  Apache Arrow 15 adds three columnar layouts derived from Meta's Velox Vectors: StringView, ListView and Run-End-Encoding (REE).

## 2024-02-05

- [Static Roots: Objects with Compile-Time Constant Addresses](https://swe.quest/articles/static-roots-objects-with-compile-time-constant-addresses-91e4d5de9f87687b.md): V8 · 2024-02-05 · Hard · 4 min read · Runtimes & VMs, Memory management, Performance engineering, JavaScript, C & C++
  V8's static roots place the read-only heap at the start of every pointer-compression cage and generate it deterministically, so core objects like \`undefined\` get compressed addresses known at compile time (e.g. \`undefined\` is always 0x61).

## 2024-01-29

- [Option Soup: the subtle pitfalls of combining compiler flags](https://swe.quest/articles/option-soup-the-subtle-pitfalls-of-combining-compiler-flags-ee7121060b7d1c26.md): Mozilla Hacks · 2024-01-29 · Hard · 8 min read · C & C++, Debugging, Build systems, Linux, Incidents & postmortems
  A Firefox 120 beta crash in std::locale::classic() on Ubuntu 18.04 traced back to a downstream build that combined -static-libstdc++ with the linker flag -Bsymbolic-functions.

## 2023-10-03

- [CPU Dispatch in ClickHouse](https://swe.quest/articles/cpu-dispatch-in-clickhouse-5bbf7a6eb81cd552.md): ClickHouse · 2023-10-03 · Hard · 16 min read · C & C++, Performance engineering, Compilers, Hardware, Analytics & OLAP
  CPU dispatch lets a single binary use SIMD instruction sets like AVX2 and AVX-512 while staying compatible with older CPUs: hot functions are compiled for several targets with the target attribute, and the best variant is chosen at runtime using CPUID feature checks.

## 2023-09-29

- [chDB - A Rocket Engine on a Bicycle](https://swe.quest/articles/chdb-a-rocket-engine-on-a-bicycle-951148e84c12126b.md): ClickHouse · 2023-09-29 · Hard · 9 min read · Analytics & OLAP, Memory management, C & C++, Python, Performance engineering
  chDB embeds the ClickHouse engine as an in-process Python module instead of shelling out to the 500MB clickhouse-local binary, using WriteBufferFromVector, Python memoryview and Pybind11 for zero-copy result retrieval.

## 2023-05-16

- [Hash tables in ClickHouse and C++ Zero-cost Abstractions](https://swe.quest/articles/hash-tables-in-clickhouse-and-c-zero-cost-abstractions-bd1cf29e2582e0a8.md): ClickHouse · 2023-05-16 · Hard · 19 min read · Data structures, C & C++, Performance engineering, Query engines, Analytics & OLAP
  ClickHouse implements GROUP BY and JOIN with a family of open-addressing hash tables generated from a common zero-cost C++ framework, specialized by key type and workload.

## 2023-04-12

- [Speeding up LZ4 in ClickHouse](https://swe.quest/articles/speeding-up-lz4-in-clickhouse-dbbd26281ee7c0df.md): ClickHouse · 2023-04-12 · Hard · 32 min read · Performance engineering, Storage engines, C & C++, Algorithms, Analytics & OLAP
  LZ4 decompression often tops ClickHouse query profiles because highly compressible, cached columnar data shifts the cost onto CPU, yet storing data uncompressed proved impractical due to disk space.

## 2023-03-30

- [Letting users block injected third-party DLLs in Firefox](https://swe.quest/articles/letting-users-block-injected-third-party-dlls-in-firefox-848938ef2741cba1.md): Mozilla Hacks · 2023-03-30 · Hard · 12 min read · Browsers, Security, Operating systems, C & C++
  Firefox 110 lets Windows users block specific injected third-party DLLs from the about:third-party page, which also flags DLLs linked to past crashes.

## 2023-03-09

- [Introducing Velox: An open source unified execution engine](https://swe.quest/articles/introducing-velox-an-open-source-unified-execution-engine-d191dd46ed8f465e.md): Meta Engineering · 2023-03-09 · Hard · 8 min read · Query engines, Analytics & OLAP, C & C++, Performance engineering, Open source
  Velox is Meta's open source C++ execution engine that unifies the data-plane components (expression evaluation, aggregation, joins, sorting, I/O, resource management) shared by engines like Presto, Spark and PyTorch's TorchArrow.

## 2022-11-23

- [JIT in ClickHouse](https://swe.quest/articles/jit-in-clickhouse-a3bd9587dc26e5d4.md): ClickHouse · 2022-11-23 · Hard · 27 min read · Compilers, Query engines, C & C++, Performance engineering, Analytics & OLAP
  Just-in-time compilation is built up from first principles: hand-encoding x86-64 instructions into an mmap'd executable page, calling back into host functions via pointers, and reading ELF sections to see where code and constants live.

## 2022-10-10

- [Improving Firefox responsiveness on macOS](https://swe.quest/articles/improving-firefox-responsiveness-on-macos-b8cb4da3ea0ad313.md): Mozilla Hacks · 2022-10-10 · Hard · 6 min read · Concurrency, Memory management, Performance engineering, Operating systems, C & C++
  Firefox 103 on macOS became much more responsive under load after its customized jemalloc allocator stopped using the deprecated OSSpinLock, which spins and yields in user space and can nearly live-lock on busy systems.

## 2022-07-20

- [Using Hermes’s Quicksort to run Doom: A tale of JavaScript exploitation](https://swe.quest/articles/using-hermes-s-quicksort-to-run-doom-a-tale-of-javascript-exploitation-218717db846741cf.md): Meta Engineering · 2022-07-20 · Hard · 12 min read · Vulnerability research, Runtimes & VMs, JavaScript, Memory safety, C & C++
  A fuzzer-found bug in Hermes's stable Quicksort let a comparator callback grow the array during Array.prototype.sort, so the fixed-size index vector was read out of bounds.

## 2021-11-10

- [Oilpan library · V8](https://swe.quest/articles/oilpan-library-v8-a23ba3c3b59aeb1f.md): V8 · 2021-11-10 · Hard · 5 min read · Memory management, Runtimes & VMs, C & C++, Browsers
  Oilpan, the trace-based C++ garbage collector originally built for Blink, has been extracted into a library hosted in V8 since v9.4 (enabled in Chromium M94) under the cppgc namespace.

## 2021-07-02

- [Protecting reserved roles with PostgreSQL Hooks](https://swe.quest/articles/protecting-reserved-roles-with-postgresql-hooks-2e21a72630349824.md): Supabase · 2021-07-02 · Hard · 10 min read · PostgreSQL, Identity & auth, C & C++, Multi-tenancy
  Supabase grants customers the CREATEROLE privilege while preventing them from altering or dropping its internal service roles (like supabase\_storage\_admin) via a C extension, SupaUtils, that hooks PostgreSQL's ProcessUtility\_hook.

## 2021-04-06

- [Eliminating Data Races in Firefox – A Technical Report](https://swe.quest/articles/eliminating-data-races-in-firefox-a-technical-report-5763b33d1a4f6f94.md): Mozilla Hacks · 2021-04-06 · Hard · 11 min read · Concurrency, C & C++, Rust, Debugging, Static analysis
  Mozilla deployed ThreadSanitizer across Firefox's C/C++ and Rust code, using a compiled-in suppression list to gate new races in CI while legacy ones were triaged toward a "no data races" policy.

Same list as RSS: [https://swe.quest/feed.xml?difficulty=hard&tag=c-cpp](https://swe.quest/feed.xml?difficulty=hard&tag=c-cpp). Lists take `?page=`, `?per=12|24|48|96` and, on the home page, `?tag=` (up to 3), `?source=`, `?difficulty=easy|medium|hard` and `?search=`.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
