Page MenuHomeFreeBSD

Add options to dmb() and dsb() macros
ClosedPublic

Authored by zbb on Jun 1 2015, 12:14 AM.
Tags
None
Referenced Files
Unknown Object (File)
Feb 9 2024, 11:54 AM
Unknown Object (File)
Feb 3 2024, 3:40 AM
Unknown Object (File)
Dec 23 2023, 8:04 AM
Unknown Object (File)
Dec 20 2023, 12:24 AM
Unknown Object (File)
Nov 13 2023, 10:51 AM
Unknown Object (File)
Oct 24 2023, 9:16 PM
Unknown Object (File)
Oct 21 2023, 6:23 PM
Unknown Object (File)
Sep 23 2023, 1:26 AM

Details

Summary

Using plain dsb()/dmb() as full system barriers is usually to much.
Adding proper options to those barriers (instead of full system - sy)
will most likely reduce the cost of the instructions and will benefit
in performance improvement.
This commit adds options to barrier macro definitions.

Obtained from: Semihalf
Sponsored by: The FreeBSD Foundation

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

zbb retitled this revision from to Add options to dmb() and dsb() macros.
zbb updated this object.
zbb edited the test plan for this revision. (Show Details)
zbb added reviewers: andrew, emaste, imp, ian.
zbb set the repository for this revision to rS FreeBSD src repository - subversion.
zbb added a subscriber: Unknown Object (MLST).

Given you are changing these can you also mark them as with ish*?

sys/arm64/arm64/db_interface.c
164–165

Are these needed? The cache handling functions already have dsb and isb instructions.

sys/arm64/include/atomic.h
32

This should be #define<tab>isb()...

49–54

And these

zbb updated this object.
zbb edited edge metadata.
zbb removed rS FreeBSD src repository - subversion as the repository for this revision.
zbb marked 3 inline comments as done.
ian edited edge metadata.

Is this really all the instances of dmb() and dsb() in the code? I guess most of them must be in asm and inline-asm code.

This revision is now accepted and ready to land.Jun 6 2015, 8:05 PM
In D2701#52274, @ian wrote:

Is this really all the instances of dmb() and dsb() in the code? I guess most of them must be in asm and inline-asm code.

Yes, however there will be some more in the ITS code.