Page MenuHomeFreeBSD

Force 32-bit powerpc to use sync instead of lwsync in CK
ClosedPublic

Authored by jhibbits on Jul 29 2018, 8:07 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Apr 21, 1:38 AM
Unknown Object (File)
Mar 18 2024, 5:38 AM
Unknown Object (File)
Mar 5 2024, 4:10 AM
Unknown Object (File)
Feb 26 2024, 3:59 AM
Unknown Object (File)
Feb 15 2024, 8:06 PM
Unknown Object (File)
Dec 6 2023, 9:17 PM
Unknown Object (File)
Nov 27 2023, 12:32 PM
Unknown Object (File)
Nov 12 2023, 7:07 PM

Details

Summary

Some 32-bit powerpc variants (e500 in particular) do not handle
lwsync's opcode, and instead trigger an Illegal Instruction (Program) exception.
As the only signifcant powerpc architectures that implement lwsync are 64-bit,
force the 32-bit powerpc atomic barriers to all be sync.

This could possibly be less pessimized to use isync in places instead, however
this change fixes booting on e500 cores. Without it, e500 cores panic in
swi_add().

This was also filed on GitHub https://github.com/concurrencykit/ck/pull/122

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 18420
Build 18129: arc lint + arc unit

Event Timeline

I don’t know that ppc32 is worth too much of a time investment at this point beyond keeping it working. However, you should try running the CK regression suite. Kevin encountered a number of bugs on ppc64.

Something similar to this will happen upstream. I'm not sure what effect applying this in src/ will have when we do the vendor import but the change looks good to me.

This revision is now accepted and ready to land.Jul 29 2018, 11:10 PM

This review is obsolete, we fixed the issue upstream in https://github.com/concurrencykit/ck/commit/5ff2e9d3e6fffa4be41c932b32a7e49a429495e3. @cognet can you MFV CK into HEAD before the slush?