In my earlier scripts, I could add a bunch of loops and arrays without a significant impact on run time. In other words, the most time consuming operation was to scan the file, and I could add more and more validations to each line with only a minor impact on performance (one script has more than 1000 lines of code and takes 120 seconds to scan a 320000 line file).
In more recent scripts that doesn't happen. Each line validation is consuming more and more time. A script with just over 500 lines is taking almost 1000 seconds to scan 2.5 million lines (which means it's performance is roughly twice as bad as the previous script).
I cannot find anything fundamentally different about the two scripts. What type of operations can affect awk's performance by these amounts?
Thanks in advance for any help.
In more recent scripts that doesn't happen. Each line validation is consuming more and more time. A script with just over 500 lines is taking almost 1000 seconds to scan 2.5 million lines (which means it's performance is roughly twice as bad as the previous script).
I cannot find anything fundamentally different about the two scripts. What type of operations can affect awk's performance by these amounts?
Thanks in advance for any help.