62. Containers Batch 2 and wave-12A perf lowerings (2026-11-21)
Bitset<D>adoptsSubset<D>parity (empty,fullas@get,single,complement,set, plusof(xs: List<D>)for generators) while staying ordinary stdlib code. Reason: matchesSubset<D>constructors/operations and acceptsBitset<V>.of(k for k in V if ...); directfor v in bstays a general core-lane iteration protocol (noBitsetcompiler privilege). Reverse: revert the added methods instdlib/bitset.cp.- Bounded-domain
Bitset<D>(D.K <= 4096statically provable) reusescpl::Row<U64, W>inline storage andcpl-codegenfuses(a & b & ...).len/.count/.is_emptyinto one zero-allocation popcount pass. Reason: eliminates O(n^3) heap allocations oncf1146h(2.82x->1.29xmatched C++) without adding a new runtime container type. Reverse: remove theBitsetbranch incpl-codegen/src/scope.rs::rowsandtry_fused_bitset_opinexpr.rs. sort(by: key)with a cheap pure key expression lowers to in-placestd::stable_sortwith an inlined comparator instead ofcpl::sort_by's three auxiliary vectors. Reason: preserves stability and interpreter parity while eliminating O(n) temp allocations and index indirection (cf1284e:1.63x->1.14xmatched C++, -709 B emitted). Reverse: remove theis_cheap_pure_keybranch incpl-codegen/src/stmt.rs.