Date: Sun, 25 Jun 2017 16:53:43 -0500 From: "A. Wilcox" <AWilcox@Wilcox-Tech.com> To: freebsd-current@freebsd.org Subject: Re: Skylake/Kabylake Intel Bug? Message-ID: <595030E7.1030400@Wilcox-Tech.com> In-Reply-To: <a5e8f4c4-9cbb-d229-12a7-ce9c21bfe832@nomadlogic.org> References: <a5e8f4c4-9cbb-d229-12a7-ce9c21bfe832@nomadlogic.org>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --oWrui7sighJOoOaDG4ciP7MC2HroSsFJr Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 25/06/17 12:56, Pete Wright wrote: > Came across this post today via HN regarding a issue with Hyperthreadin= g > causing unpredictable behavior on these CPU's >=20 > https://lists.debian.org/debian-devel/2017/06/msg00308.html >=20 > I really wish there was more info on this in the email, for example > examples of programs being effected by this bug. Anywho - was wonderin= g > if any devs here had more info on this issue and could provide better > context? >=20 > Cheers, >=20 > -pete >=20 The linked OCaml issue goes quite in-depth with the mechanisms behind this bug and the risks behind not patching the microcode: https://caml.inria.fr/mantis/view.php?id=3D7452 Basically, if a HyperThreaded core is running a tight loop accessing %rax and %ah (or %rbx and %bh, etc) in quick succession, on both threads of the same physical core, it can corrupt/poison L1d cache. AIUI, OCaml manages to generate this code by manipulating tagged memory addresses and the corresponding tag (the address is in %rax, and the tag is at %ah). I'd really love to see if this affects write-through-no-allocate cache or only write-behind, but I haven't seen any program besides OCaml actually manage to get GCC to generate the insn pattern that is needed, and I don't have a Skylake or Kaby Lake CPU to test with anyway. Fun little hardware bug. Hope this helps you, --arw --=20 A. Wilcox (awilfox) Open-source programmer (C, C++, Python) https://code.foxkit.us/u/awilfox/ --oWrui7sighJOoOaDG4ciP7MC2HroSsFJr Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJZUDDoAAoJEMspy1GSK50UjTwP/RY1Vm2PsJcVFVrMccqPHVJZ PxvYL6KZrZOj4yfSIJYpB3LAPlrsIqhy6oxWEvF+2aP3FHlIIvswY4v3mAwlNQhc xlwrLQDf1kQARBsVdlGx0Y8jd8SO9Ux2UdHPh7fLqzkGgg0MmRvQH9phfG43CDRk C8qfhgGhwDy2e+RoQ0WahBGhnKtkkVxXB/NEdkouPG5eS9q4nkxBaFuc3IRQOhTh okpaDvHDWVIHt8t68fZKKM2uUm4x8Qpis6iE1LdyzTRNAebmZisIqqvdbDGb4zTb P0rxpKIMQWRBlqbfpTkguy24zXKv5410bxP28bKRGSa6JntkXNB+Wo8bunRWyaQI x0LT2XlpamX2AO9ngjaxjaXgFEVR6+HnyJ3c5tg+WBqI0lWHY71903nYOxkNqKS5 7rIro4DOprursSnusIGxHUV5cinvNGJRBssmA/ZMD6XNRx0xi5EiX8/yQYZEY7zr f2m7VOE0J3GvYZuBaGoMynDYAhehs5voN82VMqYz+AiCI4SNyOHKskJY/Wz/gZIB oKy54jRK14ztnUDTl4tOsvgBBihtoIyzqZlDDYHZ3ThJ6W9D2DQcC44c4scfQww7 6nXks8G9gkpG5DrzfKpsqR5ncppjSssJK+fKQESt8JB9ImRV2YXGAA1YP5fL0V0q cfhi60uHC/EMI01soStK =LCro -----END PGP SIGNATURE----- --oWrui7sighJOoOaDG4ciP7MC2HroSsFJr--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?595030E7.1030400>