Bin Gu
Current Organizations / Institutes
The organizations/institutes from the scholar's latest article
Research Subjects
Bin Gu has a total of 73 co-authors. Here are the top co-authors by number of shared publications:
- Xiaofeng Li
The Space Optoelectronic Measurement and Perception Lab Beijing Institute of Control Engineering 100086 Street Beijing China
5 shared publications - Longxing Yang
Beijing Institute of Control Engineering, Beijing, China
3 shared publications - Mengfei Yang
China Academy of Space Technology
3 shared publications - Yixing Luo
Software Department, Beijing Institute of Control Engineering, Beijing 100190, China
3 shared publications - Yu Jiang
Tsinghua University, Beijing, China
3 shared publications - Zhi Jin
Peking University
3 shared publications
Latest Publications
- 1 November 2026
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Software Engineering
- Vol. 52 (11) , 3291-3302
Generalization or Memorization: Data Contamination for Large Language Models in Code Generation
- 1 November 2026
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Software Engineering
- Vol. 52 (11) , 3291-3302
Generalization or Memorization: Data Contamination for Large Language Models in Code Generation
- Open Access
- 7 October 2026
- Published by Association for Computing Machinery (ACM)
- p. 3557-3561
AutoFLC: An LLM-Based Flowchart Generation Tool for Legacy Code Repository
- 7 October 2026
- Published by Association for Computing Machinery (ACM)
- p. 3557-3561
Open AccessAutoFLC: An LLM-Based Flowchart Generation Tool for Legacy Code Repository
- Open Access
- 28 September 2026
- Published by Association for Computing Machinery (ACM) in ACM Transactions on Embedded Computing Systems
MARS 2.0: A Toolchain for Designing Safety-Critical Cyber-Physical Systems
This paper presents MARS 2.0, an integrated toolchain for the model-driven design of safety-critical Cyber-Physical Systems (CPSs). MARS 2.0 supports an end-to-end workflow spanning unified modeling, formal verification, and trusted code generation. Building on its predecessor, MARS 2.0 introduces three key enhancements: (1) a co-modeling framework that combines AADL (for system architecture) and Simulink/Stateflow (for functional and physical behaviors)—denoted \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) ; (2) provers based on Hybrid Hoare Logic (HHL) for verifying formal models; and (3) correct-by-construction code generation from verified models. In MARS 2.0, users first construct an \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) model to capture the system’s architecture, control logic, and continuous dynamics in a unified framework. This model is then automatically translated into Hybrid Communicating Sequential Processes (HCSP), a formal modeling language for hybrid systems. The resulting HCSP program can be (1) simulated for rapid validation, and (2) formally verified using the HHLProver suite. Finally, once verified, the HCSP model is compiled into executable ANSI-C or SystemC code. Critically, both the “ \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) to HCSP” translation and the “HCSP to ANSI-C/SystemC” code generation are backed by formal proofs of semantic preservation. By bridging industrial modeling notations with formal methods, MARS 2.0 makes rigorous CPS development accessible to engineers.- 28 September 2026
- Published by Association for Computing Machinery (ACM) in ACM Transactions on Embedded Computing Systems
Open AccessMARS 2.0: A Toolchain for Designing Safety-Critical Cyber-Physical Systems
This paper presents MARS 2.0, an integrated toolchain for the model-driven design of safety-critical Cyber-Physical Systems (CPSs). MARS 2.0 supports an end-to-end workflow spanning unified modeling, formal verification, and trusted code generation. Building on its predecessor, MARS 2.0 introduces three key enhancements: (1) a co-modeling framework that combines AADL (for system architecture) and Simulink/Stateflow (for functional and physical behaviors)—denoted \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) ; (2) provers based on Hybrid Hoare Logic (HHL) for verifying formal models; and (3) correct-by-construction code generation from verified models. In MARS 2.0, users first construct an \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) model to capture the system’s architecture, control logic, and continuous dynamics in a unified framework. This model is then automatically translated into Hybrid Communicating Sequential Processes (HCSP), a formal modeling language for hybrid systems. The resulting HCSP program can be (1) simulated for rapid validation, and (2) formally verified using the HHLProver suite. Finally, once verified, the HCSP model is compiled into executable ANSI-C or SystemC code. Critically, both the “ \(\textsf {AADL}\!\oplus \!\textsf {S/S} \) to HCSP” translation and the “HCSP to ANSI-C/SystemC” code generation are backed by formal proofs of semantic preservation. By bridging industrial modeling notations with formal methods, MARS 2.0 makes rigorous CPS development accessible to engineers. - Open Access
- 11 May 2026
- Published by Association for Computing Machinery (ACM)
- p. 1-15
Derivative-Agnostic Inference of Nonlinear Hybrid Systems
- 11 May 2026
- Published by Association for Computing Machinery (ACM)
- p. 1-15
Open AccessDerivative-Agnostic Inference of Nonlinear Hybrid Systems
- Open Access
- 10 April 2026
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 10 (OOPSLA1) , 1874-1902
A Tale of 1001 LoC: Potential Runtime Error-Guided Specification Synthesis for Verifying Large-Scale Programs
Fully automated verification of large-scale software and hardware systems is arguably the holy grail of formal methods. Large language models (LLMs) have recently demonstrated their potential for enhancing the degree of automation in formal verification by, e.g., generating formal specifications as essential to deductive verification, yet exhibit poor scalability due to long-context reasoning limitations and, more importantly, the difficulty of inferring complex, interprocedural specifications. This paper presents Preguss - a modular, fine-grained framework for automating the generation and refinement of formal specifications. Preguss synergizes between static analysis and deductive verification by steering two components in a divide-and-conquer fashion: (i) potential runtime error-guided construction and prioritization of verification units, and (ii) LLM-aided synthesis of interprocedural specifications at the unit level. We show that Preguss substantially outperforms state-of-the-art LLM-based approaches and, in particular, it enables highly automated RTE-freeness verification for real-world programs with over a thousand LoC, with a reduction of 80.6%~88.9% human verification effort.
- 10 April 2026
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 10 (OOPSLA1) , 1874-1902
Open AccessA Tale of 1001 LoC: Potential Runtime Error-Guided Specification Synthesis for Verifying Large-Scale Programs
Fully automated verification of large-scale software and hardware systems is arguably the holy grail of formal methods. Large language models (LLMs) have recently demonstrated their potential for enhancing the degree of automation in formal verification by, e.g., generating formal specifications as essential to deductive verification, yet exhibit poor scalability due to long-context reasoning limitations and, more importantly, the difficulty of inferring complex, interprocedural specifications. This paper presents Preguss - a modular, fine-grained framework for automating the generation and refinement of formal specifications. Preguss synergizes between static analysis and deductive verification by steering two components in a divide-and-conquer fashion: (i) potential runtime error-guided construction and prioritization of verification units, and (ii) LLM-aided synthesis of interprocedural specifications at the unit level. We show that Preguss substantially outperforms state-of-the-art LLM-based approaches and, in particular, it enables highly automated RTE-freeness verification for real-world programs with over a thousand LoC, with a reduction of 80.6%~88.9% human verification effort.
- 26 July 2025
- Published by Springer Nature
- p. 518-530
Oneshotimizer: Consistent and Effective NAS via Regularizing Gradient Norm and Weight Variance
- 26 July 2025
- Published by Springer Nature
- p. 518-530
Oneshotimizer: Consistent and Effective NAS via Regularizing Gradient Norm and Weight Variance
- Open Access
- 23 June 2025
- Published by Association for Computing Machinery (ACM)
- p. 366-377
Evaluating Large Language Models for Requirements Question Answering in Industrial Aerospace Software
- 23 June 2025
- Published by Association for Computing Machinery (ACM)
- p. 366-377
Open AccessEvaluating Large Language Models for Requirements Question Answering in Industrial Aerospace Software
- Open Access
- 22 June 2025
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Software Engineering
- Vol. 2 (ISSTA) , 2113-2135
STRUT: Structured Seed Case Guided Unit Test Generation for C Programs using LLMs
Unit testing plays a crucial role in bug detection and ensuring software correctness. It helps developers identify errors early in development, thereby reducing software defects. In recent years, large language models (LLMs) have demonstrated significant potential in automating unit test generation. However, using LLMs to generate unit tests faces many challenges. 1) The execution pass rate of the test cases generated by LLMs is low. 2) The test case coverage is inadequate, making it challenging to detect potential risks in the code. 3) Current research methods primarily focus on languages such as Java and Python, while studies on C programming are scarce, despite its importance in the real world. To address these challenges, we propose STRUT, a novel unit test generation method. STRUT utilizes structured test cases as a bridge between complex programming languages and LLMs. Instead of directly generating test code, STRUT guides LLMs to produce structured test cases, thereby alleviating the limitations of LLMs when generating code for programming languages with complex features. First, STRUT analyzes the context of focal methods and constructs structured seed test cases for them. These seed test cases then guide LLMs to generate a set of structured test cases. Subsequently, a rule-based approach is employed to convert the structured set of test cases into executable test code. We conducted a comprehensive evaluation of STRUT, which achieved an impressive execution pass rate of 96.01%, along with 77.67% line coverage and 63.60% branch coverage. This performance significantly surpasses that of the LLMs-based baseline methods and the symbolic execution tool SunwiseAUnit. These results highlight STRUT's superior capability in generating high-quality unit test cases by leveraging the strengths of LLMs while addressing their inherent limitations.
- 22 June 2025
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Software Engineering
- Vol. 2 (ISSTA) , 2113-2135
Open AccessSTRUT: Structured Seed Case Guided Unit Test Generation for C Programs using LLMs
Unit testing plays a crucial role in bug detection and ensuring software correctness. It helps developers identify errors early in development, thereby reducing software defects. In recent years, large language models (LLMs) have demonstrated significant potential in automating unit test generation. However, using LLMs to generate unit tests faces many challenges. 1) The execution pass rate of the test cases generated by LLMs is low. 2) The test case coverage is inadequate, making it challenging to detect potential risks in the code. 3) Current research methods primarily focus on languages such as Java and Python, while studies on C programming are scarce, despite its importance in the real world. To address these challenges, we propose STRUT, a novel unit test generation method. STRUT utilizes structured test cases as a bridge between complex programming languages and LLMs. Instead of directly generating test code, STRUT guides LLMs to produce structured test cases, thereby alleviating the limitations of LLMs when generating code for programming languages with complex features. First, STRUT analyzes the context of focal methods and constructs structured seed test cases for them. These seed test cases then guide LLMs to generate a set of structured test cases. Subsequently, a rule-based approach is employed to convert the structured set of test cases into executable test code. We conducted a comprehensive evaluation of STRUT, which achieved an impressive execution pass rate of 96.01%, along with 77.67% line coverage and 63.60% branch coverage. This performance significantly surpasses that of the LLMs-based baseline methods and the symbolic execution tool SunwiseAUnit. These results highlight STRUT's superior capability in generating high-quality unit test cases by leveraging the strengths of LLMs while addressing their inherent limitations.
- Open Access
- 27 October 2024
- Published by Association for Computing Machinery (ACM)
- p. 117-128
Test Case Generation for Simulink Models using Model Fuzzing and State Solving
Simulink plays an important role in the industry for modeling and synthesis of embedded systems. Ensuring system stability requires using numerous test cases to validate the functionality and safety of the models. However, as requirements increase, the complexity of the models poses new challenges to traditional testing methods. Traditional methods such as constraint solving and random search run into significant obstacles when navigating the complex branching logic and states within models. In this paper, we introduce HybridTCG, a test case generation method by collaborating model fuzzing and state solving for Simulink models. First, HybridTCG starts a code-based fuzzer to generate high-coverage test cases rapidly. Then, it refines the test cases generated by the fuzzer, preserving only those that can achieve new model coverage. These selected test cases are input into the state-solving engine to derive corresponding states and resolve the constraints of subsequent branches. Ultimately, the test cases produced by the solving engine will be fed back into the fuzzer as high-quality seeds to enhance the fuzzing process. We have implemented HybridTCG and conducted a comprehensive evaluation using various benchmark Simulink models. Compared to the built-in Simulink Design Verifier and state-of-the-art academic work SimCoTest and STCG, HybridTCG achieves an average improvement of 54%, 108% and 24% on Decision Coverage, 50%, 62% and 6% on Condition Coverage, 291%, 282% and 45% on Modified Condition Decision Coverage, respectively. Moreover, HybridTCG is also much more efficient in testing than other tools.
- 27 October 2024
- Published by Association for Computing Machinery (ACM)
- p. 117-128
Open AccessTest Case Generation for Simulink Models using Model Fuzzing and State Solving
Simulink plays an important role in the industry for modeling and synthesis of embedded systems. Ensuring system stability requires using numerous test cases to validate the functionality and safety of the models. However, as requirements increase, the complexity of the models poses new challenges to traditional testing methods. Traditional methods such as constraint solving and random search run into significant obstacles when navigating the complex branching logic and states within models. In this paper, we introduce HybridTCG, a test case generation method by collaborating model fuzzing and state solving for Simulink models. First, HybridTCG starts a code-based fuzzer to generate high-coverage test cases rapidly. Then, it refines the test cases generated by the fuzzer, preserving only those that can achieve new model coverage. These selected test cases are input into the state-solving engine to derive corresponding states and resolve the constraints of subsequent branches. Ultimately, the test cases produced by the solving engine will be fed back into the fuzzer as high-quality seeds to enhance the fuzzing process. We have implemented HybridTCG and conducted a comprehensive evaluation using various benchmark Simulink models. Compared to the built-in Simulink Design Verifier and state-of-the-art academic work SimCoTest and STCG, HybridTCG achieves an average improvement of 54%, 108% and 24% on Decision Coverage, 50%, 62% and 6% on Condition Coverage, 291%, 282% and 45% on Modified Condition Decision Coverage, respectively. Moreover, HybridTCG is also much more efficient in testing than other tools.
- Open Access
- 18 October 2024
- Published by Cambridge University Press (CUP) in Research Directions: Cyber-Physical Systems
- Vol. 2, 1-8
Reset controller synthesis: a correct-by-construction way to the design of CPS
Controller synthesis offers a correct-by-construction methodology to ensure the correctness and reliability of safety-critical cyber-physical systems (CPS). Controllers are classified based on the types of controls they employ, which include reset controllers, feedback controllers and switching logic controllers. Reset controllers steer the behavior of a CPS to achieve system objectives by restricting its initial set and redefining its reset map associated with discrete jumps. Although the synthesis of feedback controllers and switching logic controllers has received considerable attention, research on reset controller synthesis is still in its early stages, despite its theoretical and practical significance. This paper outlines our recent efforts to address this gap. Our approach reduces the problem to computing differential invariants and reach-avoid sets. For polynomial CPS, the resulting problems can be solved by further reduction to convex optimizations. Moreover, considering the inevitable presence of time delays in CPS design, we further consider synthesizing reset controllers for CPS that incorporate delays.
- 18 October 2024
- Published by Cambridge University Press (CUP) in Research Directions: Cyber-Physical Systems
- Vol. 2, 1-8
Open AccessReset controller synthesis: a correct-by-construction way to the design of CPS
Controller synthesis offers a correct-by-construction methodology to ensure the correctness and reliability of safety-critical cyber-physical systems (CPS). Controllers are classified based on the types of controls they employ, which include reset controllers, feedback controllers and switching logic controllers. Reset controllers steer the behavior of a CPS to achieve system objectives by restricting its initial set and redefining its reset map associated with discrete jumps. Although the synthesis of feedback controllers and switching logic controllers has received considerable attention, research on reset controller synthesis is still in its early stages, despite its theoretical and practical significance. This paper outlines our recent efforts to address this gap. Our approach reduces the problem to computing differential invariants and reach-avoid sets. For polynomial CPS, the resulting problems can be solved by further reduction to convex optimizations. Moreover, considering the inevitable presence of time delays in CPS design, we further consider synthesizing reset controllers for CPS that incorporate delays.