Papers
Topics
Authors
Recent
Search
2000 character limit reached

Microsecond-scale Dynamic Validation of Idempotency for GPU Kernels

Published 31 Oct 2024 in cs.OS and cs.DC | (2410.23661v1)

Abstract: We discovered that a GPU kernel can have both idempotent and non-idempotent instances depending on the input. These kernels, called conditionally-idempotent, are prevalent in real-world GPU applications (490 out of 547 from six applications). Consequently, prior work that classifies GPU kernels as either idempotent or non-idempotent can severely compromise the correctness or efficiency of idempotence-based systems. This paper presents PICKER, the first system for instance-level idempotency validation. PICKER dynamically validates the idempotency of GPU kernel instances before their execution, by utilizing their launch arguments. Several optimizations are proposed to significantly reduce validation latency to microsecond-scale. Evaluations using representative GPU applications (547 kernels and 18,217 instances in total) show that PICKER can identify idempotent instances with no false positives and a false-negative rate of 18.54%, and can complete the validation within 5 us for all instances. Furthermore, by integrating PICKER, a fault-tolerant system can reduce the checkpoint cost to less than 4% and a scheduling system can reduce the preemption latency by 84.2%.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (77)
  1. Induction Variables, pages 35–58. Springer US, Boston, MA, 1995.
  2. Safety-related challenges and opportunities for gpus in the automotive domain. IEEE Micro, 38:46–55, 2018.
  3. Gpudrano: Detecting uncoalesced accesses in gpu programs. In International Conference on Computer Aided Verification, 2017.
  4. Static detection of uncoalesced accesses in gpu programs. Formal Methods in System Design, 60:1 – 32, 2021.
  5. Engineering a static verification tool for gpu kernels. In International Conference on Computer Aided Verification, 2014.
  6. The design and implementation of a verification technique for gpu kernels. ACM Trans. Program. Lang. Syst., 37:10:1–10:49, 2015.
  7. Gpuverify: a verifier for gpu kernels. In Conference on Object-Oriented Programming Systems, Languages, and Applications, 2012.
  8. Automated dynamic analysis of cuda programs. In Third Workshop on Software Tools for MultiCore Systems, volume 33, 2008.
  9. Rodinia: A benchmark suite for heterogeneous computing. IEEE International Symposium on Workload Characterization (IISWC), pages 44–54, 2009.
  10. Dymaxion: Optimizing memory access patterns for heterogeneous systems. 2011 International Conference for High Performance Computing, Networking, Storage and Analysis (SC), pages 1–11, 2011.
  11. cuDNN: Efficient primitives for deep learning. ArXiv, abs/1410.0759, 2014.
  12. Formal analysis of gpu programs with atomics via conflict-directed delay-bounding. In NASA Formal Methods, 2013.
  13. Symbolic crosschecking of data-parallel floating-point code. IEEE Transactions on Software Engineering, 40:710–737, 2014.
  14. TVM Community. The discussion of inplace update in dataflow block. https://discuss.tvm.apache.org/t/discuss-inplace-update-in-dataflow-block/14669, 2023.
  15. Idempotent processor architecture. 2011 44th Annual IEEE/ACM International Symposium on Microarchitecture (MICRO), pages 140–151, 2011.
  16. Static analysis and compiler design for idempotent processing. Proceedings of the 33rd ACM SIGPLAN Conference on Programming Language Design and Implementation, 2012.
  17. Z3: An efficient smt solver. In International Conference on Tools and Algorithms for Construction and Analysis of Systems, 2008.
  18. CUTLASS developers. Cutlass. https://github.com/NVIDIA/cutlass, 2021.
  19. Automated verification of idempotence for stateful serverless applications. In 17th USENIX Symposium on Operating Systems Design and Implementation (OSDI 23), pages 887–910, Boston, MA, 2023. USENIX Association.
  20. Towards a machine learning-assisted kernel with lake. Proceedings of the 28th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2, 2023.
  21. Apunet: Revitalizing gpu as packet processing accelerator. In Symposium on Networked Systems Design and Implementation, 2017.
  22. Microsecond-scale preemption for concurrent GPU-accelerated DNN inferences. In 16th USENIX Symposium on Operating Systems Design and Implementation (OSDI 22), pages 539–558, Carlsbad, CA, July 2022. USENIX Association.
  23. Decoding cuda binary. 2019 IEEE/ACM International Symposium on Code Generation and Optimization (CGO), pages 229–241, 2019.
  24. Deep residual learning for image recognition. IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 770–778, 2016.
  25. Pat Helland. Idempotence is not a medical condition. Communications of the ACM, 55:56 – 65, 2012.
  26. Mobilenets: Efficient convolutional neural networks for mobile vision applications. ArXiv, abs/1704.04861, 2017.
  27. Densely connected convolutional networks. IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 2261–2269, 2017.
  28. Parallelgpuos: A concurrent os-level gpu checkpoint and restore system using validated speculation. ArXiv, abs/2405.12079, 2024.
  29. Exploiting memory access patterns to improve memory performance in data-parallel architectures. IEEE Transactions on Parallel and Distributed Systems, 22:105–118, 2011.
  30. Formal foundations of serverless computing. Proceedings of the ACM on Programming Languages, 3:1 – 26, 2019.
  31. Fast and efficient model serving using multi-gpus with direct-host-access. Proceedings of the Eighteenth European Conference on Computer Systems, 2023.
  32. Boki: Stateful serverless computing with shared logs. Proceedings of the ACM SIGOPS 28th Symposium on Operating Systems Principles, 2021.
  33. Raising the bar for using gpus in software packet processing. In Symposium on Networked Systems Design and Implementation, 2015.
  34. iguard: In-gpu advanced race detection. Proceedings of the ACM SIGOPS 28th Symposium on Operating Systems Principles, 2021.
  35. Exploiting reference idempotency to reduce speculative storage overflow. ACM Trans. Program. Lang. Syst., 28:942–965, 2006.
  36. Idempotence-based preemptive gpu kernel scheduling for embedded systems. IEEE Transactions on Computers, 70:332–346, 2021.
  37. Asymmetric resilience: Exploiting task-level idempotency for transient error recovery in accelerator-based systems. 2020 IEEE International Symposium on High Performance Computer Architecture (HPCA), pages 44–57, 2020.
  38. Verifying gpu kernels by test amplification. Proceedings of the 33rd ACM SIGPLAN Conference on Programming Language Design and Implementation, 2012.
  39. Scalable smt-based verification of gpu kernel functions. In Fast Software Encryption Workshop, 2010.
  40. Gklee: concolic verification and test generation for gpus. In ACM SIGPLAN Symposium on Principles & Practice of Parallel Programming, 2012.
  41. Parametric flows: Automated behavior equivalencing for symbolic analysis of races in cuda programs. 2012 International Conference for High Performance Computing, Networking, Storage and Analysis, pages 1–10, 2012.
  42. Practical symbolic race checking of gpu programs. SC14: International Conference for High Performance Computing, Networking, Storage and Analysis, pages 179–190, 2014.
  43. Yes, one-bit-flip matters! universal dnn model inference depletion with runtime code fault injection. In USENIX Security Symposium, 2024.
  44. Exploring memory persistency models for gpus. 2019 28th International Conference on Parallel Architectures and Compilation Techniques (PACT), pages 311–323, 2019.
  45. Enabling efficient preemption for simt architectures with lightweight context switching. International Conference for High Performance Computing, Networking, Storage and Analysis, pages 898–908, 2016.
  46. Honeycomb: Secure and efficient GPU executions via static validation. In 17th USENIX Symposium on Operating Systems Design and Implementation (OSDI 23), pages 155–172, Boston, MA, 2023. USENIX Association.
  47. NVIDIA. NVIDIA GPU Instruction Set Reference. https://docs.nvidia.com/cuda/cuda-binary-utilities/index.html#instruction-set-reference.
  48. NVIDIA. NVIDIA TensorRT. https://developer.nvidia.com/tensorrt.
  49. NVIDIA. NVIDIA Tesla V100 GPU Architecture. https://images.nvidia.cn/content/volta-architecture/pdf/volta-architecture-whitepaper.pdf, 2017.
  50. NVIDIA. CUDA Samples. https://github.com/NVIDIA/cuda-samples, 2023.
  51. NVIDIA. FasterTransformer. https://github.com/NVIDIA/FasterTransformer, 2023.
  52. Gpm: leveraging persistent memory from a gpu. Proceedings of the 27th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, 2022.
  53. Checkpoint restart support for heterogeneous hpc applications. 2020 20th IEEE/ACM International Symposium on Cluster, Cloud and Internet Computing (CCGRID), pages 242–251, 2020.
  54. Chimera: Collaborative Preemption for Multitasking on a Shared GPU. Twentieth International Conference on Architectural Support for Programming Languages and Operating Systems, 2015.
  55. Pytorch: An imperative style, high-performance deep learning library. In NeurIPS, 2019.
  56. Error resilient machine learning for safety-critical systems: Position paper. 2020 IEEE 26th International Symposium on On-Line Testing and Robust System Design (IOLTS), pages 1–4, 2020.
  57. Vocl-ft: introducing techniques for efficient soft error coprocessor recovery. SC15: International Conference for High Performance Computing, Networking, Storage and Analysis, pages 1–12, 2015.
  58. Gpu devices for safety-critical systems: A survey. ACM Computing Surveys, 55:1 – 37, 2022.
  59. Halfmoon: Log-optimal fault-tolerant stateful serverless computing. Proceedings of the 29th Symposium on Operating Systems Principles, 2023.
  60. Language models are unsupervised multitask learners. 2019.
  61. G. Ramalingam and Kapil Vaswani. Fault tolerance via idempotence. Principles of Programming Languages (POPL), January 2013.
  62. SoK: (State of) The Art of War: Offensive Techniques in Binary Analysis. In IEEE Symposium on Security and Privacy, 2016.
  63. Push-button verification of file systems via crash refinement. In USENIX Annual Technical Conference, 2016.
  64. Gpufs: Integrating a file system with gpus. In TOCS, 2013.
  65. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556, 2014.
  66. A fault-tolerance shim for serverless computing. Proceedings of the Fifteenth European Conference on Computer Systems, 2020.
  67. Parboil: A revised benchmark suite for scientific and commercial throughput computing. 2012.
  68. I/o dependent idempotence bugs in intermittent systems. Proceedings of the ACM on Programming Languages, 3:1 – 31, 2019.
  69. Rethinking the inception architecture for computer vision. IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 2818–2826, 2016.
  70. Enabling preemptive multiprogramming on gpus. ACM/IEEE 41st International Symposium on Computer Architecture (ISCA), pages 193–204, 2014.
  71. Apache TVM. Apache TVM: An End to End Machine Learning Compiler Framework for CPUs, GPUs and accelerators. https://tvm.apache.org/, 2021.
  72. Joel van der Woude and Matthew Hicks. Intermittent computation without hardware support or programmer intervention. In USENIX Symposium on Operating Systems Design and Implementation, 2016.
  73. Nvbit: A dynamic binary instrumentation framework for nvidia gpus. Proceedings of the 52nd Annual IEEE/ACM International Symposium on Microarchitecture, 2019.
  74. Mulberry: Enabling bit-error robustness for energy-efficient multi-agent autonomous systems. In Proceedings of the 29th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2, ASPLOS ’24, pages 746–762, New York, NY, USA, 2024. Association for Computing Machinery.
  75. Scalable and fast lazy persistency on gpus. In IEEE International Symposium on Workload Characterization, IISWC 2020, Beijing, China, October 27-30, 2020, pages 252–263. IEEE, 2020.
  76. Fault-tolerant and transactional stateful serverless workflows. In USENIX Symposium on Operating Systems Design and Implementation, 2020.
  77. ExoFlow: A universal workflow system for Exactly-Once DAGs. In 17th USENIX Symposium on Operating Systems Design and Implementation (OSDI 23), pages 269–286, Boston, MA, 2023. USENIX Association.

Summary

No one has generated a summary of this paper yet.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Continue Learning

We haven't generated follow-up questions for this paper yet.

Collections

Sign up for free to add this paper to one or more collections.

Tweets

Sign up for free to view the 1 tweet with 0 likes about this paper.