NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Polar Coded Distributed Matrix Multiplication

Burak Bartan, Mert PilanciarXiv 2019

Abstract

We propose a serverless computing mechanism for distributed computation based on polar codes. Serverless computing is an emerging cloud-based computation model that lets users run their functions on the cloud without provisioning or managing servers. Our proposed approach is a hybrid computing framework that carries out computationally expensive tasks such as linear algebraic operations involving large-scale data using serverless computing and does the rest of the processing locally. We address the limitations and reliability issues of serverless platforms such as straggling workers using coding theory, drawing ideas from recent literature on coded computation. The proposed mechanism uses polar codes to ensure straggler-resilience in a computationally effective manner. We provide extensive evidence showing polar codes outperform other coding methods. We have designed a sequential decoder specifically for polar codes in erasure channels with full-precision input and outputs. In addition, we have extended the proposed method to the matrix multiplication case where both matrices being multiplied are coded. The proposed coded computation scheme is implemented for AWS Lambda. Experiment results are presented where the performance of the proposed coded computation technique is tested in optimization via gradient descent. Finally, we introduce the idea of partial polarization which reduces the computational burden of encoding and decoding at the expense of straggler-resilience.

Addressing the Straggler Problem in Serverless Computing

In distributed computing, "stragglers"—worker nodes that are significantly slower than others or fail entirely—often dictate the overall completion time of a task. While serverless computing (e.g., AWS Lambda) offers massive scalability without the overhead of managing servers, it exacerbates the straggler problem due to strict resource limits and unpredictable execution times.

Existing solutions often use Maximum Distance Separable (MDS) codes, like Reed-Solomon (RS), to add redundancy. However, MDS codes suffer from high computational complexity ($O(N^2)$ or $O(N^3)$) for decoding. This becomes a significant bottleneck when the number of workers ($N$) grows into the hundreds or thousands—a common scenario in serverless environments. Polar codes offer a compelling alternative with $O(N \log N)$ complexity, making them much more practical for high-$N$ regimes.

System Architecture and Methods

The proposed hybrid framework offloads heavy linear algebra tasks to serverless functions while the master node handles coordination and decoding. The core of this system is the adaptation of polar codes—originally designed for communication channels—to the "erasure channel" of distributed computing.

System architecture for polar coded distributed computation on AWS Lambda.

Key methodological contributions include:

  • Sequential Decoder for Real Numbers: Standard polar decoders work on finite fields. The authors designed a sequential decoder that handles full-precision real numbers, ensuring numerical stability for scientific computing.
  • 2D Matrix Multiplication: The framework extends 1D (matrix-vector) approaches to a 2D scheme for matrix-matrix multiplication, where both matrices are coded.
  • Partial Construction: To reduce the encoding/decoding burden for massive datasets, "partial polarization" partitions the matrix into smaller blocks that are coded independently.
  • Polarization of Run Times: Conceptually, polar codes "polarize" the execution times of workers, effectively creating virtual "fast" and "slow" channels from mediocre physical hardware.

Experimental Results

The framework was evaluated using synthetic matrix multiplications and real-world benchmarks on AWS Lambda. A major advantage of polar codes is that encoding and decoding involve only additions and subtractions, avoiding the costly floating-point multiplications required by Reed-Solomon decoders.

Comparison of encoding and decoding times for Polar Coding versus Reed-Solomon (RS) methods.

As shown in the performance plots, polar codes demonstrate superior scalability. In experiments with $N=512$ workers, polar codes were orders of magnitude faster to decode than Reed-Solomon codes. While naive RS decoding time spiked toward 300 seconds, polar decoding remained near-instantaneous. Furthermore, in iterative tasks like gradient descent for least-squares optimization, the polar-coded approach converged significantly faster than uncoded methods by eliminating the need to wait for the final "tail" stragglers in each iteration.

Limitations and Future Work

Despite their efficiency, polar codes have some constraints. The standard construction requires the number of workers to be a power of two ($2^k$), which can complicate resource allocation. Additionally, polar codes are not MDS; they require slightly more worker outputs than the theoretical minimum to decode successfully, though this gap closes as $N$ increases. Future research will focus on more efficient data movement strategies to mitigate the communication overhead of moving large coded matrices to and from cloud storage like S3.

Summary updated

BibTeX
@misc{bartan2019polar,
  author = {Burak Bartan and Mert Pilanci},
  title = {{Polar Coded Distributed Matrix Multiplication}},
  year = {2019},
  eprint = {1901.06811},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1901.06811},
}
Figure