Cppless: Productive and Performant Serverless Programming in C++ (2401.10834v1)
Abstract: The rise of serverless introduced a new class of scalable, elastic and highly available parallel workers in the cloud. Many systems and applications benefit from offloading computations and parallel tasks to dynamically allocated resources. However, the developers of C++ applications found it difficult to integrate functions due to complex deployment, lack of compatibility between client and cloud environments, and loosely typed input and output data. To enable single-source and efficient serverless acceleration in C++, we introduce Cppless, an end-to-end framework for implementing serverless functions which handles the creation, deployment, and invocation of functions. Cppless is built on top of LLVM and requires only two compiler extensions to automatically extract C++ function objects and deploy them to the cloud. We demonstrate that offloading parallel computations from a C++ application to serverless workers can provide up to 30x speedup, requiring only minor code modifications and costing less than one cent per computation.
- 2014. AWS Lambda. https://aws.amazon.com/lambda/. Accessed: 2020-01-20.
- 2022. The State of Serverless. https://www.datadoghq.com/state-of-serverless/. Accessed: 2023-08-16.
- SAND: Towards High-Performance Serverless Computing. In Proceedings of the 2018 USENIX Conference on Usenix Annual Technical Conference (Boston, MA, USA) (USENIX ATC ’18). USENIX Association, USA, 923–935.
- Sprocket: A Serverless Video Processing Framework. In Proceedings of the ACM Symposium on Cloud Computing (Carlsbad, CA, USA) (SoCC ’18). Association for Computing Machinery, New York, NY, USA, 263–274. https://doi.org/10.1145/3267809.3267815
- On the FaaS Track: Building Stateful Distributed Applications with Serverless Architectures. In Proceedings of the 20th International Middleware Conference (Davis, CA, USA) (Middleware ’19). Association for Computing Machinery, New York, NY, USA, 41–54. https://doi.org/10.1145/3361525.3361535
- On-demand Container Loading in {{\{{AWS}}\}} Lambda. In 2023 USENIX Annual Technical Conference (USENIX ATC 23). 315–328.
- FaaSKeeper: Learning from Building Serverless Services with ZooKeeper as an Example. arXiv:2203.14859 [cs.DC]
- Marcin Copik and Hartmut Kaiser. 2017. Using SYCL as an Implementation Framework for HPX.Compute. In Proceedings of the 5th International Workshop on OpenCL (Toronto, Canada) (IWOCL 2017). Association for Computing Machinery, New York, NY, USA, Article 30, 7 pages. https://doi.org/10.1145/3078155.3078187
- SeBS: A Serverless Benchmark Suite for Function-as-a-Service Computing. In Proceedings of the 22nd International Middleware Conference (Middleware ’21). Association for Computing Machinery. https://doi.org/10.1145/3464298.3476133
- rFaaS: Enabling High Performance Serverless with RDMA and Leases. In 2023 IEEE International Parallel and Distributed Processing Symposium (IPDPS) (IPDPS ’23). 897–907. https://doi.org/10.1109/IPDPS54959.2023.00094
- Barcelona openmp tasks suite: A set of benchmarks targeting the exploitation of task parallelism in openmp. In 2009 international conference on parallel processing. IEEE, 124–131.
- Vinnie Falco. 2016. Beast: C++ HTTP and WebSocket built on Boost.Asio. https://github.com/boostorg/beast.
- Encoding, Fast and Slow: Low-Latency Video Processing Using Thousands of Tiny Threads. In 14th USENIX Symposium on Networked Systems Design and Implementation (NSDI 17). USENIX Association, Boston, MA, 363–376. https://www.usenix.org/conference/nsdi17/technical-sessions/presentation/fouladi
- W. Shane Grant and Randolph Voorhies. 2017. cereal - A C++11 library for serialization. http://uscilab.github.io/cereal/.
- Closing the Performance Gap with Modern C++. In Lecture Notes in Computer Science. Springer International Publishing, 18–31. https://doi.org/10.1007/978-3-319-46079-6_2
- Emily Herbert and Arjun Guha. 2020. A Language-based Serverless Function Accelerator. arXiv:1911.02178 [cs.DC]
- Towards Demystifying Serverless Machine Learning Training. In ACM SIGMOD International Conference on Management of Data (SIGMOD 2021).
- Cloud Programming Simplified: A Berkeley View on Serverless Computing. CoRR abs/1902.03383 (2019). arXiv:1902.03383 http://arxiv.org/abs/1902.03383
- Khronos SYCL for OpenCL: A Tutorial. In Proceedings of the 3rd International Workshop on OpenCL (Palo Alto, California) (IWOCL ’15). Association for Computing Machinery, New York, NY, USA, Article 24, 1 pages. https://doi.org/10.1145/2791321.2791345
- Solving the 24-queens Problem using MPI on a PC Cluster. Graduate School of Information Systems, The University of Electro-Communications, Tech. Rep (2004).
- Chris Lattner and Vikram Adve. 2004. LLVM: A Compilation Framework for Lifelong Program Analysis and Transformation. San Jose, CA, USA, 75–88.
- Lambada: Interactive Data Analytics on Cold Data using Serverless Cloud Infrastructure. ArXiv abs/1912.00937 (2019).
- Starling: A Scalable Query Engine on Cloud Functions. In Proceedings of the 2020 ACM SIGMOD International Conference on Management of Data (Portland, OR, USA) (SIGMOD ’20). Association for Computing Machinery, New York, NY, USA, 131–141. https://doi.org/10.1145/3318464.3380609
- Shuffling, Fast and Slow: Scalable Analytics on Serverless Infrastructure. In 16th USENIX Symposium on Networked Systems Design and Implementation (NSDI 19). USENIX Association, Boston, MA, 193–206. https://www.usenix.org/conference/nsdi19/presentation/pu
- Ruyman Reyes and Victor Lomüller. 2016. SYCL: Single-source C++ accelerator programming. In Parallel Computing: On the Road to Exascale. IOS Press, 673–682.
- Martin Richards. 1997. Backtracking algorithms in MCPL using bit patterns and recursion. Technical Report. Citeseer.
- Toward Multicloud Access Transparency in Serverless Computing. IEEE Software 38, 1 (2021), 68–74. https://doi.org/10.1109/MS.2020.3029994
- Peter Shirley. 2020a. Ray Tracing in One Weekend. https://raytracing.github.io/books/RayTracingInOneWeekend.html
- Peter Shirley. 2020b. Ray Tracing: The Next Week. https://raytracing.github.io/books/RayTracingTheNextWeek.html
- Tatsuhiro Tsujikawa. 2013. nghttp2 - HTTP/2 C Library. https://github.com/nghttp2/nghttp2.
- Gpucc: An Open-Source GPGPU Compiler. In Proceedings of the 2016 International Symposium on Code Generation and Optimization (Barcelona, Spain) (CGO ’16). Association for Computing Machinery, New York, NY, USA, 105–116. https://doi.org/10.1145/2854038.2854041
- Kappa: A Programming Framework for Serverless Computing. In Proceedings of the 11th ACM Symposium on Cloud Computing (Virtual Event, USA) (SoCC ’20). Association for Computing Machinery, New York, NY, USA, 328–343. https://doi.org/10.1145/3419111.3421277