Manuscript Offprint

arXiv:2608.29745

JITterFlip: Uncovering Fault Attack Surfaces in JIT-Compiled LLM Serving

Tairui Wang, Zhi Zhang, Yansong Gao, Xin Zhang, Qingni Shen, Zhonghai Wu

Abstract

LLMs are widely deployed through cloud-hosted inference services, where Just-in-Time (JIT) compilation is used to reduce recurring framework and GPU-launch overhead. JIT serving introduces a host-side control plane that selects compiled artifacts and orchestrates their execution on the GPU. Meanwhile, the shared cloud setting has motivated a growing body of bit-flip attacks (BFAs) against LLM/DNN inference. Most existing BFAs target model parameters/weights require model-specific knowledge. A smaller body of work reduces this dependency by faulting executable code, yet still corrupts code that directly implements model computation, limiting their attack effect to inference depletion.

We present JITterFlip, the first BFA targeting the host-side JIT serving control plane of GPU-based LLM inference. By faulting CPU-resident serving decisions rather than model computation, JITterFlip enables both gibberish output generation and a correct-output sponge attack. To identify exploitable targets in a large JIT compiler stack, JITterFlip develops a decision-guided fault-vulnerable code analysis.

Across four text and multimodal LLM workloads, the identified vulnerable code faults exhibit cross-model transferability, produce gibberish outputs with PPL ratios of 15.45× to 2.48×10⁶×, and demonstrate correct-output sponge attacks with latency amplification of 2.03× to 181.90×. JITterFlip also bypasses recent BFA defenses for LLMs while retaining both attack effects. Last, we demonstrate end-to-end Rowhammer attacks across four LLMs: a single bit flip in CPU-resident branch code propagates across the CPU-GPU boundary to disrupt GPU-executed inference without direct access to GPU memory, reaching up to 7.23×10⁶× PPL amplification or 124.97× latency amplification while preserving the exact generated output.

1 Introduction

Large language models (LLMs) have become foundational to modern AI systems, supporting a broad range of text, code, reasoning, document-analysis, and multimodal applications [53, 70]. Their rapid adoption has also driven increas-

ing demand for efficient inference serving. Just-in-Time (JIT) compilation is particularly attractive for LLM serving because autoregressive generation repeatedly exercises the model execution path. It significantly reduces the recurring framework and GPU-launch overhead by reusing optimized compiled execution, while retaining runtime specialization for changing serving conditions. This execution mode has received mainstream support. For example, vLLM V1 enables PyTorch torch.compile by default and combines compiled-code caching, shape specialization, and CUDA-Graph execution to accelerate LLM serving [58–60].

Meanwhile, LLMs are widely served through cloud-hosted GPU/CPU platforms and model-as-a-service APIs, where mutually untrusted tenants may co-reside on the same physical hardware. This deployment setting has motivated a large body of bit-flip attacks (BFAs) against LLMs (including DNNs) [8, 11, 12, 21, 27, 29, 32, 35–37, 40, 41, 49, 56, 64, 67]. Among them, practical BFAs leverage Rowhammer [34] to demonstrate their end-to-end attacks. However, existing BFAs have largely focused on corrupting the model computation. Most target model parameters or weights and thus require knowledge of the victim model's architecture, weights, or quantization representation to identify fault-vulnerable bits [12, 21, 27, 32, 49, 64, 67].

A smaller body of work instead targets executable code [13, 35]. Still, they operate on the computation plane of DNN inference. Particularly, FrameFlip [35] faults a precompiled numerical library (i.e., OpenBLAS). Compiled Models [13] faults the .text section of model executables generated by DL compilers. While they target different code surfaces, both corrupt code that directly implements model computation. Thus, their demonstrated effects are limited to inference depletion, where faulty computation results in corrupted model outputs, making such attacks detectable by existing output-based defenses [14, 54, 71].

JIT-compiled LLM serving introduces a fundamentally different code surface where a CPU host-side serving control plane that orchestrates compiled computation rather than implementing the model arithmetic itself. This control logic determines which compiled artifact serves the current execu-tion and whether and how the selected computation is issued to the GPU. In the PyTorch compiler stack, the control plane spans across different components (e.g., Dynamo frame dispatch). Thus, while prior executable-code BFAs corrupt the code that performs model computation, JIT-compiled serving exposes control logic that orchestrates its execution.

This motivates our work which shifts the BFA target from model computation to serving control plane. We observe that faulting the control plane can disrupt GPU inference while keeping model weights and GPU kernels intact. More importantly, it can keep the model output correct as the faulted execution is redirected to a semantically valid but significantly more expensive path, enabling a correct-output sponge attack [52]. Unlike inference depletion, this attack preserves model semantics and is thus difficult to detect from output correctness alone.

To systematically study this unexplored attack surface, we present JITterFlip, the first BFAs against the JIT serving control plane of LLM inference. We focus on two families of inference-critical decisions implemented by host-side JIT control code. Compiled-artifact selection determines which compiled execution path serves the current inference. GPU-work submission determines whether and how the selected computation is issued to the GPU. Consequently, faulting the former logic can redirect inference onto a much slower but semantically valid execution path, producing the correct-output sponge effect. Faulting the latter can suppress or misdirect required GPU computation and produce gibberish outputs while keeping the process alive.

The key challenge is to identify exploitable fault targets in a large and complex JIT compiler stack, where a substantial amount of code implements compilation bookkeeping, error handling, and other auxiliary control rather than inference-critical decisions. FrameFlip [35] searches a fault target by exhaustively enumerating and testing every conditional branches within a specific computing function (i.e., cblas_dgemm). Thus, this search approach does not scale to JIT-compiled LLM serving where the control plane spans multiple compiler and runtime components. Also, an exploitable target should not only alter serving behavior, but also preserve continued execution rather than crashing the execution. It is prohibitively inefficient to exhaustively faulting and evaluating this much larger search space.

To address this challenge, JITterFlip employs a decision-guided fault-vulnerable code analysis against the targeted PyTorch compiler stack. We first manually reconstruct the JIT serving lifecycle and localize control logic associated with compiled-artifact selection and GPU-work submission. This semantic characterization reduces the analysis scope from 181 files and 139.1K SLoC in the host-side JIT stack to 34 files and 34.7K SLoC of decision-relevant control logic. We further abstract recurring conditional-control patterns that contribute to the decision-making logic. Guided by these patterns, we propose an automated LLVM Intermediate Representation (IR) analysis to examine the reduced files, resulting in 36,861 conditional branches. The analysis then builds separate ranking lists for the two attack objectives by assessing how strongly each resulted branch is associated with inference-critical control decisions that can lead to gibberish output generation or sponge effect. For top-20 from each list, JITterFlip identifies 5 output-corruption branches and 10 latency-amplification branches.

We evaluate the severity and transferability of the identified branch targets across four LLMs: Qwen3-8B and DeepSeek-R1-Distill-Qwen-7B on text-generation workloads based on WikiText-2, and Gemma-3-4B and Qwen2.5-VL-7B on multimodal workloads based on ScienceQA. The identified targets produce gibberish outputs with PPL ratios ranging from 15.45×15.45\times to 2.48×106×2.48\times10^{6}\times, or demonstrate a sponge attack by increasing the request latency by 2.03×2.03\times to 181.90×181.90\times. The branch faults also exhibit cross-model transferability: multiple branches remain effective across different LLMs and workloads while preserving both attack effects. Further, we evaluate JITterFlip against two complimentary BFA defenses for LLMs, FaR [45] and LM-Fix [54]. JITterFlip successfully bypasses both defenses and retains both attack effects. These results expose a protection gap in existing BFA defenses for LLMs, as they do not cover the JIT serving control plane targeted by JITterFlip.

Last, we demonstrate the exploitability of the identified branch targets through end-to-end Rowhammer attacks. Importantly, JITterFlip induces bit flips entirely in CPU-resident branch target, and the resulting corruption of JIT serving decisions propagates across the CPU–GPU boundary and disrupts GPU-executed LLM inference, without requiring direct access to GPU memory. Across all four LLMs, the Rowhammer attacks produce gibberish outputs with PPL ratios from 287.3×287.3\times to 7.23×1067.23\times10^{6}, or demonstrate a correct-output sponge attack that preserves the generated output while increasing the request latency by 97.38×97.38\times to 124.97×124.97\times.

References (56)

  • Deep-troj: An inference stage trojan insertion algorithm through efficient weight replacement attack
  • Ghosting your llm: Without the knowledge of your gradient and data (opens arXiv in a new tab)
  • PyTorch 2: Faster Machine Learning Through Dynamic Python Bytecode Transformation and Graph Compilation
  • Compilation of a countermeasure against instruction-skip fault attacks
  • Practical fault attack on deep neural networks
  • Proflip: Targeted trojan attack with progressive bit flips
  • Compiled models, built-in exploits: Uncovering pervasive bit-flip attack surfaces in dnn executables
  • Bitshield: Defending against bit-flip attacks on dnn executables
  • Bit-flip error resilience in llms: A comprehensive analysis and defense framework
  • Camfas: A compiler approach to mitigate fault attacks via enhanced simdization
  • Prisonbreak: Jailbreaking large language models with fewer than twenty-five targeted bit-flips
  • Exploiting correcting codes: on the effectiveness of ECC memory against rowhammer attacks
  • Intel sgx explained
  • Abstract interpretation: A unified lattice model for static analysis of programs by construction or approximation of fixpoints
  • Attentionbreaker: Adaptive evolutionary optimization for unmasking vulnerabilities in llms through bit-flip attacks
  • An engorgio prompt makes large language model babble on
  • Trespass: Exploiting the many sides of target row refresh
  • Inducing high energy-latency of large vision-language models with verbose images
  • Another flip in the wall of rowhammer defenses
  • Sbfa: Single sneaky bit flip attack to break large language models (opens arXiv in a new tab)
  • Tfl: Targeted bit-flip attack on large language model (opens arXiv in a new tab)
  • Terminal brain damage: Exposing the graceless degradation in deep neural networks under hardware fault attacks
  • Blacksmith: Scalable rowhammering in the frequency domain
  • ECC. fail: Mounting rowhammer attacks on DDR4 servers with ECC memory
  • Flipllm: Efficient bit-flip attacks on multimodal llms using reinforcement learning (opens arXiv in a new tab)
  • Flipping bits in memory without accessing them: an experimental study of DRAM disturbance errors
  • Yes, One-Bit-Flip matters! universal DNN model inference depletion with runtime code fault injection
  • Backdoor attacks on neural networks via one-bit flip
  • {Rowhammer-Based} trojan injection: One bit flip is sufficient for backdooring {DNNs}
  • LoopLLM: Transferable energy-latency attacks in LLMs via repetitive generation
  • Achilles: A formal framework of leaking secrets from signature schemes via rowhammer
  • GPUHammer: Rowhammer attacks on GPU memories are practical
  • Fault injection attack on deep neural network
  • Phoenix: Rowhammer attacks on ddr5 with self-correcting synchronization
  • Fpga-accelerated defense architecture for efficient bit-flip attack resilience in transformer models
  • Forget and rewire: Enhancing the resilience of transformer-based models against Bit-Flip attacks
  • Principles of Program Analysis
  • {DRAMA}: Exploiting {DRAM} addressing for {Cross-CPU} attacks
  • Tbt: Targeted neural network attack with bit trojan
  • Precise interprocedural dataflow analysis via graph reachability
  • Two approaches to interprocedural data flow analysis
  • Sponge examples: Energy-latency attacks on neural networks
  • Nature, 620(7972):172–180, 2023
  • Lm-fix: Lightweight bit-flip detection and rapid recovery framework for language models
  • Don't knock! rowhammer at the backdoor of dnn models
  • Your scale factors are my weapon: Targeted bit-flip attacks on vision transformers via scale factor manipulation
  • Aegis: Mitigating targeted bit-flip attacks against deep neural networks
  • Dramdig: A knowledge-assisted tool to uncover dram address mapping
  • Silentstriker: Toward stealthy bit-flip attacks on large language models
  • Bithydra: Towards bit-flip inference cost attack against large language models (opens arXiv in a new tab)
  • Has the two-decade-old prophecy come true? artificial bad intelligence triggered by merely a single-bit flip in large language models
  • {DeepHammer}: Depleting the intelligence of deep neural networks through targeted chain of bit flips
  • Orca: A distributed serving system for Transformer-Based generative models
  • SoK: Rowhammer on commodity operating systems
  • A Survey of Large Language Models
  • SAVE:software-implemented fault tolerance for model inference against gpu memory bit flips