linux-record: Simplify with record_mem_at_reg()
The function record_linux_system_call() often records a memory area
whose address is contained in a register. So far this required two
function calls: one for fetching the register value, and another one for
recording the memory area. These two function calls are now merged into
a new local helper function, and all occurrences are adjusted. This
reduces the source code and makes it more readable.
gdb/ChangeLog:
* linux-record.c (record_mem_at_reg): New helper function.
(record_linux_system_call): Exploit new helper function where
applicable.