Skip to main content

Posts

Showing posts from April, 2021

Regular Pattern Search Using grep, awk and sed

Hello, Dear Readers,   In this post, I will share some deep insights into regular pattern searching using grep, awk, and sed. In VLSI/EDA flows, engineers frequently work with large Innovus, Voltus, STA, EMIR, synthesis and simulation reports. Linux commands such as grep , awk , and sed provide a fast way to search, filter and process this data without opening huge files manually. 1. Regular Expressions: A regular expression (regex) defines a pattern for searching text. Common patterns: Pattern Meaning Example . Any character V.D * Zero or more ab* + One or more ab+ [0-9] Digit U [0-9] [a-z] Lowercase [a-z] + ^ Start of line ^VDD $ End of line VDD$ ` ` OR `VDD VSS` For example: grep -E 'ERROR|WARNING|FATAL' voltus.log Searches for any of the three patterns. 2. grep — Search and Filter: grep is mainly used to find matching lines . Basic search grep 'VIOLATION' report.rpt Case-insensitive search grep -i 'error' run.log Show line numbers grep -n 'VIOLATION...

Carry Lookahead Adder Design And Implementation of Generic Parametrized Adder Using Verilog HDL

  Hello Dear Readers, Today In this post I have designed a carry-lookahead adder design and implemented its parametrized version using Verilog HDL and analysis that design for the desire output. First of all, I have designed CLA based on the theory described in the below video of the Neso Academy.       Verilog Code: module add (a, b, c, g, p, s); // adder and g, p input a, b, c; // inputs: a, b, c; output g, p, s; // outputs: g, p, s; assign s=a ^ b ^ c; // output: sum of inputs assign g = a & b; // output: carry generator assign p = a | b; // output: carry propagator endmodule module gp (g,p,c_in,g_out,p_out,c_out); // carry generator, carry propagator input [1:0] g, p; // lower level 2-set of g, p input c_in; // lower level carry_in output g_out,p_out,c_out; // higher level g, p, carry_out assign g_out = g[1] | p[1] & g[0]; // higher level carry generator assign p_out = p[1] & p[0]; // higher level carry propagator assign c_out = g[0] | p[0] & c_in...