Mohammadhossein Amouei;Benjamin C. M. Fung;Philippe Charland;Jun Meng
{"title":"LENA: Llama-Based Embeddings of Neutralized Assembly for Cross-Compiler/Optimization Binary Code Similarity Detection","authors":"Mohammadhossein Amouei;Benjamin C. M. Fung;Philippe Charland;Jun Meng","doi":"10.1109/TSE.2026.3705321","DOIUrl":null,"url":null,"abstract":"Binary code similarity detection (BCSD) is fundamental to software security, yet remains challenging under cross-compiler and cross-optimization settings. Existing methods often rely on contrastive objectives that are sensitive to false negatives, while recent alternatives may learn redundant embeddings that limit fine-grained discrimination. In this paper, we present LENA, a BCSD framework that adapts a Llama backbone through an optimization-translation task and trains a lightweight projector using a hybrid objective that combines contrastive learning with variance and covariance regularization. Experiments on x86-64 benchmarks show that LENA outperforms state-of-the-art baselines, improving average Recall@1 by 10.45% on GCC, 5.36% on Clang, and 8.55% in cross-compiler settings, while also improving average R-Precision in vulnerability detection. We further provide a supporting tie-aware evaluation analysis and introduce Tie-sensitive Reciprocal Rank (TsRR), which provides deterministic reciprocal-rank-based reporting when tied similarity scores occur and reduces ambiguity in BCSD evaluation.","PeriodicalId":13324,"journal":{"name":"IEEE Transactions on Software Engineering","volume":"52 10","pages":"2946-2969"},"PeriodicalIF":6.0000,"publicationDate":"2026-10-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"IEEE Transactions on Software Engineering","FirstCategoryId":"94","ListUrlMain":"https://ieeexplore.ieee.org/document/11570086/","RegionNum":1,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"2026/6/18 0:00:00","PubModel":"Epub","JCR":"Q1","JCRName":"COMPUTER SCIENCE, SOFTWARE ENGINEERING","Score":null,"Total":0}
引用次数: 0
Abstract
Binary code similarity detection (BCSD) is fundamental to software security, yet remains challenging under cross-compiler and cross-optimization settings. Existing methods often rely on contrastive objectives that are sensitive to false negatives, while recent alternatives may learn redundant embeddings that limit fine-grained discrimination. In this paper, we present LENA, a BCSD framework that adapts a Llama backbone through an optimization-translation task and trains a lightweight projector using a hybrid objective that combines contrastive learning with variance and covariance regularization. Experiments on x86-64 benchmarks show that LENA outperforms state-of-the-art baselines, improving average Recall@1 by 10.45% on GCC, 5.36% on Clang, and 8.55% in cross-compiler settings, while also improving average R-Precision in vulnerability detection. We further provide a supporting tie-aware evaluation analysis and introduce Tie-sensitive Reciprocal Rank (TsRR), which provides deterministic reciprocal-rank-based reporting when tied similarity scores occur and reduces ambiguity in BCSD evaluation.
期刊介绍:
IEEE Transactions on Software Engineering seeks contributions comprising well-defined theoretical results and empirical studies with potential impacts on software construction, analysis, or management. The scope of this Transactions extends from fundamental mechanisms to the development of principles and their application in specific environments. Specific topic areas include:
a) Development and maintenance methods and models: Techniques and principles for specifying, designing, and implementing software systems, encompassing notations and process models.
b) Assessment methods: Software tests, validation, reliability models, test and diagnosis procedures, software redundancy, design for error control, and measurements and evaluation of process and product aspects.
c) Software project management: Productivity factors, cost models, schedule and organizational issues, and standards.
d) Tools and environments: Specific tools, integrated tool environments, associated architectures, databases, and parallel and distributed processing issues.
e) System issues: Hardware-software trade-offs.
f) State-of-the-art surveys: Syntheses and comprehensive reviews of the historical development within specific areas of interest.