LLM-aided explanations of EDA synthesis errors (2404.07235v2)
Abstract: Training new engineers in digital design is a challenge, particularly when it comes to teaching the complex electronic design automation (EDA) tooling used in this domain. Learners will typically deploy designs in the Verilog and VHDL hardware description languages to Field Programmable Gate Arrays (FPGAs) from Altera (Intel) and Xilinx (AMD) via proprietary closed-source toolchains (Quartus Prime and Vivado, respectively). These tools are complex and difficult to use -- yet, as they are the tools used in industry, they are an essential first step in this space. In this work, we examine how recent advances in artificial intelligence may be leveraged to address aspects of this challenge. Specifically, we investigate if LLMs, which have demonstrated text comprehension and question-answering capabilities, can be used to generate novice-friendly explanations of compile-time synthesis error messages from Quartus Prime and Vivado. To perform this study we generate 936 error message explanations using three OpenAI LLMs over 21 different buggy code samples. These are then graded for relevance and correctness, and we find that in approximately 71% of cases the LLMs give correct & complete explanations suitable for novice learners.
- S. A. Edwards, “Experiences teaching an FPGA-based embedded systems class,” ACM SIGBED Review, vol. 2, no. 4, pp. 56–62, Oct. 2005. [Online]. Available: https://dl.acm.org/doi/10.1145/1121812.1121823
- S. Pasricha, “Embedded Systems Education in the 2020s: Challenges, Reflections, and Future Directions,” in Proceedings of the Great Lakes Symposium on VLSI 2022, ser. GLSVLSI ’22. New York, NY, USA: Association for Computing Machinery, Jun. 2022, pp. 519–524. [Online]. Available: https://dl.acm.org/doi/10.1145/3526241.3530348
- M. A. Cherney, “U.S. will be short 67,000 chip workers by 2030, industry group says,” Reuters, Jul. 2023. [Online]. Available: https://www.reuters.com/technology/us-will-be-short-67000-chip-workers-by-2030-industry-group-says-2023-07-25/
- B. A. Becker, G. Glanville, R. Iwashima, C. McDonnell, K. Goslin, and C. Mooney, “Effective compiler error message enhancement for novice programming students,” Computer Science Education, vol. 26, no. 2-3, pp. 148–175, Jul. 2016. [Online]. Available: https://doi.org/10.1080/08993408.2016.1225464
- I. Karvelas, A. Li, and B. A. Becker, “The Effects of Compilation Mechanisms and Error Message Presentation on Novice Programmer Behavior,” in Proceedings of the 51st ACM Technical Symposium on Computer Science Education, ser. SIGCSE ’20. New York, NY, USA: Association for Computing Machinery, Feb. 2020, pp. 759–765. [Online]. Available: https://dl.acm.org/doi/10.1145/3328778.3366882
- M. Ben-Ari, “Constructivism in Computer Science Education,” Journal of Computers in Mathematics and Science Teaching, vol. 20, no. 1, pp. 45–73, 2001, publisher: Association for the Advancement of Computing in Education (AACE). [Online]. Available: https://www.learntechlib.org/primary/p/8505/
- L. Ouyang, J. Wu, X. Jiang, D. Almeida, C. Wainwright, P. Mishkin, C. Zhang, S. Agarwal, K. Slama, A. Ray, J. Schulman, J. Hilton, F. Kelton, L. Miller, M. Simens, A. Askell, P. Welinder, P. F. Christiano, J. Leike, and R. Lowe, “Training language models to follow instructions with human feedback,” in Advances in Neural Information Processing Systems, S. Koyejo, S. Mohamed, A. Agarwal, D. Belgrave, K. Cho, and A. Oh, Eds., vol. 35. Curran Associates, Inc., 2022, pp. 27 730–27 744. [Online]. Available: https://proceedings.neurips.cc/paper_files/paper/2022/file/b1efde53be364a73914f58805a001731-Paper-Conference.pdf
- OpenAI, “ChatGPT: Optimizing Language Models for Dialogue,” Nov. 2022. [Online]. Available: https://openai.com/blog/chatgpt/
- H. Pearce, B. Tan, and R. Karri, “DAVE: Deriving Automatically Verilog from English,” in Proceedings of the 2020 ACM/IEEE Workshop on Machine Learning for CAD. Virtual Event Iceland: ACM, Nov. 2020, pp. 27–32. [Online]. Available: https://dl.acm.org/doi/10.1145/3380446.3430634
- S. Thakur, B. Ahmad, Z. Fan, H. Pearce, B. Tan, R. Karri, B. Dolan-Gavitt, and S. Garg, “Benchmarking Large Language Models for Automated Verilog RTL Code Generation,” in 2023 Design, Automation & Test in Europe Conference & Exhibition (DATE), Apr. 2023, pp. 1–6, iSSN: 1558-1101. [Online]. Available: https://ieeexplore.ieee.org/abstract/document/10137086
- S. Thakur, B. Ahmad, H. Pearce, B. Tan, B. Dolan-Gavitt, R. Karri, and S. Garg, “VeriGen: A Large Language Model for Verilog Code Generation,” ACM Transactions on Design Automation of Electronic Systems, Feb. 2024, just Accepted. [Online]. Available: https://dl.acm.org/doi/10.1145/3643681
- M. Liu, N. Pinckney, B. Khailany, and H. Ren, “Invited Paper: VerilogEval: Evaluating Large Language Models for Verilog Code Generation,” in 2023 IEEE/ACM International Conference on Computer Aided Design (ICCAD), Oct. 2023, pp. 1–8, iSSN: 1558-2434. [Online]. Available: https://ieeexplore.ieee.org/abstract/document/10323812
- B. Ahmad, S. Thakur, B. Tan, R. Karri, and H. Pearce, “On Hardware Security Bug Code Fixes By Prompting Large Language Models,” IEEE Transactions on Information Forensics and Security, pp. 1–1, 2024, conference Name: IEEE Transactions on Information Forensics and Security. [Online]. Available: https://ieeexplore.ieee.org/abstract/document/10462177
- R. Kande, H. Pearce, B. Tan, B. Dolan-Gavitt, S. Thakur, R. Karri, and J. Rajendran, “(Security) Assertions by Large Language Models,” IEEE Transactions on Information Forensics and Security, pp. 1–1, 2024, conference Name: IEEE Transactions on Information Forensics and Security. [Online]. Available: https://ieeexplore.ieee.org/abstract/document/10458667
- M. Liu, T.-D. Ene, R. Kirby, C. Cheng, N. Pinckney, R. Liang, J. Alben, H. Anand, S. Banerjee, I. Bayraktaroglu, B. Bhaskaran, B. Catanzaro, A. Chaudhuri, S. Clay, B. Dally, L. Dang, P. Deshpande, S. Dhodhi, S. Halepete, E. Hill, J. Hu, S. Jain, B. Khailany, K. Kunal, X. Li, H. Liu, S. Oberman, S. Omar, S. Pratty, J. Raiman, A. Sarkar, Z. Shao, H. Sun, P. P. Suthar, V. Tej, K. Xu, and H. Ren, “ChipNeMo: Domain-Adapted LLMs for Chip Design,” Nov. 2023, arXiv:2311.00176 [cs]. [Online]. Available: http://arxiv.org/abs/2311.00176
- J. Blocklove, S. Garg, R. Karri, and H. Pearce, “Chip-Chat: Challenges and Opportunities in Conversational Hardware Design,” in 2023 ACM/IEEE 5th Workshop on Machine Learning for CAD (MLCAD), Sep. 2023, pp. 1–6. [Online]. Available: https://ieeexplore.ieee.org/document/10299874
- E. Kasneci, K. Sessler, S. Küchemann, M. Bannert, D. Dementieva, F. Fischer, U. Gasser, G. Groh, S. Günnemann, E. Hüllermeier, S. Krusche, G. Kutyniok, T. Michaeli, C. Nerdel, J. Pfeffer, O. Poquet, M. Sailer, A. Schmidt, T. Seidel, M. Stadler, J. Weller, J. Kuhn, and G. Kasneci, “ChatGPT for good? On opportunities and challenges of large language models for education,” Learning and Individual Differences, vol. 103, p. 102274, Apr. 2023. [Online]. Available: https://www.sciencedirect.com/science/article/pii/S1041608023000195
- R. Dijkstra, Z. Genç, S. Kayal, J. Kamps, and others, “Reading Comprehension Quiz Generation using Generative Pre-trained Transformers,” 2022. [Online]. Available: https://e.humanities.uva.nl/publications/2022/dijk_read22.pdf
- E. Gabajiwala, P. Mehta, R. Singh, and R. Koshy, “Quiz Maker: Automatic Quiz Generation from Text Using NLP,” in Futuristic Trends in Networks and Computing Technologies, ser. Lecture Notes in Electrical Engineering, P. K. Singh, S. T. Wierzchoń, J. K. Chhabra, and S. Tanwar, Eds. Singapore: Springer Nature, 2022, pp. 523–533.
- S. Jalil, S. Rafi, T. D. LaToza, K. Moran, and W. Lam, “ChatGPT and Software Testing Education: Promises & Perils,” in 2023 IEEE International Conference on Software Testing, Verification and Validation Workshops (ICSTW), Apr. 2023, pp. 4130–4137, iSSN: 2159-4848. [Online]. Available: https://ieeexplore.ieee.org/abstract/document/10132255
- B. A. Becker, P. Denny, J. Finnie-Ansley, A. Luxton-Reilly, J. Prather, and E. A. Santos, “Programming Is Hard - Or at Least It Used to Be: Educational Opportunities and Challenges of AI Code Generation,” in Proceedings of the 54th ACM Technical Symposium on Computer Science Education V. 1, ser. SIGCSE 2023. New York, NY, USA: Association for Computing Machinery, Mar. 2023, pp. 500–506. [Online]. Available: https://dl.acm.org/doi/10.1145/3545945.3569759
- P. Denny, V. Kumar, and N. Giacaman, “Conversing with Copilot: Exploring Prompt Engineering for Solving CS1 Problems Using Natural Language,” in Proceedings of the 54th ACM Technical Symposium on Computer Science Education V. 1, ser. SIGCSE 2023. New York, NY, USA: Association for Computing Machinery, Mar. 2023, pp. 1136–1142. [Online]. Available: https://dl.acm.org/doi/10.1145/3545945.3569823
- S. MacNeil, A. Tran, J. Leinonen, P. Denny, J. Kim, A. Hellas, S. Bernstein, and S. Sarsa, “Automatically Generating CS Learning Materials with Large Language Models,” in Proceedings of the 54th ACM Technical Symposium on Computer Science Education V. 2, Mar. 2022, pp. 1176–1176, arXiv:2212.05113 [cs]. [Online]. Available: http://arxiv.org/abs/2212.05113
- S. MacNeil, A. Tran, A. Hellas, J. Kim, S. Sarsa, P. Denny, S. Bernstein, and J. Leinonen, “Experiences from Using Code Explanations Generated by Large Language Models in a Web Software Development E-Book,” in Proceedings of the 54th ACM Technical Symposium on Computer Science Education V. 1, ser. SIGCSE 2023. New York, NY, USA: Association for Computing Machinery, Mar. 2023, pp. 931–937. [Online]. Available: https://dl.acm.org/doi/10.1145/3545945.3569785
- S. MacNeil, A. Tran, D. Mogil, S. Bernstein, E. Ross, and Z. Huang, “Generating Diverse Code Explanations using the GPT-3 Large Language Model,” in Proceedings of the 2022 ACM Conference on International Computing Education Research - Volume 2, ser. ICER ’22, vol. 2. New York, NY, USA: Association for Computing Machinery, Aug. 2022, pp. 37–39. [Online]. Available: https://dl.acm.org/doi/10.1145/3501709.3544280
- A. Taylor, A. Vassar, J. Renzella, and H. Pearce, “dcc –help: Transforming the Role of the Compiler by Generating Context-Aware Error Explanations with Large Language Models,” in Proceedings of the 55th ACM Technical Symposium on Computer Science Education V. 1, ser. SIGCSE 2024. New York, NY, USA: Association for Computing Machinery, Mar. 2024, pp. 1314–1320. [Online]. Available: https://dl.acm.org/doi/10.1145/3626252.3630822
Sponsored by Paperpile, the PDF & BibTeX manager trusted by top AI labs.
Get 30 days freePaper Prompts
Sign up for free to create and run prompts on this paper using GPT-5.
Top Community Prompts
Collections
Sign up for free to add this paper to one or more collections.