[Rpm-maint] [rpm-software-management/rpm] Consider available memory and address space for parallel execution (PR #2418)

Michal Domonkos notifications at github.com
Wed Mar 22 16:55:48 UTC 2023


@dmnks commented on this pull request.



> +    long int pagesize = sysconf(_SC_PAGESIZE);
+    long int pages = sysconf(_SC_PHYS_PAGES);
+
+    if (pagesize < 0)
+	pagesize = 4096;
+    if (pages > 0)
+	mem = pages * pagesize;
+
+    return mem;
+}
+
+static unsigned long getmem_proc(int thread)
+{
+    unsigned long mem = getmem_total();
+    /*
+     * Conservative estimates for thread use on 32bit systems where address

Just curious (no nitpick here), where do these estimates come from? They don't seem totally arbitrary so I suppose there's some technical reason behind them?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2418#pullrequestreview-1353082629
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/2418/review/1353082629 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20230322/b1f5a4b7/attachment.html>


More information about the Rpm-maint mailing list