ARCHIVES

Original Article

Design and FPGA Implementation of GELU Activation Function Using Verilog HDL

Dr. Nuthan AC1 Shruthi V2 Monish Gowda D S3
1 2 3 Department of Electronics and Communication Engineering, GMIT, Bharathinagara, Karnataka, India.

Published Online: July-August 2026

Pages: 01-14

Abstract

Deep neural networks increasingly rely on smooth, non-monotonic activation functions such as the Gaussian Error Linear Unit (GELU), which has become the default activation in modern transformer and convolutional architectures. While GELU improves accuracy, its exact form involves the Gaussian error function, which is expensive to evaluate in hardware, so deploying such models on resource-constrained edge devices demands a hardware-efficient yet accurate approximation. This work presents the design and FPGA implementation of the GELU activation function using Verilog HDL. The proposed architecture adopts a hybrid CORDIC–polynomial approximation: a lightweight polynomial datapath performs the cubic pre-shaping (x + 0.044715x³) and the √(2/π) scaling, while a pipelined hyperbolic-CORDIC core evaluates the hyperbolic tangent without dedicated multipliers. The complete design uses Q7.25 signed fixed-point arithmetic and a finite-state-machine controller, and is realised as a reconfigurable accelerator supporting GELU, ReLU, and SILU. Following a hardware–software co-design methodology, a bit-accurate Python golden model is used to study quantization and to verify the Verilog implementation, after which the design is synthesised and implemented on the Xilinx Artix-7 (XC7A35T) device of the Basys 3 board using Xilinx Vivado. Functional verification over the input range [−3, +3] shows a maximum absolute error of approximately 1.3 × 10⁻⁴with respect to the ideal GELU. The implemented accelerator consumes 2157 look-up tables (10%), 1856 flip-flops (4%), and 18 DSP slices (20%), dissipates a total on-chip power of 0.182 W, and meets timing at a 100 MHz clock with a positive worst-negative slack of 0.083 ns (maximum frequency ≈ 100.8 MHz). These results demonstrate accurate, low-power, and area-efficient activation computation suitable for real-time neural-network inference in edge-AI and biomedical applications.

Related Articles

2026

Fake Currency Detection Using Deep Learning

2026

Smart E-Commerce System with Dynamic Pricing

2026

Personal Expense Tracker with Currency Converter

2026

Paw Safe: An Extensive Technology-Driven Framework for Stray Dog Rescue, Healthcare Management, Community Engagement, and Smart Urban Governance

2026

Design and Development of a Full-Stack E-Commerce Website

2026

Power quality improvement techniques from a topological perspective: An overview

Share Article

X
LinkedIn
Facebook
WhatsApp

Or copy link

https://www.ijsreat.com/archives/design-and-fpga-implementation-of-gelu-activation-function-using-verilog-hdl

*Instagram doesn't support direct link sharing from web. Copy the link and share it in your Instagram story or post.