I think it's a fine idea to write the program to C++. Yes, a C++ program doing the same logic as a perl program will be faster. But I agree there may be a bottleneck in the perl program that could be fixed.
Normally, I do a short task using bash. But once it gets to a certain level of complexity, I move to C. It runs faster, but that's not the main point. It's so much easier to maintain a complex program in C than a complex program in a scripting language. The same logic applies to perl, which is kind of infamous for somehow leading to undecipherable code. On the other hand, there are large applications written in perl.
Quote:
A C++ program would have to be rebuilt to move it to a
different machine architecture and might need to be rebuilt to move
it to a different operating system even if they both run on the same hardware.
For the most part, I disagree with this assertion. If there is a graphic front end, it is often tricky writing multi-platform code. But for processing a log file, the program should compile on any platform, assuming the programmer is competent.