Update filter.cpp/.h in generator.