What about performance?
Awk has a built-in operation to read a line and break it into fields
This operation is carefully optimized, because it is so common
The C++ version spends most of its time reading input
Writing a high-performance ``Awk input'' abstraction might pay off