News for hackers. Stuff that matters.
Re:PCID is now a critical performance/security feature on x86 by loeg on Monday January 08, 2018 @07:25PM (#16102336)
Can you name a mainstream OS (for any definition of "mainstream" you like, really) that doesn't use PCID?
Re:PCID is now a critical performance/security feature on x86 by LinuxBender on Monday January 08, 2018 @07:37PM (#16102408)
Someone please correct me if I am incorrect, but that would be any mainstream linux not using the 4.14 kernel. Redhat, CentOS, Suse at least. Looks like CoreOS that is on 4.14 is on a minor release just prior to the PCID patch.

It looks like Ubuntu 18 Bionic Beaver may have it. (4.15) I suppose some folks use Ubuntu in a datacenter, but more likely the LTS releases and 18 is not likely in many production datacenters.

Can you confirm that Redhat backported that newer PCID code into the 3.10 kernel branch? If so, people should not be seeing a performance hit on the KPTI patch.

Re:PCID is now a critical performance/security feature on x86 by loeg on Tuesday January 09, 2018 @12:33PM (#16107932)
Ah, I didn't realize Linux was so behind in supporting PCID here. Thanks! For what it's worth, Fedora Linux is on kernel 4.14.11 already.

Curiously enough, FreeBSD has had PCID support since 2013 (r255060). We found it improved performance in microbenchmarks:

> In the microbenchmarks, using the PCID decreased latency of the context switches by ~30% on SandyBridge class desktop CPUs, measured with the lat_ctx program from lmbench.

> If available, use INVPCID instruction when a TLB entry in non-current address space needs to be invalidated. The instruction is typically available on the Haswell.

Re:PCID is now a critical performance/security feature on x86 by LinuxBender on Tuesday January 09, 2018 @12:51PM (#16108091)
You're welcome! We were trying to unravel that post about PCID as well.

It appears the first PCID code was merged in 4.14.12 so you will probably have that in the coming days / weeks. CoreOS is also 4.14.11.

For those on LTS releases, we may have to venture into uncharted waters. The first that came to mind was elrepo.org, as they apply some of the same build options that Redhat uses against the latest upstream. Their kernel packages are meant to provide support for newer laptop hardware...

Re:PCID is now a critical performance/security feature on x86 by c2h5oh on Monday January 08, 2018 @09:33PM (#16103047)
Linux if it's running kernel older than 8 weeks.