← Back
Home › Systems › Numerical and mathematical computing

autodiff-framework

automatic differentiation

JAX, Enzyme

SystemTechniques · 14Primitives · 40 autodiff-framework Alias analysiscompilers · medium: Decide whether two pointers may refer to the same memory (Andersen, Steensgaard, type-based) to enable optimizationsDataflow analysiscompilers · medium: Compute a fact per program point (live variables, reaching definitions, available expressions) by iterating transfer functions over the CFG to a fixed point.›Function inliningcompilers · medium: Inline call sites by cost model and call-graph order; enables downstream optimizationsInstruction selectioncompilers · medium: Cover the IR with target instruction patterns at least cost; greedy maximal munch is simple, dynamic programming over a tree or DAG is optimal.›JIT compilationcompilers · medium: Run cold code in a cheap tier, count executions, and compile only what gets hot, trading warm-up time and memory for peak speed.›Kernel autotuningml-training · medium: Searching tile sizes and launch parameters per shape/hardware, caching the best configsTensor compiler schedulingml-training · medium: Tile, fuse and lay out tensor ops for a target (XLA, TVM, Triton schedules), plus autotuningSSA formcompilers · low: Give every variable exactly one definition, merging at joins with phi functions; def-use becomes explicit and optimizations turn sparse and cheap.›Kernel fusionml-training · low: Merge chains of memory-bound GPU ops into one kernel, so intermediates stay in registers instead of round-tripping through HBM.›Tensor layout transformsml-training · low: Choosing and converting tensor layouts (NCHW/NHWC, blocked, tiled) for kernel efficiencyTensor memory planningml-training · low: Static buffer reuse from tensor lifetimes so a graph runs in a fixed arena with minimal peak memoryShape inferencecompilers · low: Propagating tensor shapes and dtypes through an operator graph, with symbolic dimensionsPythonlanguages · low: The fastest language to write and the home of ML and data science; slow as an interpreter, fast when C/CUDA libraries do the work.›Collective communicationml-training · low: The family of group exchanges (broadcast, reduce, all-gather, reduce-scatter, all-to-all) and the latency-plus-bytes cost model that picks ring, tree or direct algorithms by message size and topology.›Cuda graphsml-training · low: Capturing a sequence of GPU kernel launches once and replaying it to remove CPU launch overheadGradient checkpointingml-training · low: Save only some activations in the forward pass and recompute the rest during backward, trading about 33% extra compute for O(√n) activation memory.›Reverse-mode automatic differentiat…ml-training · low: Record the forward computation on a tape, then sweep it backwards once to get the gradient of a scalar loss for all inputs.›Tensor parallelismml-training · low: Split each layer's weight matrices across GPUs (Megatron-style column then row splits) so one layer's math runs on t devices with one all-reduce per block.›Union-findgraphs · low: Disjoint-set forest with union by size and path compression; merges sets and answers same-set queries in effectively constant time.›Control-flow graphcompilers · low: Split a linear instruction list into basic blocks and connect them by jumps; the graph every optimizer, SSA builder and dataflow pass walks.›Topological sortgraphs · low: Order the vertices of a DAG so every edge points forward; the core of build systems, schedulers and dependency resolution, with cycle detection for free.›Strongly connected componentsgraphs · low: Tarjan/Kosaraju SCCs for cycle detection in dependency graphsMachine code emissioncompilers · low: Encode instructions to bytes for x86-64 and AArch64, branch relaxation, constant pools+ 7 more techniques+ 24 more primitives

Similar systems

Share the most building blocks with this one.