From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Rahguzar Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 24 Jul 2024 17:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 72278@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.172184176622490 (code B ref -1); Wed, 24 Jul 2024 17:23:02 +0000 Received: (at submit) by debbugs.gnu.org; 24 Jul 2024 17:22:46 +0000 Received: from localhost ([127.0.0.1]:34407 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWfhN-0005qe-Qg for submit@debbugs.gnu.org; Wed, 24 Jul 2024 13:22:46 -0400 Received: from lists.gnu.org ([209.51.188.17]:41372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWfhK-0005qV-Kq for submit@debbugs.gnu.org; Wed, 24 Jul 2024 13:22:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sWfhD-0002fQ-Iu for bug-gnu-emacs@gnu.org; Wed, 24 Jul 2024 13:22:35 -0400 Received: from sender-pp-o91.zoho.eu ([136.143.169.91]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sWfh9-00037U-VK for bug-gnu-emacs@gnu.org; Wed, 24 Jul 2024 13:22:35 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1721841748; cv=none; d=zohomail.eu; s=zohoarc; b=RzR0u9AN2nmfrmYXLiFoCATy9hTZH8YOQtdeul2yUM8MCTySrTij5vzfDgZ7OzTCyb9WxWT6RlooPfeC78UpJs/seCEbWbDX5d2FF1niFvF8u2P8H36+6qSfqarkNJ9cJAq8DVQKZ65cYjjctBr4ZXFow5Xy8jG5StuXpKGFddM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1721841748; h=Content-Type:Date:Date:From:From:MIME-Version:Message-ID:Subject:Subject:To:To:Message-Id:Reply-To:Cc; bh=8PEEbAVre9+oBpnunNOZZOOIIyvMY64XjyCQnsCprE0=; b=hscwNk2cBMdOAdqSHOC1vjf3wtXDALJFO825ktS9tYxd2kGuafb8ro1HvqH9BTDyS5O1+IX3F33r2rln9G6FX6ea+8ueFjttWr+9RHE5M3u33SCidocYO19BCarN7Ta66yjTyqWiUUJOvKCC94ft3wo7rjiMY60uTLkdAfpeGAI= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=zohomail.eu; spf=pass smtp.mailfrom=rahguzar@zohomail.eu; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1721841748; s=zoho; d=zohomail.eu; i=rahguzar@zohomail.eu; h=From:From:To:To:Subject:Subject:Date:Date:Message-ID:MIME-Version:Content-Type:Message-Id:Reply-To:Cc; bh=8PEEbAVre9+oBpnunNOZZOOIIyvMY64XjyCQnsCprE0=; b=bA7DGRl4hMKO4GqwzsIPbQxorm762MwdchnuhYaQaxWqY0h9T4Cd9LBNOYDzdeVV GvsgKZrCxExqcSQLPBeZ3HulLbqpfAXRzBcNbSBKykP+v+hBBJQb1SMm9fzm7LfdK8r CwXms52O2MDIX8GYbaM9ea8s0pfQbra/pK6eaynA= Received: by mx.zoho.eu with SMTPS id 1721841747349908.8658468844457; Wed, 24 Jul 2024 19:22:27 +0200 (CEST) From: Rahguzar Date: Wed, 24 Jul 2024 19:22:08 +0200 Message-ID: <87v80un1rz.fsf@zohomail.eu> MIME-Version: 1.0 Content-Type: text/plain X-ZohoMailClient: External Received-SPF: pass client-ip=136.143.169.91; envelope-from=rahguzar@zohomail.eu; helo=sender-pp-o91.zoho.eu X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) Dear Emacs Maintainers, I am using GNU/Linux on an Apple M2 processor using the Asahi Linux project [1]. They provide a kernel with 16KB page size [2]. This causes proced to show incorrect values for percentage memory (other memory related attributes might also be affected). E.g. comparing with top I see that value reported by proced is a quarter of that related by top. [1] https://asahilinux.org [2] https://discussion.fedoraproject.org/t/switch-to-the-kernel-16k-variant/87711 In GNU Emacs 29.4 (build 1, aarch64-redhat-linux-gnu, GTK+ Version 3.24.42, cairo version 1.18.0) of 2024-07-08 built on c7db9ae0ee0641de8f7c6190b678dcb8 System Description: Fedora Linux Asahi Remix 40 (Forty) Configured using: 'configure --build=aarch64-redhat-linux-gnu --host=aarch64-redhat-linux-gnu --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --runstatedir=/run --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-cairo --with-dbus --with-gif --with-gpm=no --with-harfbuzz --with-jpeg --with-json --with-modules --with-native-compilation=aot --with-pgtk --with-png --with-rsvg --with-sqlite3 --with-tiff --with-tree-sitter --with-webp --with-xpm --with-xwidgets build_alias=aarch64-redhat-linux-gnu host_alias=aarch64-redhat-linux-gnu CC=gcc 'CFLAGS=-DMAIL_USE_LOCKF -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mbranch-protection=standard -fasynchronous-unwind-tables -fstack-clash-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer ' LDFLAGS=-Wl,-z,relro PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig CXX=g++ 'CXXFLAGS=-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mbranch-protection=standard -fasynchronous-unwind-tables -fstack-clash-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer '' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM XWIDGETS GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: ELisp/l Minor modes in effect: pdf-occur-global-minor-mode: t shell-dirtrack-mode: t undo-fu-session-mode: t highlight-quoted-mode: t corfu-history-mode: t corfu-popupinfo-mode: t corfu-mode: t evil-surround-mode: t server-mode: t outline-minor-mode: t dirvish-override-dired-mode: t satchel-mode: t nerd-icons-completion-mode: t marginalia-mode: t vertico-multiform-mode: t vertico-mode: t evil-goggles-mode: t anzu-mode: t evil-mode: t evil-local-mode: t recentf-mode: t savehist-mode: t electric-pair-mode: t save-place-mode: t override-global-mode: t flymake-mode: t pixel-scroll-precision-mode: t repeat-mode: t midnight-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t buffer-read-only: t size-indication-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t abbrev-mode: t view-mode: t Load-path shadows: /home/azeem/.local/state/emacs/elpaca/builds/transient/transient hides /usr/share/emacs/29.4/lisp/transient /home/azeem/.local/state/emacs/elpaca/builds/ef-themes/theme-loaddefs hides /usr/share/emacs/29.4/lisp/theme-loaddefs /home/azeem/.local/state/emacs/elpaca/builds/eww-hacks/shr hides /usr/share/emacs/29.4/lisp/net/shr /home/azeem/.local/state/emacs/elpaca/builds/eww-hacks/eww hides /usr/share/emacs/29.4/lisp/net/eww Features: (shadow files-x emacsbug evil-nerd-commenter html-mode-expansions sgml-mode evil-nerd-commenter-operator evil-nerd-commenter-sdk misearch multi-isearch pdf-roll crm consult-info gnus-fun embark-org embark-consult embark inspirehep-pdf companion-mode inspirehep reftex reftex-loaddefs reftex-vars pdf-sync pdf-annot pdf-outline pdf-links pdf-history pdf-occur tablist tablist-filter semantic/wisent/comp semantic/wisent semantic/wisent/wisent semantic/util-modes semantic/util semantic semantic/tag semantic/lex semantic/fw mode-local cedet pdf-isearch pdf-misc pdf-tools pdf-view pdf-cache pdf-info tq pdf-util pdf-macs password-store auth-source-pass with-editor shell consult-imenu checkdoc vc-git vc-dispatcher package-lint-flymake package-lint let-alist finder finder-inf lisp-mnt package url-handlers vertico-directory oc-basic url-queue mm-url ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect ol-docview doc-view ol-bibtex bibtex ol-bbdb ol-w3m ol-doi org-link-doi descr-text mastodon-notifications smerge-mode diff diff-mode link-hint ffap goto-addr avy jka-compr view helpful cc-langs cc-vars cc-defs imenu trace edebug debug backtrace info-look info f help-fns radix-tree elisp-refs s dash undo-fu-session nerd-icons-corfu dabbrev delsel jit-spell ispell cape face-remap mastodon-media image-mode exif mastodon-profile mastodon-tl url-http url-gw url-cache url-auth mastodon-auth mastodon-client plstore mastodon mastodon-search mastodon-toot facemenu mastodon-iso persist mastodon-http request adaptive-wrap shr-color highlight-quoted corfu-history corfu-popupinfo corfu evil-embrace embrace expand-region text-mode-expansions the-org-mode-expansions org-element org-persist xdg org-id org-refile avl-tree generator er-basic-expansions expand-region-core expand-region-custom evil-surround qp sort smiley gnus-cite mm-archive mail-extr textsec uni-scripts idna-mapping ucs-normalize uni-confusable textsec-check gnus-async gnus-bcklg gnus-ml disp-table nndraft nnmh vertico-repeat epa-file network-stream nsm gnus-agent gnus-srvr gnus-score score-mode nnvirtual gnus-msg nntp gnus-cache fabs consult server mu4e mu4e-org org ob ob-tangle ob-ref ob-lob ob-table ob-exp org-macro org-src ob-comint org-pcomplete pcomplete org-list org-footnote org-faces org-entities noutline outline ob-emacs-lisp ob-core ob-eval org-cycle org-table ol org-fold org-fold-core org-keys oc org-loaddefs find-func org-version org-compat org-macs mu4e-notification notifications mu4e-main smtpmail mu4e-view mu4e-mime-parts gnus-art mm-uu mml2015 mm-view mml-smime smime gnutls dig gnus-sum gnus-group gnus-undo gnus-start gnus-dbus dbus gnus-cloud nnimap nnmail mail-source utf7 nnoo parse-time iso8601 gnus-spec gnus-int gnus-range gnus-win gnus cal-menu calendar cal-loaddefs mu4e-headers mu4e-thread mu4e-actions mu4e-compose nnheader range mu4e-search mu4e-lists mu4e-bookmarks mu4e-mark mu4e-message shr pixel-fill kinsoku url-file svg xml dom browse-url flow-fill mule-util hl-line mu4e-contacts mu4e-update mu4e-folders mu4e-context mu4e-query-items mu4e-server mu4e-modeline mu4e-vars mu4e-helpers mu4e-config mu4e-window ido message sendmail yank-media puny cus-start dirvish transient format-spec autorevert filenotify dired dired-loaddefs rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr mailabbrev mail-utils gmm-utils mailheader mu4e-obsolete usher satchel ibuf-ext ibuffer ibuffer-loaddefs bookmark nerd-icons-completion nerd-icons nerd-icons-faces nerd-icons-data nerd-icons-data-mdicon nerd-icons-data-flicon nerd-icons-data-codicon nerd-icons-data-devicon nerd-icons-data-sucicon nerd-icons-data-wicon nerd-icons-data-faicon nerd-icons-data-powerline nerd-icons-data-octicon nerd-icons-data-pomicon nerd-icons-data-ipsicon marginalia vertico-multiform vertico compat compat-30 evil-goggles pulse color ef-spring-theme ef-themes pdf-loader evil-anzu anzu evil evil-integration evil-maps evil-commands reveal evil-jumps evil-command-window evil-types evil-search evil-ex evil-macros evil-repeat evil-states evil-core comp comp-cstr cl-extra help-mode advice evil-common rect evil-vars edmacro kmacro orderless mastodon-autoloads request-autoloads persist-autoloads yeetube-autoloads filechooser-autoloads wile-autoloads adaptive-wrap-autoloads usher-autoloads undo-fu-session-autoloads ef-themes-autoloads jit-spell-autoloads satchel-autoloads pdf-tools-autoloads tablist-autoloads xr-autoloads link-hint-autoloads avy-autoloads yaml-mode-autoloads markdown-mode-autoloads magit-autoloads git-commit-autoloads magit-section-autoloads inspirehep-autoloads consult-hoogle-autoloads haskell-mode-autoloads geiser-guile-autoloads geiser-autoloads fabs-autoloads companion-mode-autoloads eww-hacks-autoloads evil-embrace-autoloads embrace-autoloads expand-region-autoloads evil-surround-autoloads evil-nerd-commenter-autoloads evil-goggles-autoloads evil-anzu-autoloads anzu-autoloads evil-autoloads goto-chg-autoloads eshell-syntax-highlighting-autoloads eat-autoloads package-lint-flymake-autoloads package-lint-autoloads elisp-def-autoloads macrostep-autoloads helpful-autoloads f-autoloads elisp-refs-autoloads dash-autoloads s-autoloads highlight-quoted-autoloads dirvish-autoloads transient-autoloads diredfl-autoloads trashed-autoloads vertico-autoloads orderless-autoloads nerd-icons-completion-autoloads marginalia-autoloads embark-consult-autoloads embark-autoloads nerd-icons-corfu-autoloads nerd-icons-autoloads cape-autoloads corfu-autoloads consult-autoloads password-store-autoloads with-editor-autoloads compat-autoloads elpaca-log elpaca-ui url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap recentf tree-widget savehist elec-pair saveplace bind-key url-parse auth-source eieio eieio-core password-cache json map url-vars easy-mmode cus-edit pp cus-load wid-edit pcase ibuf-macs flymake-proc flymake project byte-opt bytecomp byte-compile compile text-property-search comint ansi-osc ansi-color warnings icons thingatpt cl-macs pixel-scroll cua-base ring subr-x repeat rx midnight gv cl-seq elpaca elpaca-process cl-loaddefs cl-lib elpaca-autoloads rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win pgtk-win term/common-win pgtk-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads xwidget-internal dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk pgtk multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 1976204 1127031) (symbols 48 94384 7) (strings 32 478350 81603) (string-bytes 1 31638678) (vectors 16 149464) (vector-slots 8 3721744 648039) (floats 8 2069 5420) (intervals 56 197274 14128) (buffers 984 162)) From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 24 Jul 2024 19:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Rahguzar , 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.17218494422880 (code B ref 72278); Wed, 24 Jul 2024 19:31:02 +0000 Received: (at 72278) by debbugs.gnu.org; 24 Jul 2024 19:30:42 +0000 Received: from localhost ([127.0.0.1]:34511 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWhhB-0000kN-Kx for submit@debbugs.gnu.org; Wed, 24 Jul 2024 15:30:42 -0400 Received: from mail-ed1-f50.google.com ([209.85.208.50]:42386) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWhh9-0000k9-55 for 72278@debbugs.gnu.org; Wed, 24 Jul 2024 15:30:40 -0400 Received: by mail-ed1-f50.google.com with SMTP id 4fb4d7f45d1cf-595856e2336so327679a12.1 for <72278@debbugs.gnu.org>; Wed, 24 Jul 2024 12:30:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721849367; x=1722454167; darn=debbugs.gnu.org; h=to:subject:message-id:date:mime-version:references:in-reply-to:from :from:to:cc:subject:date:message-id:reply-to; bh=NkzhJGWSl6b6W/TWvXKbQZfuM9o4yZHHVtWnwUlTVp8=; b=h4hLfZxUIC9gbPqqgJ2tqT7aU1xxDHR0UdSm4modn/fAj9z4YhIurtV2CWQLzwtoyT ORUQCqY4zMZnV0FppUUARC9hXjiJ60SBQHN2IsTRFiQ3OPFpEf0pw2EW8sfTE37pYAGY l1hSuJIavzKTzARuau+GEKJCMDBnkar/zCUIt6E9tQku8dz7eS+ttWLlkS9rJJY9W4jo v5a95wRUX3QPiDtiZhwluuJD4m4kum4SW5FkJZXsnjVyVmmEmx8uCTCFRVuJGEYFrq9a vtHoXg0slRqqDTvCaIaDsjCiD0VUTyJ0Tyqj2HRgmTGWu+HgKgb+ULq16XZW48xX+7B9 xZIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721849367; x=1722454167; h=to:subject:message-id:date:mime-version:references:in-reply-to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=NkzhJGWSl6b6W/TWvXKbQZfuM9o4yZHHVtWnwUlTVp8=; b=cbKCOM7uzrQ1hm1Uus9ghfqncQ9aHaHtEjQVhRI7qXC1VAmitkAAfba2jdBHgeZRug +LYM/D4JV3smDTILABx/uo8+ZJ9/meEGStrjeHQbYgpQN6lcqTvoNW4TGHyDfMz8ZAl2 IZpdsO0jfmZ8saGZs5541XFJ3KrybM6MWNYkTPhTHhFca/W0NfWxX9/yHPzhG8ebuHT6 GL2MbA7BH785nKAeG9ff45bwHhalmw+RlVH2eD/s7DoFIo575zcCEzMyJ51aP6AHelOz J+zc8agSJgbkEbIez8q8UG7srkERiLCB7w6QHUSRypHYHY5F1ygTL3N5ZeziuN2ogIOZ lQpA== X-Forwarded-Encrypted: i=1; AJvYcCUa8VAdomSgjZLPMWx/YTytOm8ckRVxtiLkfYFC/NXPgLqDco+3l0T0Wkq/bUv1tMp2Nl4WMzpAAgdxrf11o9spfWsRO0w= X-Gm-Message-State: AOJu0YxfC7PV/zjT7LwqiY4XcYEgi0e8u5u9bxZO5yVKhhUjI63NW1aR iX93+b3Y/zAgy96ca9CoQhaj3R75x86j3xrsh5ab9Xd5WT1ZiPPWobwixufCOA1iC65CTVHOB9s Pj+lMDR/EqMnS7VaWhSnufbrucpM= X-Google-Smtp-Source: AGHT+IEt5jrAB9szQO+Ria1HZL7pyQg+w4vIdwIg0HiCDixyfjR7QZGntwuDWYTOB3mHC1JDW0P/fi7bluLx81DD6nU= X-Received: by 2002:a50:d502:0:b0:585:5697:b882 with SMTP id 4fb4d7f45d1cf-5ab19dcc409mr3073518a12.3.1721849366738; Wed, 24 Jul 2024 12:29:26 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 24 Jul 2024 12:29:25 -0700 From: Stefan Kangas In-Reply-To: <87v80un1rz.fsf@zohomail.eu> References: <87v80un1rz.fsf@zohomail.eu> MIME-Version: 1.0 Date: Wed, 24 Jul 2024 12:29:25 -0700 Message-ID: Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Rahguzar via "Bug reports for GNU Emacs, the Swiss army knife of text editors" writes: > Dear Emacs Maintainers, > > I am using GNU/Linux on an Apple M2 processor using the Asahi Linux > project [1]. They provide a kernel with 16KB page size [2]. This causes proced > to show incorrect values for percentage memory (other memory related > attributes might also be affected). E.g. comparing with top I see that > value reported by proced is a quarter of that related by top. > > [1] https://asahilinux.org > [2] https://discussion.fedoraproject.org/t/switch-to-the-kernel-16k-variant/87711 1. What is the output of running this command? grep MemTotal /proc/meminfo Does that value seem right? Does that file make sense in general? 2. Copy this to a buffer somewhere, put point after the last parenthesis, and press `C-u C-x C-e': (pp (mapcar #'process-attributes (seq-take (list-system-processes) 5))) Please post the result back here. Could you also tell us which values in the resulting list are wrong (a.k.a. "different from top")? Thanks in advance. From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Rahguzar Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 24 Jul 2024 20:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Kangas Cc: 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172185367120263 (code B ref 72278); Wed, 24 Jul 2024 20:42:02 +0000 Received: (at 72278) by debbugs.gnu.org; 24 Jul 2024 20:41:11 +0000 Received: from localhost ([127.0.0.1]:34582 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWinO-0005Gk-NZ for submit@debbugs.gnu.org; Wed, 24 Jul 2024 16:41:11 -0400 Received: from sender-pp-o91.zoho.eu ([136.143.169.91]:37242) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWinJ-0005GV-4z for 72278@debbugs.gnu.org; Wed, 24 Jul 2024 16:41:08 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1721853657; cv=none; d=zohomail.eu; s=zohoarc; b=WFmUm1A0eAvZpxe52a6oPV7QUPjO8kNfWbzhf2EZ+K38WL5okBTu5azlww6HMDQdY+P18Pmse4OVGqsy/U2AfE+2M9puxzgq1PaarSt++Fw9wK3xCmyHoxkkRzVOaC45nwkEtvd1RxSM779lt9REC4hfxDSKWV3oZLe2inSbS38= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1721853657; h=Content-Type:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=SLgPiFhqi6FLE178XPSzIltJ11orh27a/DZhMcspy6w=; b=DIFzGqZ1ZkUUZSwD0QmWn4/732tQzjZNMMewXJVj8qI7XTCnzKmKebgKUebrSBbNqbX8W+8WoxOPKbgxp22TDLLUTeWY9/9Q3kmGtAOfoKt0i5KjlqiXYOJof27AgOkXTY4dx96TAPavXsMP+DvsALc84GtmNdc8LwPPTy8G2co= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=zohomail.eu; spf=pass smtp.mailfrom=rahguzar@zohomail.eu; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1721853657; s=zoho; d=zohomail.eu; i=rahguzar@zohomail.eu; h=From:From:To:To:Cc:Cc:Subject:Subject:In-Reply-To:References:Date:Date:Message-ID:MIME-Version:Content-Type:Message-Id:Reply-To; bh=SLgPiFhqi6FLE178XPSzIltJ11orh27a/DZhMcspy6w=; b=Ra5aMAVmEYRwv+YVnJ3WSb363TuphVBV+STRo1pcVWQLrtJ6nUl/1kjyt53aSUez wcjV4xlSS02csPskl4VfunOWvKmS1TJlNURpTzPGvpehNUGU289RCyhX2QySQPkZf+/ IBU29ZYvYCPiuU0BGMbD2o18KL78Gw0dBP+NIdCk= Received: by mx.zoho.eu with SMTPS id 1721853654259658.4112672224819; Wed, 24 Jul 2024 22:40:54 +0200 (CEST) From: Rahguzar In-Reply-To: (Stefan Kangas's message of "Wed, 24 Jul 2024 12:29:25 -0700") References: <87v80un1rz.fsf@zohomail.eu> User-Agent: mu4e 1.12.1; emacs 29.4 Date: Wed, 24 Jul 2024 22:40:53 +0200 Message-ID: <87msm6mskq.fsf@zohomail.eu> MIME-Version: 1.0 Content-Type: text/plain X-ZohoMailClient: External X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Stefan, Stefan Kangas writes: > Rahguzar via "Bug reports for GNU Emacs, the Swiss army knife of text > editors" writes: > >> Dear Emacs Maintainers, >> >> I am using GNU/Linux on an Apple M2 processor using the Asahi Linux >> project [1]. They provide a kernel with 16KB page size [2]. This causes proced >> to show incorrect values for percentage memory (other memory related >> attributes might also be affected). E.g. comparing with top I see that >> value reported by proced is a quarter of that related by top. >> >> [1] https://asahilinux.org >> [2] https://discussion.fedoraproject.org/t/switch-to-the-kernel-16k-variant/87711 > > 1. What is the output of running this command? > > grep MemTotal /proc/meminfo > > Does that value seem right? Does that file make sense in general? The value and the file generally look correct to me. > 2. Copy this to a buffer somewhere, put point after the last > parenthesis, and press `C-u C-x C-e': > > (pp (mapcar #'process-attributes > (seq-take (list-system-processes) 5))) > > Please post the result back here. > > Could you also tell us which values in the resulting list are wrong > (a.k.a. "different from top")? The processes that end up in that list have memory footprint so small that top ends up showing percentage memory as 0. I modified the snippet to obtain 5 processes started by firefox: (((args . "/usr/lib64/firefox/firefox") (pmem . 3.018895533065192) (rss . 727876) (vsize . 17513856) (thcount . 105) (nice . 0) (pri . 20) (pcpu . 1.0718871382569872) (etime 12 34487 450000 0) (start 26260 56544 260000 0) (ctime 0 8651 310000 0) (cstime 0 393 900000 0) (cutime 0 8257 410000 0) (time 0 8799 330000 0) (stime 0 2500 340000 0) (utime 0 6298 990000 0) (cmajflt . 83) (cminflt . 10288762) (majflt . 1571) (minflt . 20999882) (tpgid . -1) (ttname . "") (sess . 1239) (pgrp . 1239) (ppid . 1) (state . "S") (comm . "firefox") (group . "azeem") (egid . 1000) (user . "azeem") (euid . 1000)) ((args . "/usr/lib64/firefox/firefox -contentproc -parentBuildID 20240712194222 -prefsLen 42067 -prefMapSize 262227 -appDir /usr/lib64/firefox/browser {6dc0e492-94e8-413e-83e0-ac2b970bde23} 1241 socket") (pmem . 0.05839737689600688) (rss . 14080) (vsize . 576016) (thcount . 6) (nice . 0) (pri . 20) (pcpu . 5.359847034838214e-05) (etime 12 34486 950000 0) (start 26260 56544 770000 0) (ctime 0 0 0 0) (cstime 0 0 0 0) (cutime 0 0 0 0) (time 0 0 440000 0) (stime 0 0 180000 0) (utime 0 0 260000 0) (cmajflt . 0) (cminflt . 0) (majflt . 9) (minflt . 1669) (tpgid . -1) (ttname . "") (sess . 1239) (pgrp . 1239) (ppid . 1241) (state . "S") (comm . "Socket Process") (group . "azeem") (egid . 1000) (user . "azeem") (euid . 1000)) ((args . "/usr/lib64/firefox/firefox -contentproc -childID 1 -isForBrowser -prefsLen 42067 -prefMapSize 262227 -jsInitLen 234780 -parentBuildID 20240712194222 -greomni /usr/lib64/firefox/omni.ja -appomni /usr/lib64/firefox/browser/omni.ja -appDir /usr/lib64/firefox/browser {2280679f-70cf-4f2d-887a-33665cc52830} 1241 tab") (pmem . 0.9880603908509892) (rss . 238228) (vsize . 22750640) (thcount . 27) (nice . 0) (pri . 20) (pcpu . 0.13563582493620777) (etime 12 34486 810000 0) (start 26260 56544 920000 0) (ctime 0 0 0 0) (cstime 0 0 0 0) (cutime 0 0 0 0) (time 0 1113 460000 0) (stime 0 75 970000 0) (utime 0 1037 490000 0) (cmajflt . 0) (cminflt . 0) (majflt . 0) (minflt . 1710810) (tpgid . -1) (ttname . "") (sess . 1239) (pgrp . 1239) (ppid . 1241) (state . "R") (comm . "WebExtensions") (group . "azeem") (egid . 1000) (user . "azeem") (euid . 1000)) ((args . "/usr/lib64/firefox/firefox -contentproc -childID 2 -isForBrowser -prefsLen 43016 -prefMapSize 262227 -jsInitLen 234780 -parentBuildID 20240712194222 -greomni /usr/lib64/firefox/omni.ja -appomni /usr/lib64/firefox/browser/omni.ja -appDir /usr/lib64/firefox/browser {c7fd5dcc-7f18-4677-8cd3-ff49efab3e75} 1241 tab") (pmem . 0.10299173743477577) (rss . 24832) (vsize . 4366000) (thcount . 28) (nice . 0) (pri . 20) (pcpu . 0.0032487989036966473) (etime 12 34486 770000 0) (start 26260 56544 960000 0) (ctime 0 0 0 0) (cstime 0 0 0 0) (cutime 0 0 0 0) (time 0 26 670000 0) (stime 0 6 580000 0) (utime 0 20 90000 0) (cmajflt . 0) (cminflt . 0) (majflt . 0) (minflt . 2708) (tpgid . -1) (ttname . "") (sess . 1239) (pgrp . 1239) (ppid . 1241) (state . "S") (comm . "Privileged Cont") (group . "azeem") (egid . 1000) (user . "azeem") (euid . 1000)) ((args . "/usr/lib64/firefox/firefox -contentproc -childID 3 -isForBrowser -prefsLen 29688 -prefMapSize 262227 -jsInitLen 234780 -parentBuildID 20240712194222 -greomni /usr/lib64/firefox/omni.ja -appomni /usr/lib64/firefox/browser/omni.ja -appDir /usr/lib64/firefox/browser {77722f8d-f95f-4796-9765-00d7017c5796} 1241 tab") (pmem . 1.0487306202000508) (rss . 252856) (vsize . 6381408) (thcount . 31) (nice . 0) (pri . 20) (pcpu . 0.48562684148940605) (etime 12 34486 380000 0) (start 26260 56545 350000 0) (ctime 0 0 0 0) (cstime 0 0 0 0) (cutime 0 0 0 0) (time 0 3986 600000 0) (stime 0 651 720000 0) (utime 0 3334 880000 0) (cmajflt . 0) (cminflt . 0) (majflt . 5) (minflt . 1335797) (tpgid . -1) (ttname . "") (sess . 1239) (pgrp . 1239) (ppid . 1241) (state . "S") (comm . "Isolated Web Co") (group . "azeem") (egid . 1000) (user . "azeem") (euid . 1000))) The percentage memory values in top for these processes are 12.1 0.2 4.0 0.4 and 4.2 so 4 times those returned by proced. > Thanks in advance. >From discussion with Eli at the help-gnu-emacs thread I think there is some hard coded assumption about 4KB page size in sysdep.c. E.g. here at line 3741 pmem = 4.0 * 100 * rss / procfs_get_total_memory (); Thanks, Rahguzar From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Jul 2024 05:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Rahguzar , Paul Eggert Cc: 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.17218840235018 (code B ref 72278); Thu, 25 Jul 2024 05:08:02 +0000 Received: (at 72278) by debbugs.gnu.org; 25 Jul 2024 05:07:03 +0000 Received: from localhost ([127.0.0.1]:35082 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWqgw-0001Ip-TE for submit@debbugs.gnu.org; Thu, 25 Jul 2024 01:07:03 -0400 Received: from eggs.gnu.org ([209.51.188.92]:36752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWqgu-0001Hy-Kg for 72278@debbugs.gnu.org; Thu, 25 Jul 2024 01:07:01 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sWqgg-0006Gc-Ke; Thu, 25 Jul 2024 01:06:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=1SdptZRhj89pTbzxX08Z5hXwPQ8ajXO69z8raObC/r8=; b=Frd6zykyVkTX l+wz4I1RpoWoBLYDPPNaxmUoYoEK3OWkikFkybdT3FpYlIewEwEpoIh+Urb3r1UcTbJkQXrSNdR6U JReh3vhnzQNRlcW6Wn9+zlwIBxr+Os6NtV/UWwFoWt+cFNcPifpl64WMGaWF32vjKRogf5Oigqo2D 3FpuMI6rfvrpuQ59CRwPWeN07I5hJii6Q0LptzgQFbGmPuSybYL8NkscU5x7Te86RGWyzbjOIrZEQ VImqhYdz6ve1K797cYOJZyWS2EtW8VQM24FN5Y/qbE1Hawdc/1SsoDj2nKX3746Hoht8vFmpQ9AHq QRLudfgw+657QtBjA+YjXg==; Date: Thu, 25 Jul 2024 08:06:44 +0300 Message-Id: <86zfq65acb.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <87v80un1rz.fsf@zohomail.eu> (bug-gnu-emacs@gnu.org) References: <87v80un1rz.fsf@zohomail.eu> X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Wed, 24 Jul 2024 19:22:08 +0200 > From: Rahguzar via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > I am using GNU/Linux on an Apple M2 processor using the Asahi Linux > project [1]. They provide a kernel with 16KB page size [2]. This causes proced > to show incorrect values for percentage memory (other memory related > attributes might also be affected). E.g. comparing with top I see that > value reported by proced is a quarter of that related by top. > > [1] https://asahilinux.org > [2] https://discussion.fedoraproject.org/t/switch-to-the-kernel-16k-variant/87711 Paul, it sounds like we need to multiply by getpagesize() instead of by a fixed value of 4? Some implementations of system_process_attributes already do that, although not the one which reads "/proc" on Linux. From unknown Fri Aug 15 17:20:59 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Rahguzar Subject: bug#72278: closed (Re: bug#72278: 29.4; Proced reports incorrect results with 16KB page size) Message-ID: References: <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> <87v80un1rz.fsf@zohomail.eu> X-Gnu-PR-Message: they-closed 72278 X-Gnu-PR-Package: emacs Reply-To: 72278@debbugs.gnu.org Date: Thu, 25 Jul 2024 06:39:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1721889542-14781-1" This is a multi-part message in MIME format... ------------=_1721889542-14781-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #72278: 29.4; Proced reports incorrect results with 16KB page size which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 72278@debbugs.gnu.org. --=20 72278: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D72278 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1721889542-14781-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 72278-done) by debbugs.gnu.org; 25 Jul 2024 06:38:50 +0000 Received: from localhost ([127.0.0.1]:35200 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWs7m-0003q2-3N for submit@debbugs.gnu.org; Thu, 25 Jul 2024 02:38:50 -0400 Received: from mail.cs.ucla.edu ([131.179.128.66]:33926) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWs7k-0003pi-9x for 72278-done@debbugs.gnu.org; Thu, 25 Jul 2024 02:38:49 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id C84843C0140A0; Wed, 24 Jul 2024 23:38:35 -0700 (PDT) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id NLYdemiFGlZd; Wed, 24 Jul 2024 23:38:35 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 59C8A3C00E400; Wed, 24 Jul 2024 23:38:35 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 59C8A3C00E400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1721889515; bh=BxP93MN+km71+Tr1JxGPIKFFqz737AuUst3MOtcyZWc=; h=Message-ID:Date:MIME-Version:To:From; b=LD+7GNprvjA6ByhKrxq2jb5BjxxqqEgW18dHfxcXPZ0PRsmBkGxtsEPOdQuFl1Jr8 +cUDJr1YyxnByANDxiswWGmHIr+JrDYiBWVPrMyxOnSr/+KZio+iKLlpa0hRQH+itm BZKgO9Cif0P6MWJcglhO29egN2AKBooJD4cDyyGfgOTH6xt8nrhUkWDxZua6Kjk4Bn ZMCtnPIzmKLhajMidILlhHeM65HbvDbS+mIhl0VTCQDFRHGO0VCfwazES2eWnblbXi beOXUbWy/HP5LNRqE6p/F7g85uJvZwoqK5L0VKodTORNPQn6matdOk4QufhWwUgFp5 K9CCk/L/0SxWQ== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id KY7LlXynpLaY; Wed, 24 Jul 2024 23:38:35 -0700 (PDT) Received: from [192.168.254.12] (unknown [47.154.17.165]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 3998C3C0140A0; Wed, 24 Jul 2024 23:38:35 -0700 (PDT) Content-Type: multipart/mixed; boundary="------------W5uUXeSMfic91hZo3OtrdQUe" Message-ID: <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> Date: Wed, 24 Jul 2024 23:38:34 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#72278: 29.4; Proced reports incorrect results with 16KB page size To: Eli Zaretskii References: <87v80un1rz.fsf@zohomail.eu> <86zfq65acb.fsf@gnu.org> Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: <86zfq65acb.fsf@gnu.org> X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 72278-done Cc: Rahguzar , 72278-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------W5uUXeSMfic91hZo3OtrdQUe Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 2024-07-24 22:06, Eli Zaretskii wrote: > Paul, it sounds like we need to multiply by getpagesize() instead of > by a fixed value of 4? Yes, that sounds right. I installed the attached patch into Emacs master on Savannah, and am boldly closing the bug as fixed. We can reopen it if I'm wrong. Thanks, Rahguzar, for reporting the bug. --------------W5uUXeSMfic91hZo3OtrdQUe Content-Type: text/x-patch; charset=UTF-8; name="0001-Fix-process-attributes-rss-and-pmem-on-GNU-Linux.patch" Content-Disposition: attachment; filename*0="0001-Fix-process-attributes-rss-and-pmem-on-GNU-Linux.patch" Content-Transfer-Encoding: base64 RnJvbSA0MmNkZmU3ZjYwZWY3YWUzYmNjYjViMWU0MzM0OWMzYTZiNTRhYzRhIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 PgpEYXRlOiBXZWQsIDI0IEp1bCAyMDI0IDIzOjMyOjI0IC0wNzAwClN1YmplY3Q6IFtQQVRD SF0gRml4IHByb2Nlc3MtYXR0cmlidXRlcyByc3MgYW5kIHBtZW0gb24gR05VL0xpbnV4Ck1J TUUtVmVyc2lvbjogMS4wCkNvbnRlbnQtVHlwZTogdGV4dC9wbGFpbjsgY2hhcnNldD1VVEYt OApDb250ZW50LVRyYW5zZmVyLUVuY29kaW5nOiA4Yml0CgpQcm9ibGVtIHJlcG9ydGVkIGJ5 IFJhaGd1emFyIDxodHRwczovL2J1Z3MuZ251Lm9yZy83MjI3OD4uCiogc3JjL3N5c2RlcC5j IChzeXN0ZW1fcHJvY2Vzc19hdHRyaWJ1dGVzKToKW0dOVV9MSU5VWCB8fCBDWUdXSU4gfHwg X19BTkRST0lEX19dOiBXaGVuIGNvbXB1dGluZyByc3MgYW5kIHBtZW0sCmRvbuKAmXQgYXNz dW1lIHBhZ2VzaXplIGlzIDQwOTY7IGl0IGNvdWxkIGJlIGdyZWF0ZXIuCi0tLQogc3JjL3N5 c2RlcC5jIHwgMTAgKysrKysrKystLQogMSBmaWxlIGNoYW5nZWQsIDggaW5zZXJ0aW9ucygr KSwgMiBkZWxldGlvbnMoLSkKCmRpZmYgLS1naXQgYS9zcmMvc3lzZGVwLmMgYi9zcmMvc3lz ZGVwLmMKaW5kZXggZDkxNmE2OTUxNTUuLjM5NTVkNzk2Y2E1IDEwMDY0NAotLS0gYS9zcmMv c3lzZGVwLmMKKysrIGIvc3JjL3N5c2RlcC5jCkBAIC0zNTQ4LDYgKzM1NDgsNyBAQCBwcm9j ZnNfdHR5bmFtZSAoaW50IHJkZXYpCiB9CiAjIGVuZGlmCS8qIEdOVV9MSU5VWCB8fCBfX0FO RFJPSURfXyAqLwogCisvKiBUb3RhbCB1c2FibGUgUkFNIGluIEtpQi4gICovCiBzdGF0aWMg dWludG1heF90CiBwcm9jZnNfZ2V0X3RvdGFsX21lbW9yeSAodm9pZCkKIHsKQEAgLTM3Mzcs OCArMzczOCwxMyBAQCBzeXN0ZW1fcHJvY2Vzc19hdHRyaWJ1dGVzIChMaXNwX09iamVjdCBw aWQpCiAJICBhdHRycyA9IEZjb25zIChGY29ucyAoUW5pY2UsIG1ha2VfZml4bnVtIChuaWNl bmVzcykpLCBhdHRycyk7CiAJICBhdHRycyA9IEZjb25zIChGY29ucyAoUXRoY291bnQsIElO VF9UT19JTlRFR0VSICh0aGNvdW50KSksIGF0dHJzKTsKIAkgIGF0dHJzID0gRmNvbnMgKEZj b25zIChRdnNpemUsIElOVF9UT19JTlRFR0VSICh2c2l6ZSAvIDEwMjQpKSwgYXR0cnMpOwot CSAgYXR0cnMgPSBGY29ucyAoRmNvbnMgKFFyc3MsIElOVF9UT19JTlRFR0VSICg0ICogcnNz KSksIGF0dHJzKTsKLQkgIHBtZW0gPSA0LjAgKiAxMDAgKiByc3MgLyBwcm9jZnNfZ2V0X3Rv dGFsX21lbW9yeSAoKTsKKworCSAgLyogUlNTIGluIEtpQi4gICovCisJICB1aW50bWF4X3Qg cnNzayA9IHJzczsKKwkgIHJzc2sgKj0gZ2V0cGFnZXNpemUgKCkgPj4gMTA7CisKKwkgIGF0 dHJzID0gRmNvbnMgKEZjb25zIChRcnNzLCBJTlRfVE9fSU5URUdFUiAocnNzaykpLCBhdHRy cyk7CisJICBwbWVtID0gMTAwLjAgKiByc3NrIC8gcHJvY2ZzX2dldF90b3RhbF9tZW1vcnkg KCk7CiAJICBpZiAocG1lbSA+IDEwMCkKIAkgICAgcG1lbSA9IDEwMDsKIAkgIGF0dHJzID0g RmNvbnMgKEZjb25zIChRcG1lbSwgbWFrZV9mbG9hdCAocG1lbSkpLCBhdHRycyk7Ci0tIAoy LjQzLjAKCg== --------------W5uUXeSMfic91hZo3OtrdQUe-- ------------=_1721889542-14781-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 24 Jul 2024 17:22:46 +0000 Received: from localhost ([127.0.0.1]:34407 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWfhN-0005qe-Qg for submit@debbugs.gnu.org; Wed, 24 Jul 2024 13:22:46 -0400 Received: from lists.gnu.org ([209.51.188.17]:41372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWfhK-0005qV-Kq for submit@debbugs.gnu.org; Wed, 24 Jul 2024 13:22:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sWfhD-0002fQ-Iu for bug-gnu-emacs@gnu.org; Wed, 24 Jul 2024 13:22:35 -0400 Received: from sender-pp-o91.zoho.eu ([136.143.169.91]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sWfh9-00037U-VK for bug-gnu-emacs@gnu.org; Wed, 24 Jul 2024 13:22:35 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1721841748; cv=none; d=zohomail.eu; s=zohoarc; b=RzR0u9AN2nmfrmYXLiFoCATy9hTZH8YOQtdeul2yUM8MCTySrTij5vzfDgZ7OzTCyb9WxWT6RlooPfeC78UpJs/seCEbWbDX5d2FF1niFvF8u2P8H36+6qSfqarkNJ9cJAq8DVQKZ65cYjjctBr4ZXFow5Xy8jG5StuXpKGFddM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1721841748; h=Content-Type:Date:Date:From:From:MIME-Version:Message-ID:Subject:Subject:To:To:Message-Id:Reply-To:Cc; bh=8PEEbAVre9+oBpnunNOZZOOIIyvMY64XjyCQnsCprE0=; b=hscwNk2cBMdOAdqSHOC1vjf3wtXDALJFO825ktS9tYxd2kGuafb8ro1HvqH9BTDyS5O1+IX3F33r2rln9G6FX6ea+8ueFjttWr+9RHE5M3u33SCidocYO19BCarN7Ta66yjTyqWiUUJOvKCC94ft3wo7rjiMY60uTLkdAfpeGAI= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=zohomail.eu; spf=pass smtp.mailfrom=rahguzar@zohomail.eu; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1721841748; s=zoho; d=zohomail.eu; i=rahguzar@zohomail.eu; h=From:From:To:To:Subject:Subject:Date:Date:Message-ID:MIME-Version:Content-Type:Message-Id:Reply-To:Cc; bh=8PEEbAVre9+oBpnunNOZZOOIIyvMY64XjyCQnsCprE0=; b=bA7DGRl4hMKO4GqwzsIPbQxorm762MwdchnuhYaQaxWqY0h9T4Cd9LBNOYDzdeVV GvsgKZrCxExqcSQLPBeZ3HulLbqpfAXRzBcNbSBKykP+v+hBBJQb1SMm9fzm7LfdK8r CwXms52O2MDIX8GYbaM9ea8s0pfQbra/pK6eaynA= Received: by mx.zoho.eu with SMTPS id 1721841747349908.8658468844457; Wed, 24 Jul 2024 19:22:27 +0200 (CEST) From: Rahguzar To: bug-gnu-emacs@gnu.org Subject: 29.4; Proced reports incorrect results with 16KB page size Date: Wed, 24 Jul 2024 19:22:08 +0200 Message-ID: <87v80un1rz.fsf@zohomail.eu> MIME-Version: 1.0 Content-Type: text/plain X-ZohoMailClient: External Received-SPF: pass client-ip=136.143.169.91; envelope-from=rahguzar@zohomail.eu; helo=sender-pp-o91.zoho.eu X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) Dear Emacs Maintainers, I am using GNU/Linux on an Apple M2 processor using the Asahi Linux project [1]. They provide a kernel with 16KB page size [2]. This causes proced to show incorrect values for percentage memory (other memory related attributes might also be affected). E.g. comparing with top I see that value reported by proced is a quarter of that related by top. [1] https://asahilinux.org [2] https://discussion.fedoraproject.org/t/switch-to-the-kernel-16k-variant/87711 In GNU Emacs 29.4 (build 1, aarch64-redhat-linux-gnu, GTK+ Version 3.24.42, cairo version 1.18.0) of 2024-07-08 built on c7db9ae0ee0641de8f7c6190b678dcb8 System Description: Fedora Linux Asahi Remix 40 (Forty) Configured using: 'configure --build=aarch64-redhat-linux-gnu --host=aarch64-redhat-linux-gnu --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --runstatedir=/run --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-cairo --with-dbus --with-gif --with-gpm=no --with-harfbuzz --with-jpeg --with-json --with-modules --with-native-compilation=aot --with-pgtk --with-png --with-rsvg --with-sqlite3 --with-tiff --with-tree-sitter --with-webp --with-xpm --with-xwidgets build_alias=aarch64-redhat-linux-gnu host_alias=aarch64-redhat-linux-gnu CC=gcc 'CFLAGS=-DMAIL_USE_LOCKF -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mbranch-protection=standard -fasynchronous-unwind-tables -fstack-clash-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer ' LDFLAGS=-Wl,-z,relro PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig CXX=g++ 'CXXFLAGS=-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mbranch-protection=standard -fasynchronous-unwind-tables -fstack-clash-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer '' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM XWIDGETS GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: ELisp/l Minor modes in effect: pdf-occur-global-minor-mode: t shell-dirtrack-mode: t undo-fu-session-mode: t highlight-quoted-mode: t corfu-history-mode: t corfu-popupinfo-mode: t corfu-mode: t evil-surround-mode: t server-mode: t outline-minor-mode: t dirvish-override-dired-mode: t satchel-mode: t nerd-icons-completion-mode: t marginalia-mode: t vertico-multiform-mode: t vertico-mode: t evil-goggles-mode: t anzu-mode: t evil-mode: t evil-local-mode: t recentf-mode: t savehist-mode: t electric-pair-mode: t save-place-mode: t override-global-mode: t flymake-mode: t pixel-scroll-precision-mode: t repeat-mode: t midnight-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t buffer-read-only: t size-indication-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t abbrev-mode: t view-mode: t Load-path shadows: /home/azeem/.local/state/emacs/elpaca/builds/transient/transient hides /usr/share/emacs/29.4/lisp/transient /home/azeem/.local/state/emacs/elpaca/builds/ef-themes/theme-loaddefs hides /usr/share/emacs/29.4/lisp/theme-loaddefs /home/azeem/.local/state/emacs/elpaca/builds/eww-hacks/shr hides /usr/share/emacs/29.4/lisp/net/shr /home/azeem/.local/state/emacs/elpaca/builds/eww-hacks/eww hides /usr/share/emacs/29.4/lisp/net/eww Features: (shadow files-x emacsbug evil-nerd-commenter html-mode-expansions sgml-mode evil-nerd-commenter-operator evil-nerd-commenter-sdk misearch multi-isearch pdf-roll crm consult-info gnus-fun embark-org embark-consult embark inspirehep-pdf companion-mode inspirehep reftex reftex-loaddefs reftex-vars pdf-sync pdf-annot pdf-outline pdf-links pdf-history pdf-occur tablist tablist-filter semantic/wisent/comp semantic/wisent semantic/wisent/wisent semantic/util-modes semantic/util semantic semantic/tag semantic/lex semantic/fw mode-local cedet pdf-isearch pdf-misc pdf-tools pdf-view pdf-cache pdf-info tq pdf-util pdf-macs password-store auth-source-pass with-editor shell consult-imenu checkdoc vc-git vc-dispatcher package-lint-flymake package-lint let-alist finder finder-inf lisp-mnt package url-handlers vertico-directory oc-basic url-queue mm-url ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect ol-docview doc-view ol-bibtex bibtex ol-bbdb ol-w3m ol-doi org-link-doi descr-text mastodon-notifications smerge-mode diff diff-mode link-hint ffap goto-addr avy jka-compr view helpful cc-langs cc-vars cc-defs imenu trace edebug debug backtrace info-look info f help-fns radix-tree elisp-refs s dash undo-fu-session nerd-icons-corfu dabbrev delsel jit-spell ispell cape face-remap mastodon-media image-mode exif mastodon-profile mastodon-tl url-http url-gw url-cache url-auth mastodon-auth mastodon-client plstore mastodon mastodon-search mastodon-toot facemenu mastodon-iso persist mastodon-http request adaptive-wrap shr-color highlight-quoted corfu-history corfu-popupinfo corfu evil-embrace embrace expand-region text-mode-expansions the-org-mode-expansions org-element org-persist xdg org-id org-refile avl-tree generator er-basic-expansions expand-region-core expand-region-custom evil-surround qp sort smiley gnus-cite mm-archive mail-extr textsec uni-scripts idna-mapping ucs-normalize uni-confusable textsec-check gnus-async gnus-bcklg gnus-ml disp-table nndraft nnmh vertico-repeat epa-file network-stream nsm gnus-agent gnus-srvr gnus-score score-mode nnvirtual gnus-msg nntp gnus-cache fabs consult server mu4e mu4e-org org ob ob-tangle ob-ref ob-lob ob-table ob-exp org-macro org-src ob-comint org-pcomplete pcomplete org-list org-footnote org-faces org-entities noutline outline ob-emacs-lisp ob-core ob-eval org-cycle org-table ol org-fold org-fold-core org-keys oc org-loaddefs find-func org-version org-compat org-macs mu4e-notification notifications mu4e-main smtpmail mu4e-view mu4e-mime-parts gnus-art mm-uu mml2015 mm-view mml-smime smime gnutls dig gnus-sum gnus-group gnus-undo gnus-start gnus-dbus dbus gnus-cloud nnimap nnmail mail-source utf7 nnoo parse-time iso8601 gnus-spec gnus-int gnus-range gnus-win gnus cal-menu calendar cal-loaddefs mu4e-headers mu4e-thread mu4e-actions mu4e-compose nnheader range mu4e-search mu4e-lists mu4e-bookmarks mu4e-mark mu4e-message shr pixel-fill kinsoku url-file svg xml dom browse-url flow-fill mule-util hl-line mu4e-contacts mu4e-update mu4e-folders mu4e-context mu4e-query-items mu4e-server mu4e-modeline mu4e-vars mu4e-helpers mu4e-config mu4e-window ido message sendmail yank-media puny cus-start dirvish transient format-spec autorevert filenotify dired dired-loaddefs rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr mailabbrev mail-utils gmm-utils mailheader mu4e-obsolete usher satchel ibuf-ext ibuffer ibuffer-loaddefs bookmark nerd-icons-completion nerd-icons nerd-icons-faces nerd-icons-data nerd-icons-data-mdicon nerd-icons-data-flicon nerd-icons-data-codicon nerd-icons-data-devicon nerd-icons-data-sucicon nerd-icons-data-wicon nerd-icons-data-faicon nerd-icons-data-powerline nerd-icons-data-octicon nerd-icons-data-pomicon nerd-icons-data-ipsicon marginalia vertico-multiform vertico compat compat-30 evil-goggles pulse color ef-spring-theme ef-themes pdf-loader evil-anzu anzu evil evil-integration evil-maps evil-commands reveal evil-jumps evil-command-window evil-types evil-search evil-ex evil-macros evil-repeat evil-states evil-core comp comp-cstr cl-extra help-mode advice evil-common rect evil-vars edmacro kmacro orderless mastodon-autoloads request-autoloads persist-autoloads yeetube-autoloads filechooser-autoloads wile-autoloads adaptive-wrap-autoloads usher-autoloads undo-fu-session-autoloads ef-themes-autoloads jit-spell-autoloads satchel-autoloads pdf-tools-autoloads tablist-autoloads xr-autoloads link-hint-autoloads avy-autoloads yaml-mode-autoloads markdown-mode-autoloads magit-autoloads git-commit-autoloads magit-section-autoloads inspirehep-autoloads consult-hoogle-autoloads haskell-mode-autoloads geiser-guile-autoloads geiser-autoloads fabs-autoloads companion-mode-autoloads eww-hacks-autoloads evil-embrace-autoloads embrace-autoloads expand-region-autoloads evil-surround-autoloads evil-nerd-commenter-autoloads evil-goggles-autoloads evil-anzu-autoloads anzu-autoloads evil-autoloads goto-chg-autoloads eshell-syntax-highlighting-autoloads eat-autoloads package-lint-flymake-autoloads package-lint-autoloads elisp-def-autoloads macrostep-autoloads helpful-autoloads f-autoloads elisp-refs-autoloads dash-autoloads s-autoloads highlight-quoted-autoloads dirvish-autoloads transient-autoloads diredfl-autoloads trashed-autoloads vertico-autoloads orderless-autoloads nerd-icons-completion-autoloads marginalia-autoloads embark-consult-autoloads embark-autoloads nerd-icons-corfu-autoloads nerd-icons-autoloads cape-autoloads corfu-autoloads consult-autoloads password-store-autoloads with-editor-autoloads compat-autoloads elpaca-log elpaca-ui url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap recentf tree-widget savehist elec-pair saveplace bind-key url-parse auth-source eieio eieio-core password-cache json map url-vars easy-mmode cus-edit pp cus-load wid-edit pcase ibuf-macs flymake-proc flymake project byte-opt bytecomp byte-compile compile text-property-search comint ansi-osc ansi-color warnings icons thingatpt cl-macs pixel-scroll cua-base ring subr-x repeat rx midnight gv cl-seq elpaca elpaca-process cl-loaddefs cl-lib elpaca-autoloads rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win pgtk-win term/common-win pgtk-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads xwidget-internal dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk pgtk multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 1976204 1127031) (symbols 48 94384 7) (strings 32 478350 81603) (string-bytes 1 31638678) (vectors 16 149464) (vector-slots 8 3721744 648039) (floats 8 2069 5420) (intervals 56 197274 14128) (buffers 984 162)) ------------=_1721889542-14781-1-- From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Jul 2024 09:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Rahguzar Cc: 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.17218988289027 (code B ref 72278); Thu, 25 Jul 2024 09:14:02 +0000 Received: (at 72278) by debbugs.gnu.org; 25 Jul 2024 09:13:48 +0000 Received: from localhost ([127.0.0.1]:35526 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWuXk-0002LW-EH for submit@debbugs.gnu.org; Thu, 25 Jul 2024 05:13:48 -0400 Received: from mail-ed1-f47.google.com ([209.85.208.47]:44281) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWuXi-0002LO-B1 for 72278@debbugs.gnu.org; Thu, 25 Jul 2024 05:13:47 -0400 Received: by mail-ed1-f47.google.com with SMTP id 4fb4d7f45d1cf-5a3458bf989so826841a12.0 for <72278@debbugs.gnu.org>; Thu, 25 Jul 2024 02:13:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721898758; x=1722503558; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=INZaJHLv+mmqXtGnoEDaFFk6tBRJMI+X9DDRHlt8i+I=; b=O/srd0rBFvN0Ez2A3iVciJa/oOcfRQl6Kxg5e8gSaTD6x4tAiSKkzxYIjxSMwXw+Ob 4fy8aQFc8/ir4y5PBbs27ySSfTsThL2sBKS6NpkJY1qMauGYdrqwD5F3vHEmE/Cvdav6 gS/zmaXCKh6XuxoNgbSrBJ30l3+0J/gmTyx+e10bvkPg9hvwdoNLIyww2JhTktu1hB/8 NGv29rSrpAKh92zpTYlqXOJMFWI7FBmjOyPZSt3fWUB50qK3XoaVsUcEoYOW8LRznAxr OxjzCeQBcuBl9xk0XI5dxqQpCNNAZt8FEFP26cJwNZ5W9lVfZfxJqHLlFHEnKdFj00hp W8LA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721898758; x=1722503558; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=INZaJHLv+mmqXtGnoEDaFFk6tBRJMI+X9DDRHlt8i+I=; b=eUJkGeGyG5VKp9AANHzzo3T7xSR7dCVBZZju9X5FRi7CAUuDkuvuRCyPUXEWD7RwVo K/Tr1tTR8iolyYUtaEHQW8YSzC3T8z3t+rpHQjV7EIT3OaCcazWZkfP7aUs6rRjvfnoh 9qcwBp+XSli6CkHTQFwbitQjJu1rO4wSD74tVkTOz8Gpj3rvtDnP1OOkC4sOZUp3TBMs BPMcrgw9XL0AgfmK3rAgwtpFqXhjhN/Cf+rT/GolAVxczm8kDXLI4EEZy4vsYQTe7ZaM 7B+cMxRxM6XeCizBpDr65FeiVQROtOVhE9NsyWk9cwAjdKKsk+Gyjt9JQbRk2oE0Xafj 6YzQ== X-Gm-Message-State: AOJu0Yy91qVyRtdb2a7maVitoNyc04BjoFrV3YBcaY4JtEQlB3gQdWj0 d174/psQZnrKMEZMpK4yHEYdp8+wJQ++MyGpPmXiN9oMdM9bR0S4AbmlkK6zTE8QfJwapCfDTR1 BRruN1XWUgC4U+YF0T/BOuVYtyTk= X-Google-Smtp-Source: AGHT+IH+9r7aVm64c+1FVQoTXazh1iS8wZyBx1zBJ7l9XaqdXSB3H9MZ6/g84IGcLi6XtRt6K4Hcwt84j7KPq/Uk1wg= X-Received: by 2002:a50:cd93:0:b0:5a1:a469:4d9b with SMTP id 4fb4d7f45d1cf-5ac2a7b70c0mr1301236a12.13.1721898757744; Thu, 25 Jul 2024 02:12:37 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 25 Jul 2024 09:12:37 +0000 From: Stefan Kangas In-Reply-To: <87msm6mskq.fsf@zohomail.eu> References: <87v80un1rz.fsf@zohomail.eu> <87msm6mskq.fsf@zohomail.eu> MIME-Version: 1.0 Date: Thu, 25 Jul 2024 09:12:37 +0000 Message-ID: Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Rahguzar writes: > From discussion with Eli at the help-gnu-emacs thread I think there is > some hard coded assumption about 4KB page size in sysdep.c. E.g. here at > line 3741 > > pmem = 4.0 * 100 * rss / procfs_get_total_memory (); Makes sense to me. AFAIK, the page size can be different for different processes, so I guess we'd need to find the page size per process in something like /proc//status? Is that the right way to do it? I'm not on a GNU/Linux machine right now so I can't check. From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Rahguzar Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Jul 2024 09:40:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Kangas Cc: 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172190036822524 (code B ref 72278); Thu, 25 Jul 2024 09:40:02 +0000 Received: (at 72278) by debbugs.gnu.org; 25 Jul 2024 09:39:28 +0000 Received: from localhost ([127.0.0.1]:35545 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWuwa-0005rE-4P for submit@debbugs.gnu.org; Thu, 25 Jul 2024 05:39:28 -0400 Received: from sender-pp-o91.zoho.eu ([136.143.169.91]:37239) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWuwX-0005r5-5i for 72278@debbugs.gnu.org; Thu, 25 Jul 2024 05:39:26 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1721900356; cv=none; d=zohomail.eu; s=zohoarc; b=BN8Ff1cjnSp7/po8puVuQIUFfWwDeVmDn4+LCCeDxBr3mlvBQfvmCre3WKt46BvBH/A3/land5YP+Qam7X3Q31Hl5opFE0LgfE2hCFQUN6C2i17w/FcZjoG4rrpIs0kAC6TgrIbpaRCnUM8C0U9eCMIPgRfcuqlb2e5eL6oX1SI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1721900356; h=Content-Type:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=6PFXoInRGXw4VknDEWTfXyMTcALDnCDO3rAh9XP9SDY=; b=V5b9FQ9mTgS8h2NkWuDiS6Bh3fqdc9pkBlmMUqi5UqJdDNpugHnyDlE6MKq104111qDqWehXyfZJfwzb5YUVfdaC4F+x55Ym/bTZwIo2eHzGgIzHo5yXKwHCLsV7ZneG4LEFHpc5qxz/D9u/SSXaj96YelZxs/obJH9yM4VqUOs= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=zohomail.eu; spf=pass smtp.mailfrom=rahguzar@zohomail.eu; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1721900356; s=zoho; d=zohomail.eu; i=rahguzar@zohomail.eu; h=From:From:To:To:Cc:Cc:Subject:Subject:In-Reply-To:References:Date:Date:Message-ID:MIME-Version:Content-Type:Message-Id:Reply-To; bh=6PFXoInRGXw4VknDEWTfXyMTcALDnCDO3rAh9XP9SDY=; b=W1/h1bkg/XKa3Z0mmDvHfJ1pNicduErQrivNt8zDcp609xvMR4c8zcFdnmXhM1hA EdaiRWd8KrkTS8zdpnTxT4MaONUi3xiz/i6EjgxvteiK4mvt3UqSnBkZEsKv9P7hG2h klMUPDJOCUXBlHmfe7wBbqAt8BCiH50L8cNjNBaM= Received: by mx.zoho.eu with SMTPS id 1721900352699839.6086619399556; Thu, 25 Jul 2024 11:39:12 +0200 (CEST) From: Rahguzar In-Reply-To: (Stefan Kangas's message of "Thu, 25 Jul 2024 09:12:37 +0000") References: <87v80un1rz.fsf@zohomail.eu> <87msm6mskq.fsf@zohomail.eu> User-Agent: mu4e 1.12.1; emacs 29.4 Date: Thu, 25 Jul 2024 11:39:06 +0200 Message-ID: <87bk2ln745.fsf@zohomail.eu> MIME-Version: 1.0 Content-Type: text/plain X-ZohoMailClient: External X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Stefan, Stefan Kangas writes: > Rahguzar writes: > >> From discussion with Eli at the help-gnu-emacs thread I think there is >> some hard coded assumption about 4KB page size in sysdep.c. E.g. here at >> line 3741 >> >> pmem = 4.0 * 100 * rss / procfs_get_total_memory (); > > Makes sense to me. > > AFAIK, the page size can be different for different processes, so I > guess we'd need to find the page size per process in something like > /proc//status? Is that the right way to do it? > > I'm not on a GNU/Linux machine right now so I can't check. Paul Eggert's changes fixed the issue for me. Rahguzar From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Jul 2024 09:57:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Paul Eggert , Eli Zaretskii Cc: Rahguzar , 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172190141024596 (code B ref 72278); Thu, 25 Jul 2024 09:57:01 +0000 Received: (at 72278) by debbugs.gnu.org; 25 Jul 2024 09:56:50 +0000 Received: from localhost ([127.0.0.1]:35564 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWvDO-0006Oe-1O for submit@debbugs.gnu.org; Thu, 25 Jul 2024 05:56:50 -0400 Received: from mail-ed1-f42.google.com ([209.85.208.42]:57851) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWvDL-0006ON-7y for 72278@debbugs.gnu.org; Thu, 25 Jul 2024 05:56:48 -0400 Received: by mail-ed1-f42.google.com with SMTP id 4fb4d7f45d1cf-5a156556fb4so959690a12.3 for <72278@debbugs.gnu.org>; Thu, 25 Jul 2024 02:56:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721901334; x=1722506134; darn=debbugs.gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date :mime-version:references:in-reply-to:from:from:to:cc:subject:date :message-id:reply-to; bh=uKVcavsFsP/Xnc/Obmg/ANxGq4gvv0TdF9GPw78vtFQ=; b=H/1N0wZrpUIHHV6NVjGQ5GyomABXvz+uIuUIf9psjaIwGSM8kgmEdHbm2EPFL2UiV0 UmQ7JUquHFkAp/o5cHkktaEq0pMUAOQ5tWrmSiUORmFuLoCMhzm3qNuUukAuN3GhV4K7 MFym0wnloqAyjuE2m0+tPES9jXGum+wosQ33r32960aVmqAi787NCIwM/viGoKPtZtiD 0kjgUPbsTyjJR1thuq2X7ZsnmNHTjuNMZyUbsutgeYQbJNIK4jTLOJzg/UELcw46nytJ tkojgtcviIZLbmw1eQISLLPP4T+F2vxlPflpfjRODDFb7saii/8JWK2nXIi0/neQFU3d U/cg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721901334; x=1722506134; h=content-transfer-encoding:cc:to:subject:message-id:date :mime-version:references:in-reply-to:from:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=uKVcavsFsP/Xnc/Obmg/ANxGq4gvv0TdF9GPw78vtFQ=; b=ZI35ICzRklBA08QQ5J9yUWKezyZL63rFvc44eh62rERx0MwCWPQYZBFXuVxaVonWSP AcFNoEL5yzWqcUF3YLbtW3R0MIuwOCZ0ALvVI+fS7gRD62rdO5KPbFgBz2tAADUump4r dGPGIBjvg+QstOrORT9PyIQdZcg3quuUwOWZkPicwwStZW5TOeF+u3OU9hL8anqVa8Yd /I0DbH+jJURE5j7ec2wsdB7dSdWXoZd+uBCCqdtTkmMLfykjxzFUR4pF1718BxHbj4ix 5o8M/kAzKMkaltqCEMFcFFOQQU4NWeYKhUNiV3Yf6C2Q0yNPqOZypHS/UteA1Zj35lQi SbWA== X-Forwarded-Encrypted: i=1; AJvYcCXKPID05mRwpDlybRIGa7qq22zbQJlUbFBKYj/0re7jYqTi15PtFWzLtB+kDngjsHQnle8YTvZNtiy+/z4g7KmqRFp/e5w= X-Gm-Message-State: AOJu0Yybde4dM/Pi9E7fFgcAuOFRGWxDFOaDwUxo3sWkQoREttw367ig gRa1ymEN+gvVONSmzoTAFxEJjqh7hz4dm2DkZQFBrSJ4l6jlyx9NtsXYAP/m2VmEDLdm4kBslbM y6Gax++AHdxjNDpdrUKZP7ksLnSc= X-Google-Smtp-Source: AGHT+IGJm/UFXTDr6T8B6LW5JPfdXU47b3BZ5uS7IIMgpTLpDynD39b7IhESjfBNRn4CxMezLd0E83hIE8sNylSL9HA= X-Received: by 2002:a50:f609:0:b0:58b:12bd:69c8 with SMTP id 4fb4d7f45d1cf-5ac641292b1mr937625a12.36.1721901334114; Thu, 25 Jul 2024 02:55:34 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 25 Jul 2024 02:55:32 -0700 From: Stefan Kangas In-Reply-To: <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> References: <87v80un1rz.fsf@zohomail.eu> <86zfq65acb.fsf@gnu.org> <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> MIME-Version: 1.0 Date: Thu, 25 Jul 2024 02:55:32 -0700 Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Paul Eggert writes: > From 42cdfe7f60ef7ae3bccb5b1e43349c3a6b54ac4a Mon Sep 17 00:00:00 2001 > From: Paul Eggert > Date: Wed, 24 Jul 2024 23:32:24 -0700 > Subject: [PATCH] Fix process-attributes rss and pmem on GNU/Linux > MIME-Version: 1.0 > Content-Type: text/plain; charset=3DUTF-8 > Content-Transfer-Encoding: 8bit > > Problem reported by Rahguzar . > * src/sysdep.c (system_process_attributes): > [GNU_LINUX || CYGWIN || __ANDROID__]: When computing rss and pmem, > don=E2=80=99t assume pagesize is 4096; it could be greater. > --- > src/sysdep.c | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) > > diff --git a/src/sysdep.c b/src/sysdep.c > index d916a695155..3955d796ca5 100644 > --- a/src/sysdep.c > +++ b/src/sysdep.c > @@ -3548,6 +3548,7 @@ procfs_ttyname (int rdev) > } > # endif /* GNU_LINUX || __ANDROID__ */ > > +/* Total usable RAM in KiB. */ > static uintmax_t > procfs_get_total_memory (void) > { > @@ -3737,8 +3738,13 @@ system_process_attributes (Lisp_Object pid) > attrs =3D Fcons (Fcons (Qnice, make_fixnum (niceness)), attrs); > attrs =3D Fcons (Fcons (Qthcount, INT_TO_INTEGER (thcount)), attrs); > attrs =3D Fcons (Fcons (Qvsize, INT_TO_INTEGER (vsize / 1024)), attrs= ); > - attrs =3D Fcons (Fcons (Qrss, INT_TO_INTEGER (4 * rss)), attrs); > - pmem =3D 4.0 * 100 * rss / procfs_get_total_memory (); > + > + /* RSS in KiB. */ > + uintmax_t rssk =3D rss; > + rssk *=3D getpagesize () >> 10; > + > + attrs =3D Fcons (Fcons (Qrss, INT_TO_INTEGER (rssk)), attrs); > + pmem =3D 100.0 * rssk / procfs_get_total_memory (); Thanks, that looks like an improvement. On Linux, page sizes can vary per process ("multiple page size support"). Should we bother with that? I also note that the man page for getpagesize says this: This call first appeared in 4.2BSD. SVr4, 4.4BSD, SUSv2. In SUSv2 the getpagesize() call was labeled LEGACY, and it was removed in POSIX.1-2001. > if (pmem > 100) > pmem =3D 100; > attrs =3D Fcons (Fcons (Qpmem, make_float (pmem)), attrs); > -- > 2.43.0 From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Jul 2024 14:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Kangas , Eli Zaretskii Cc: Rahguzar , 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172191889423577 (code B ref 72278); Thu, 25 Jul 2024 14:49:02 +0000 Received: (at 72278) by debbugs.gnu.org; 25 Jul 2024 14:48:14 +0000 Received: from localhost ([127.0.0.1]:37562 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWzlN-00068A-Pe for submit@debbugs.gnu.org; Thu, 25 Jul 2024 10:48:14 -0400 Received: from mail.cs.ucla.edu ([131.179.128.66]:51942) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sWzlL-00067t-4Q for 72278@debbugs.gnu.org; Thu, 25 Jul 2024 10:48:12 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id B3A9D3C0140A0; Thu, 25 Jul 2024 07:47:57 -0700 (PDT) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id rqVciX-QD7aB; Thu, 25 Jul 2024 07:47:57 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 712573C00E402; Thu, 25 Jul 2024 07:47:57 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 712573C00E402 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1721918877; bh=hJWqwrl1nYxIqZhHeyaOfSPNkYnPseLxlVHxdXidhlI=; h=Message-ID:Date:MIME-Version:To:From; b=Ctoyg0br79yU4LcOdCFjN8HCsxTlaAkOidC0XkFbHa/FFANLPtbjxji82Jc01lVTL uP+xDhvJRL+XRB7ZVakJoICaRMIKfn3hh04yZFRe7jhs/tJvCq6F1CKz20Dsr6UZxq WWDP5zvs7kEc+yM0773Dyql/gtZyGg9wMFvfJzJI8939g0QLtiLpeH+nIhPYxsNhOm nhFm6h1cUslQoGwoVPph3SFDpRFlBkQabUhx0yr7c8EKlhLGlIOeNieZUxJCXxLaD7 E5SL/rCsGVgW4WOWSgWlD/Wmr3OMpjGKhA6GES8P0aYFlQT1AvSy9G4QkjYW7Xik7n sp2JeH5DQ0RkA== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id eySs93PQ80Vq; Thu, 25 Jul 2024 07:47:57 -0700 (PDT) Received: from [192.168.254.12] (unknown [47.154.17.165]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 4C07A3C0140A0; Thu, 25 Jul 2024 07:47:57 -0700 (PDT) Message-ID: Date: Thu, 25 Jul 2024 07:47:56 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: <87v80un1rz.fsf@zohomail.eu> <86zfq65acb.fsf@gnu.org> <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2024-07-25 02:55, Stefan Kangas wrote: > On Linux, page sizes can vary per process ("multiple page size > support"). Should we bother with that? I thought that support didn't change what getpagesize returns or what /proc/PID/stat reports, at least not in mainline Linux kernels. Am I missing something? > I also note that the man page for getpagesize says this: > > This call first appeared in 4.2BSD. SVr4, 4.4BSD, SUSv2. In > SUSv2 the getpagesize() call was labeled LEGACY, and it was > removed in POSIX.1-2001. Emacs uses getpagesize in other places. I suppose we should change them all to sysconf (_SC_PAGESIZE) on the off chance that there's a platform somewhere where page sizes exceed 1 GiB. I don't know of any such platform now, probably because so much software still uses getpagesize.... From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 26 Jul 2024 22:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Paul Eggert , Eli Zaretskii Cc: Rahguzar , 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172203326310810 (code B ref 72278); Fri, 26 Jul 2024 22:35:02 +0000 Received: (at 72278) by debbugs.gnu.org; 26 Jul 2024 22:34:23 +0000 Received: from localhost ([127.0.0.1]:40231 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sXTW2-0002oH-T7 for submit@debbugs.gnu.org; Fri, 26 Jul 2024 18:34:23 -0400 Received: from mail-lj1-f181.google.com ([209.85.208.181]:54638) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sXTW0-0002o9-VX for 72278@debbugs.gnu.org; Fri, 26 Jul 2024 18:34:22 -0400 Received: by mail-lj1-f181.google.com with SMTP id 38308e7fff4ca-2ee920b0781so18583871fa.1 for <72278@debbugs.gnu.org>; Fri, 26 Jul 2024 15:34:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1722033191; x=1722637991; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=ibqzmsT1JzxZjOe3J3381lovxrXYNesf2qkkTHpGL84=; b=OZNOHZvLFgo0MmyGFAcpci/ScPJ+OrzL7XCEJEbi5xuPtv5prVojekNfpF2polyemz Nq60Bj608OdNOC1DQ3OHiahcfHG2vmZqVI8KavMARbIwr9SE3j37F2PRX1wK7wUGBL/w QAygG+x7lij2kwxT8+EbToZ31ZIx0k0ax1MOF4ajZTSXG/5MzSVOAMXb1dq53tVTxtDk wkm8W5OMKYEloB4qgrGtHo7mF/wNT/vu3rd6gNqfQqUhYavmpw2q1NgpwmH/VxMjG2u8 yN8WN3Q3sDYaM1oE38P1BnF0oXauxd4UkbRQ+NfbsZm6WPyNZ6L1Fcz5gFg1FnJY/4ul YPUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1722033191; x=1722637991; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ibqzmsT1JzxZjOe3J3381lovxrXYNesf2qkkTHpGL84=; b=P5+CWHtW4PBA3Zb1ZIhNs5Mu6izEQ1tTj7aRkehJINvvrcxtDXkzox/Rv1iT/l7ilx FkEQKPhemPdXuhTEDFD0yL2xW2K6zwvK6dNiACPXVv59plIfAClugidw4U7GqR2ldhEM nieYPWWThbT3nFAjFDm4NJ9l65aEk2I+dGRIRlxdDKLEnihq7haI7vq/DYg2yGbm1vta p36v68RbxGzQfQriaNaipiTuI9EK2Zpex/bP+aMOZr9ou1FmAxydapkeaRT7ddGEq3/Z mr2OeSqnpmu/aIgY2ur9x5ivtREiTVoYbucs9tDQnA2eR8HuRHKhLf+nS42H38CUSuR5 CcIg== X-Forwarded-Encrypted: i=1; AJvYcCU4g11mm2wwi1orKONSUAAdIYWF1xXRc6hhKA0VPofKW4R5V7NCY4TrFIwv7ofQaPml9VKJQ3CzCkkD8PfuadX6xJg4lh8= X-Gm-Message-State: AOJu0YyZm5fWpp70hJzoexUyopZOxj1dvajFRer10Ol+ugHnIAPzDsTd ABPmjHAluHM/5EJAKhxJuGs8mSCoaQO/I+4FAihNdOD10xCZH20pbH7LWVX1H0qshQcm6r4IN2g i8oRsHyH90XDoRA1T3bq3GWy7g4k= X-Google-Smtp-Source: AGHT+IGccDp1ydJ6wxTtAMSmeY6XM3IiS5FaJBSdaYbV1bAR/gATPQ6aW1nBjJ9fi6ZsTfQiNNgzY8Mq44YGSvSeU8I= X-Received: by 2002:a2e:94ca:0:b0:2ef:2e8b:1802 with SMTP id 38308e7fff4ca-2f12ee575a6mr5810201fa.31.1722033190552; Fri, 26 Jul 2024 15:33:10 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Fri, 26 Jul 2024 18:33:09 -0400 From: Stefan Kangas In-Reply-To: References: <87v80un1rz.fsf@zohomail.eu> <86zfq65acb.fsf@gnu.org> <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> MIME-Version: 1.0 Date: Fri, 26 Jul 2024 18:33:09 -0400 Message-ID: Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Paul Eggert writes: > On 2024-07-25 02:55, Stefan Kangas wrote: >> On Linux, page sizes can vary per process ("multiple page size >> support"). Should we bother with that? > > I thought that support didn't change what getpagesize returns or what > /proc/PID/stat reports, at least not in mainline Linux kernels. Am I > missing something? I don't know to be honest, which is why I'm asking. If you think using getpagesize is all that we need then that's good enough for me. From unknown Fri Aug 15 17:20:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#72278: 29.4; Proced reports incorrect results with 16KB page size Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 27 Jul 2024 01:41:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72278 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Kangas , Eli Zaretskii Cc: Rahguzar , 72278@debbugs.gnu.org Received: via spool by 72278-submit@debbugs.gnu.org id=B72278.172204445028613 (code B ref 72278); Sat, 27 Jul 2024 01:41:01 +0000 Received: (at 72278) by debbugs.gnu.org; 27 Jul 2024 01:40:50 +0000 Received: from localhost ([127.0.0.1]:40301 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sXWQT-0007RQ-JG for submit@debbugs.gnu.org; Fri, 26 Jul 2024 21:40:49 -0400 Received: from mail.cs.ucla.edu ([131.179.128.66]:41480) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sXWQQ-0007RC-MP for 72278@debbugs.gnu.org; Fri, 26 Jul 2024 21:40:48 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 828D63C00D407; Fri, 26 Jul 2024 18:40:31 -0700 (PDT) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id gHCBQbR6d5dR; Fri, 26 Jul 2024 18:40:31 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 03A263C00D408; Fri, 26 Jul 2024 18:40:31 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 03A263C00D408 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1722044431; bh=C4oHwbk7IgtAyi9UiES7Vv8jCn2EKSzG+iTqOtfpbTY=; h=Message-ID:Date:MIME-Version:To:From; b=nadS9bC1B47FI9fxEI757iQG8C1qQG6S3ZmNLKDmDV0soK3FpAXNVDjy9ZVXpUqZz L/3z5Q5m36mG3w2ZnT5fPDQWbz7WUmTvQhDLbc8ybAFfS5EHG6ayOGqySiZ7Ph0SSU C+zZp/cHBrGcJL1pyY5WMfAncWwS6ERCmj2bU52kpDmNveKFrrfvNI08AwhMIZS1B0 GjY/7LXh0qPMUBfFoxtmlqxV+A/SwYjQAU30QZVUXRYNRzkCU3zoctBM/dlFF9CJph 9FerkDn7DDJ/DO1TXsyRvGBPDJsJqUZ60JTwc6o5nMBOjuk84AYDkC7KV2dx0N+SqL +pqr44aR8inRw== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id 9KW8siiTXV4Q; Fri, 26 Jul 2024 18:40:30 -0700 (PDT) Received: from [192.168.254.12] (unknown [47.154.17.165]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id D12353C00D407; Fri, 26 Jul 2024 18:40:30 -0700 (PDT) Message-ID: Date: Fri, 26 Jul 2024 18:40:30 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: <87v80un1rz.fsf@zohomail.eu> <86zfq65acb.fsf@gnu.org> <88d8077a-b01b-4428-8388-6944581bdfe7@cs.ucla.edu> Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2024-07-26 15:33, Stefan Kangas wrote: > Paul Eggert writes: > >> On 2024-07-25 02:55, Stefan Kangas wrote: >>> On Linux, page sizes can vary per process ("multiple page size >>> support"). Should we bother with that? >> I thought that support didn't change what getpagesize returns or what >> /proc/PID/stat reports, at least not in mainline Linux kernels. Am I >> missing something? > I don't know to be honest, which is why I'm asking. For recent Asahi Linux user-mode pages are always 16 KiB; see . I'd be surprised if any Linux distro lets getpagesize calls differ among processes running atop the same kernel. Although Linux does support huge pages via (for example) mmap with MAP_HUGETLB, I would expect this to not affect getpagesize or /proc/PID/stat. I haven't verified this by running code or by scouting through kernel source, though.