Re: [PATCH] Support gzip compressed exec and core files in gdb

Jan Kratochvil
2015-03-11T22:13:38Z

On Wed, 11 Mar 2015 00:01:42 +0100, Michael Eager wrote:
> Add support to automatically unzip compressed executable and core files.
> Files will be uncompressed into temporary directory (/tmp or $TMPDIR)
> and are deleted when GDB exits.

Such feature has been requested to support xz-compressed core files as
currently being stored by systemd. But to make it more convenient one should
decompress on-demand only the blocks of file that are really accessed by GDB
- expecting by bfd_iovec. Obviously GDB usually needs to access only small
part of the whole core file.

I did not check how it is supported by gzip but for xz one needs to use
--block-size, otherwise the file blocks cannot be decompressed independently
in random access way.

ISTM libz-gzip and liblzma-xz compatibility is mutually exclusive.

Jan