Large Language Models (LLMs) are increasingly used for automated vulnerability detection, but it remains unclear how program structure and semantics should be represented for LLM-based reasoning. Most prompting-based approaches provide raw source code, implicitly assuming that more source-level context gives the model better evidence. This paper challenges that assumption through RepBench, an empirical benchmark comparing raw source code with static-analysis-based program representations. RepBench converts real-world C/C++ vulnerability testcases into multiple representations: raw source, Abstract Syntax Trees (ASTs), Control-Flow Graphs (CFGs), Program Dependence Graphs (PDGs), their combinations, and an auxiliary track of enriched PDGs (ePDGs). Using a curated PrimeVul-derived corpus of 107 Joern-based testcases across five CWE categories, we evaluate ten representation variants under a fixed Chain-of-Thought and structured-output protocol, plus 19 additional ePDG cases generated through VulChecker/Hector. Representation choice substantially affects LLM vulnerability reasoning. The strongest variant, AST+PDG, achieves 83.2% accuracy, compared with 53.5% for raw source. At the family level, graph-only prompts outperform both source-only and source-plus-graph prompts while requiring far less prompt overhead. These results reveal a context dilution effect: adding raw source code to compact structural graph evidence can degrade reasoning by making vulnerability-relevant evidence less salient. Overall, our findings show that carefully selected structural representations offer a better accuracy-overhead tradeoff than simply giving LLMs more raw input, and suggest that static analysis can serve as an effective prompt-construction layer for security-focused LLM reasoning.
DREA: Decoupled Reasoning and Exploration Agents for Repository-Level Vulnerability Detection
Institute of Information Engineering, Chinese Academy of Sciences(中国科学院信息工程研究所);School of Cyber Security, University of Chinese Academy of Sciences(中国科学院大学网络安全学院)
LLM4Vuln: A Unified Evaluation Framework for Decoupling and Enhancing LLMs' Vulnerability Reasoning
Nanyang Technological University, Singapore(南洋理工大学);The Hong Kong University of Science(香港科学与技术大学);MetaTrust Labs(MetaTrust实验室);Singapore Management University, Singapore(新加坡管理学院);University of Oregon, Eugene, OR, USA(俄勒冈大学)
VulReaD: Knowledge-Graph-guided Software Vulnerability Reasoning and Detection
The University of Manchester(曼彻斯特大学);Agency for Science, Technology and Research(科技研究局);Singapore University of Technology and Design(新加坡科技设计大学);Mohamed Bin Zayed University of Artificial Intelligence(穆罕默德·本·扎耶德人工智能大学)
Graph Neural Networks for Vulnerability Detection: A Counterfactual Explanation
School of Computer Science and Technology, Huazhong University of Science and Technology(华中科技大学计算机科学与技术学院);School of Electrical Engineering, Computing and Mathematical Sciences, Curtin University(科廷大学电气、计算与数学科学学院);School of Big Data and Software Engineering, Chongqing University(重庆大学大数据与软件学院);School of Computer Science and Engineering, University of New South Wales(新南威尔士大学计算机科学与工程学院)
VulnLLM-R: Specialized Reasoning LLM with Agent Scaffold for Vulnerability Detection
Department of Computer Science, University of California, Santa Barbara, CA, USA(加州大学圣芭芭拉分校计算机科学系);Department of Computer Science, University of Chicago, Chicago, IL, USA(芝加哥大学计算机科学系);Department of Electrical Engineering and Computer Sciences, University of California, Berkeley, CA, USA(加州大学伯克利分校电子工程与计算机科学系);Department of Computer Science, University of Illinois Urbana-Champaign, Champaign, IL, USA(伊利诺伊大学厄巴纳-香槟分校计算机科学系)
Improving LLM Reasoning for Vulnerability Detection via Group Relative Policy Optimization
Institute of Informatics and Telematics, National Research Council of Italy(意大利国家研究理事会信息与电信研究所);Department of Excellence in Robotics and AI, TeCIP, Scuola Superiore Sant'Anna(卓越机器人与人工智能系,TeCIP,圣安娜高等学院)
Dipartimento di Ingegneria Elettrica e Elettronica, Università di Cagliari(卡利亚里大学电气与电子工程系);Interuniversity National Consortium for Informatics, CINI(意大利国家信息学大学联盟)