Paper 2021/1505 Original: eprint.iacr.org/2021/1505 ↗

EVA Improved: Compiler and Extension Library for CKKS

Sangeeta Chowdhary
Wei Dai
Kim Laine
Olli Saarikivi
Abstract

Homomorphic encryption (HE), especially the CKKS scheme, can be extremely challenging to use. The EVA language and compiler (Dathathri et al., PLDI 2020) was an attempt at addressing this challenge. EVA allows a developer to express their encrypted computation in a simple form with a Python-integrated language called PyEVA. It then compiles the program into an executable form by inserting operations such as relinearization and rescaling, applying optimizations, and choosing encryption parameters with the objective of minimizing execution time. Compiled programs can be executed with a parallelizing back-end against a library of HE primitives. Our work improves upon the EVA toolchain in several ways: changes to the Python front-end make writing PyEVA programs more natural, while a rework of EVA's C++ APIs makes writing new passes easier. We also implement two new optimizations, common subexpression elimination and reduction balancing, which we show allow users to write simpler and more modular PyEVA programs. We argue that the abstraction EVA provides is insufficient to resolve some common usability challenges. For example, managing vectors of arbitrary size is non-trivial. To resolve these problems, we demonstrate how building a library of commonly used data structures and functions is simple in PyEVA. EVA's automation allows writing very concise code, which gets fused and optimized together with the user program. We create the beginnings of an EVA Extension Library (EXL), that provides vector and matrix classes and a collection of common statistical functions, to demonstrate the power of this approach.

Metadata
Available format(s)
PDF
Category
Public-key cryptography
Publication info
Preprint.
History
2021-11-15: last updated
2021-11-15: published
Short URL
https://ia.cr/2021/1505
License
https://creativecommons.org/licenses/by/4.0/

BibTeX

@misc{cryptoeprint:2021/1505,
      author = {Sangeeta Chowdhary and Wei Dai and Kim Laine and Olli Saarikivi},
      title = {EVA Improved: Compiler and Extension Library for CKKS},
      howpublished = {Cryptology {ePrint} Archive, Paper 2021/1505},
      year = {2021},
      url = {https://eprint.iacr.org/2021/1505}
}
Note: In order to protect the privacy of readers, this archive does not use cookies or embedded third party content.