Немного неприятный хак и поправьте меня, если я ошибаюсь, но вы можете исправить ваш файл arch/x86/kernel/cpu/proc.c в исходном коде ядра и перекомпилировать ваше ядро, чтобы сообщить именно то, что вы хотите, если ваша тестовая программа читает из /proc/cpuinfo.
На момент написания этого ответа последняя версия файлаhttp://elixir.free-electrons.com/linux/latest/source/arch/x86/kernel/cpu/proc.c
Изhttps://www.gnu.org/software/grep/manual/html_node/Usage.html
Why does grep report “Binary file matches”?
If grep listed all matching “lines” from a binary file, it would probably generate output > that is not useful, and it might even muck up your display. So GNU grep suppresses output > from files that appear to be binary files. To force GNU grep to output lines even from files that appear to be binary, use the -a or ‘--binary-files=text’ option. To eliminate > the “Binary file matches” messages, use the -I or ‘--binary-files=without-match’ option.