From: Sergio Durigan Junior <sergiodj@redhat.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sourceware.org, jan.kratochvil@redhat.com,
palves@redhat.com, oleg@redhat.com
Subject: Re: [PATCH v2] Improve corefile generation by using /proc/PID/coredump_filter (PR corefile/16902)
Date: Mon, 16 Mar 2015 02:42:00 -0000 [thread overview]
Message-ID: <877fuhek7o.fsf@redhat.com> (raw)
In-Reply-To: <83a8zf3ok3.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 14 Mar 2015 11:39:56 +0200")
Thanks for the review, Eli.
On Saturday, March 14 2015, Eli Zaretskii wrote:
>> From: Sergio Durigan Junior <sergiodj@redhat.com>
>> Cc: Jan Kratochvil <jan.kratochvil@redhat.com>, Pedro Alves <palves@redhat.com>, Oleg Nesterov <oleg@redhat.com>
>> Date: Thu, 12 Mar 2015 17:39:39 -0400
>>
>> +On @sc{gnu}/Linux, this command can take into account the value of the
>> +file @file{/proc/@var{pid}/coredump_filter} when generating the core
>> +dump (@pxref{set use-coredump-filter}).
>
> You never explain what @var{pid} is, until you get to the example. I
> think we should tell that earlier.
Fixed.
>> +To make use of this feature, you have to write in the
>> +@file{/proc/@var{pid}/coredump_filter} file a value, in hexadecimal,
>> +which is a bit mask representing the memory mapping types. If a bit
>> +is set in the bit mask, then the memory mappings of the corresponding
>> +types will be dumped; otherwise, they will be ignored. The bits in
>> +this bit mask have the following meanings:
>> +
>> +@table @code
>> +@item bit 0
>> +Dump anonymous private mappings.
>> +@item bit 1
>> +Dump anonymous shared mappings.
>> +@item bit 2
>> +Dump file-backed private mappings.
>> +@item bit 3
>> +Dump file-backed shared mappings.
>> +@item bit 4
>> +(since Linux 2.6.24)
>> +Dump ELF headers. (@value{GDBN} does not take this bit into account)
>> +@item bit 5
>> +(since Linux 2.6.28)
>> +Dump private huge pages.
>> +@item bit 6
>> +(since Linux 2.6.28)
>> +Dump shared huge pages.
>> +@end table
>> +
>> +For example, supposing that the @code{pid} of the program being
>> +debugging is @code{1234}, if you wanted to dump everything except the
>> +anonymous private and the file-backed shared mappings, you would do:
>> +
>> +@smallexample
>> +$ echo 0x76 > /proc/1234/coredump_filter
>> +@end smallexample
>> +
>> +For more documentation about how to use the @file{coredump_filter}
>> +file, see the manpage of @code{proc(5)}.
>
> I don't think we should repeat all that information here, we should
> just refer to the man page you cite, possibly also telling what
> section of that page to look in.
My very first personal version of the patch did not have this table
here, and was just mentioning the man page, as you proposed. However,
because man pages are not the official GNU documentation format, I
decided to include a "bit" more info here.
Either, I don't have a strong preference. I will mention the man page.
I am not sending a fixed version of the patch in this message because I
am still working on Pedro's comments. When I reply to his e-mail, the
attached patch will include your suggestions as well.
Thanks,
--
Sergio
GPG key ID: 0x65FC5E36
Please send encrypted e-mail if possible
http://sergiodj.net/
next prev parent reply other threads:[~2015-03-16 2:42 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-05 3:48 [PATCH] " Sergio Durigan Junior
2015-03-05 15:48 ` Jan Kratochvil
2015-03-05 20:53 ` Sergio Durigan Junior
2015-03-05 20:57 ` Jan Kratochvil
2015-03-11 20:02 ` Oleg Nesterov
2015-03-12 11:31 ` Sergio Durigan Junior
2015-03-12 14:36 ` vvar, gup && coredump Oleg Nesterov
2015-03-12 16:29 ` Andy Lutomirski
2015-03-12 16:56 ` Oleg Nesterov
2015-03-12 17:18 ` Andy Lutomirski
2015-03-12 17:40 ` Oleg Nesterov
2015-03-12 17:45 ` Sergio Durigan Junior
2015-03-12 18:04 ` Oleg Nesterov
2015-03-13 4:50 ` Sergio Durigan Junior
2015-03-13 15:06 ` Oleg Nesterov
2015-03-12 17:56 ` Andy Lutomirski
2015-03-12 18:28 ` Oleg Nesterov
2015-03-12 17:48 ` Oleg Nesterov
2015-03-12 17:55 ` Andy Lutomirski
2015-03-12 18:16 ` Oleg Nesterov
2015-03-12 18:23 ` Sergio Durigan Junior
2015-03-12 18:20 ` Pedro Alves
2015-03-12 18:26 ` Andy Lutomirski
2015-03-16 19:03 ` install_special_mapping && vm_pgoff (Was: vvar, gup && coredump) Oleg Nesterov
2015-03-16 19:20 ` Andy Lutomirski
2015-03-16 19:46 ` Oleg Nesterov
2015-03-17 13:45 ` Oleg Nesterov
2015-03-18 1:45 ` Andy Lutomirski
2015-03-18 18:08 ` Oleg Nesterov
2015-03-16 19:40 ` Pedro Alves
2015-03-12 15:02 ` [PATCH] Improve corefile generation by using /proc/PID/coredump_filter (PR corefile/16902) Oleg Nesterov
2015-03-12 15:46 ` Pedro Alves
2015-03-12 15:57 ` Jan Kratochvil
2015-03-12 16:19 ` Pedro Alves
2015-03-12 16:07 ` Oleg Nesterov
2015-03-12 16:28 ` Pedro Alves
2015-03-12 17:37 ` Sergio Durigan Junior
2015-03-12 21:39 ` [PATCH v2] " Sergio Durigan Junior
2015-03-13 19:34 ` Pedro Alves
2015-03-16 23:53 ` Sergio Durigan Junior
2015-03-18 19:10 ` Pedro Alves
2015-03-18 19:39 ` Sergio Durigan Junior
2015-03-14 9:40 ` Eli Zaretskii
2015-03-16 2:42 ` Sergio Durigan Junior [this message]
2015-03-13 19:37 ` [PATCH] " Pedro Alves
2015-03-13 19:48 ` Pedro Alves
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=877fuhek7o.fsf@redhat.com \
--to=sergiodj@redhat.com \
--cc=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
--cc=jan.kratochvil@redhat.com \
--cc=oleg@redhat.com \
--cc=palves@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox