Bug 740

Summary: sync instruction incorrectly assigned to OP_NOP
Product: Libre-SOC's first SoC Reporter: Jacob Lifshay <programmerjake>
Component: Source CodeAssignee: Luke Kenneth Casson Leighton <lkcl>
Status: CONFIRMED ---    
Severity: major CC: libre-soc-bugs, programmerjake
Priority: ---    
Version: unspecified   
Hardware: All   
OS: All   
NLnet milestone: --- total budget (EUR) for completion of task and all subtasks: 0
budget (EUR) for this task, excluding subtasks' budget: 0 parent task for budget allocation:
child tasks for budget allocation: The table of payments (in EUR) for this task; TOML format:

Description Jacob Lifshay 2021-11-05 21:43:15 GMT
I'm assuming it should be instead assigned to OP_FENCE or similar, but am not changing it right now to not break our code, since treating it as a nop mostly works for a single-core system.

https://git.libre-soc.org/?p=openpower-isa.git;a=blob;f=openpower/isatables/minor_31.csv;h=dcadd41ca276fc3a2046aea5dd505de0702538f5;hb=HEAD#l199
Comment 1 Luke Kenneth Casson Leighton 2021-11-05 22:00:17 GMT
we are copying microwatt verbatim.  microwatt caches are writethru.
therefore sync is inherently a nop.
Comment 2 Jacob Lifshay 2021-11-05 22:14:40 GMT
(In reply to Luke Kenneth Casson Leighton from comment #1)
> we are copying microwatt verbatim.  microwatt caches are writethru.
> therefore sync is inherently a nop.

well, that only works on a single-core system. on a multi-core system, we also need to wait for all in-progress load/stores, and execute a system-wide synchronization of some sort (needed for supporting sequential-consistency atomic thread fences).