Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1214821

Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to /proc/PID/status

From David Rientjes <rientjes@google.com>
Newsgroups linux.kernel
Subject Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to /proc/PID/status
Date 2015-08-27 22:50 +0200
Message-ID <q2cht-74J-11@gated-at.bofh.it> (permalink)
References (6 earlier) <q1vPc-4OX-17@gated-at.bofh.it> <q1Cxk-6ew-1@gated-at.bofh.it> <q1R3j-1Qg-13@gated-at.bofh.it> <q1Zay-524-19@gated-at.bofh.it> <q299V-2Go-23@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On Thu, 27 Aug 2015, Jörn Engel wrote:

> On Thu, Aug 27, 2015 at 08:48:18AM +0200, Michal Hocko wrote:
> > Can we go with the single and much simpler cumulative number first and
> > only add the break down list if it is _really_ required? We can even
> > document that the future version of /proc/<pid>/status might add an
> > additional information to prepare all the parsers to be more careful.
> 
> I don't care much which way we decide.  But I find your reasoning a bit
> worrying.  If someone asks for a by-size breakup of hugepages in a few
> years, you might have existing binaries that depend on the _absence_ of
> those extra characters on the line.
> 
> Compare:
>   HugetlbPages:      18432 kB
>   HugetlbPages:    1069056 kB (1*1048576kB 10*2048kB)
> 
> Once someone has written a script that greps for 'HugetlbPages:.*kB$',
> you have lost the option of adding anything else to the line.  You have
> created yet another ABI compatibility headache today in order to save
> 112 lines of code.
> 

This is exactly the concern that I have brought up in this thread.  We 
have no other way to sanely export the breakdown in hugepage size without 
new fields being added later with the hstate size being embedded in the 
name itself.

I agree with the code as it stands in -mm today and I'm thankful to Naoya 
that a long-term maintainable API has been established.  Respectfully, I 
have no idea why we are still talking about this and I'm not going to be 
responding further unless something changes in -mm.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> - 2015-08-20 10:50 +0200
  Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-20 13:10 +0200
    Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status David Rientjes <rientjes@google.com> - 2015-08-20 22:00 +0200
      Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-21 08:40 +0200
        Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Jörn Engel <joern@purestorage.com> - 2015-08-21 18:40 +0200
    Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> - 2015-08-21 01:40 +0200
      Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-21 09:00 +0200
        Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Jörn Engel <joern@purestorage.com> - 2015-08-21 18:40 +0200
          Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-24 11:00 +0200
            Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status David Rientjes <rientjes@google.com> - 2015-08-26 01:30 +0200
              Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-26 08:40 +0200
                Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status David Rientjes <rientjes@google.com> - 2015-08-27 00:10 +0200
                Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-27 08:50 +0200
                Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Jörn Engel <joern@purestorage.com> - 2015-08-27 19:30 +0200
                Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status David Rientjes <rientjes@google.com> - 2015-08-27 22:50 +0200
                Re: [PATCH v5 2/2] mm: hugetlb: proc: add HugetlbPages field to  /proc/PID/status Michal Hocko <mhocko@kernel.org> - 2015-08-31 11:20 +0200

csiph-web