Lightweight Blockchain Verification for IoT: ARust-Python Hybrid Approach with 4.35×Throughput Gain and 75% Energy Reduction
Abstract
Abstract The integration of Internet of Things (IoT) and blockchain technologies enables secure, decentralized data management for real-time applications. However, limitations in processor, memory, and energy resources restrict the direct processing of large datasets. Notably, Garbage Collector (GC) mechanisms in high-level languages increase variance in P99 queue latencies, while expanding data volumes can result in system crashes due to Out-of-Memory (OOM) errors. This study introduces a hybrid Rust-Python Simplified Payment Verification (SPV) native hashing engine deployed on resource-constrained edge devices (Raspberry Pi Zero W) and high-capacity gateways (Raspberry Pi 5). Laboratory evaluations demonstrate that the hybrid system achieves a verification capacity of 34,000 Merkle nodes per second, representing a 4.35-fold speed improvement over pure Python on the Pi Zero W. Additionally, the system reduces GC-induced latency fluctuations and offers up to 75% potential energy savings, as indicated by theoretical modeling based on active processor cycle analyses. Bottleneck analyses on Raspberry Pi 5 indicate that Foreign Function Interface (FFI)-related data transfer costs limit parallel processing benefits for low-volume datasets. In contrast, the scalability of the hybrid architecture is evident with datasets containing 1.5 million records. The memory-mapped streaming architecture minimizes OOM risks and achieves a cache miss rate of 0.34%. Memory safety was assessed using the MIRI tool.
Community
0 commentsNo discussion yet
Be the first to share a question or observation.