Discovering PERL

As Rick Buskens and I ventured back from eating ice cream on N Craig St street I shared my thesis topic and the simulation challenge it presented. To explore the topic of analog fault modeling I needed to simulate 1000’s of circuits. For every operational op-amp I would be inserting shorts modeled as a 1-ohm resistor. Doing this manually would be tedious. After listening to me bitch and moan Rick simply said “Oh you need to use PERL.”

In Unix land AWK and SED had been scripting languages that others had mentioned. By this point in my short engineering career (~8 years), I had learned BASIC, FORTAN IV, FORTAN 77, APL and PASCAL. Over the summer I had attempted to teach myself “C” to do some of the simulation work by interpreting the HSPICE simulation results of some op-amp operation that my advisor wanted. Funny at the end of the summer I learned that HSPICE had the interpretation function built in- ah if only I had read the user manual. Guideline to all engineers if you think you need to code something to help you in your work, good chance that someone has already done so.

Now back to learning that scripting language.

To the ECE department IT group I sent an email worded something like this “I need to use Pearl, how do I start?” Their response “I think you mean PERL” and proceeded to provide the basic information.

I bought the book “Learning PERL” by Randall Schwartz, from O’Reilly and went from there. It was the most fun book on a programming language providing examples about Omar needing shekels to buy camels and llamas. I had the hardest time wrapping my head around the easy recursive nature of scripting languages like AWK, SED and PERL. Karl Brace, another classmate, finally provided me a clear enough explanation that I finally got it. I let Randall and company do the rest.

I worked through their exercises and figured out exactly how to insert my defect in to my circuit schematic representation into HSPICE and how to fire off said HSPICE simulation and put the result that I needed. When needed I always had the actual waveforms to look at but I really just needed to check a few results. Using subroutines, I made the set of scripts easy to maintain and debug as I developed the design automation flow. This permitted me to simulate a total of 4132 shorts into three different op-amp layouts (provided by my fellow graduate students). I simulated them for several electrical behaviors.

Once the scripts were written I could send off simulations to the batch computer system to run during the day and during the night. Acquiring a dumb terminal from a fellow student John Lee, permitted me to check simulation runs from home in the evening and send off the next back of simulations. The savings in my time was immense. I could focus on the fun fascinating analysis of how the op-amps failed, and could I take all these failures and represent them with simple models.

PERL saved my butt and I have Rick B to thank for the suggestion. Its I skill I used when I brought Inductive Fault Analysis to Intel. By coincidence, I met Randal Schwartz when I moved to Oregon to work for Intel.

Have a productive day,

Anne Meixner

Dear Reader, What memory or question does this piece spark in you? How has discussing your work with a colleague provided info key to your progress? How many programming languages have you had to learn. Please share your comments or stories below. You too can write for the Engineers’ Daughter- See Contribute for more Information.

Images: Picture of PEARL and Book over PERL, PERL

Additional Reading

PERL stands for Practical Extraction and Report Language. It was designed to handle lots of text processing.

Python seems to be the popular language these days. I took an introductory class on-line. There appear to be lots of comparisons between Perl and Python, I liked this one as I found it to be very matter of fact.