Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Sep 2019 11:14:42 -0700
From:      Mark Millard <marklmi@yahoo.com>
To:        Mark Johnston <markj@freebsd.org>
Cc:        FreeBSD Current <freebsd-current@freebsd.org>
Subject:   Re: "cpuset -n prefer:?" --what values for "?" are supposed to be allowed? (only 1 is, despite two numa domains)
Message-ID:  <54F53CA8-6BEC-4B31-9662-C6854CDE0A08@yahoo.com>
In-Reply-To: <3CE4AEB7-E32C-49BD-8C75-71AB8739BAEC@yahoo.com>
References:  <C230AB3E-2FCF-4837-A4FD-A29F037647FC@yahoo.com> <20190911143125.GA17992@raichu> <99BB5653-1F42-4309-9892-24029FD02E39@yahoo.com> <20190911151512.GB17992@raichu> <3CE4AEB7-E32C-49BD-8C75-71AB8739BAEC@yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help


On 2019-Sep-11, at 10:11, Mark Millard <marklmi at yahoo.com> wrote:



> On 2019-Sep-11, at 08:15, Mark Johnston <markj at freebsd.org> wrote:
>=20
>> On Wed, Sep 11, 2019 at 07:57:26AM -0700, Mark Millard wrote:
>>>=20
>>>=20
>>> On 2019-Sep-11, at 07:31, Mark Johnston <markj at freebsd.org> =
wrote:
>>>=20
>>>> On Tue, Sep 10, 2019 at 10:58:05PM -0700, Mark Millard wrote:
>>>>> In a context with:
>>>>>=20
>>>>> # cpuset -g
>>>>> pid -1 mask: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, =
16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27
>>>>> pid -1 domain policy: first-touch mask: 0, 1
>>>>>=20
>>>>> I get:
>>>>>=20
>>>>> # cpuset -l0 -n prefer:0 COMMAND
>>>>> cpuset: setdomain: Invalid argument
>>>>>=20
>>>>> # cpuset -l0 -n prefer:2 COMMAND
>>>>> cpuset: setdomain: Invalid argument
>>>>>=20
>>>>> But one prefer:? value does allow the COMMAND
>>>>> to run:
>>>>>=20
>>>>> # cpuset -l0 -n prefer:1 COMMAND
>>>>>=20
>>>>> This seem odd to me. Am I missing something?
>>>>>=20
>>>>> For reference: I'm using a ThreadRipper 1950X
>>>>> with a head -r351227 based context for this
>>>>> activity. The above happens to have been run
>>>>> in a Windows 10 Pro HyperV session, instead
>>>>> of in a native-boot of the same media. (A
>>>>> native-boot would have had 32 CPUs.)
>>>>=20
>>>> Can you please show the output of "sysctl vm.phys_segs" from this
>>>> setup?
>>>=20
>>> Sure:
>>=20
>> I was wondering if you had only one domain populated, but it seems =
not
>> to be the case.  Could you try updating to r351672 or later and see =
if
>> the behaviour persists?
>=20
> It may be a bit before I do that.
>=20
> FYI: I had set MAXMEMDOM to match the number of
> actual domains for the context:
>=20
> /usr/src/sys/amd64/conf/GENERIC-DBG:options     MAXMEMDOM=3D2
> /usr/src/sys/amd64/conf/GENERIC-NODBG:options   MAXMEMDOM=3D2
>=20
> (These kernel configuration files include GENERIC.)

Not that the below is the problem that I reported, but
cpuset_modify_domain has an oddity. In the below, note
the "root->" use followed by the "root &&" test: the
root-> use would have failed first. Should the && be
"dset &&" instead? Should "root &&" just be removed for
being redundant?

793	                root =3D cpuset_getroot(set);
794	                mtx_lock_spin(&cpuset_lock);
795	                dset =3D root->cs_domain;
796	                /*
797	                 * Verify that we have access to this set of =
domains.
798	                 */
799	                if (root && !domainset_valid(dset, domain)) {
800	                        error =3D EINVAL;
801	                        goto out;
802	                }

=3D=3D=3D
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?54F53CA8-6BEC-4B31-9662-C6854CDE0A08>