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)
Sun, Nov 24, 4:26 PM
Unknown Object (File)
Sun, Nov 17, 4:46 AM
Unknown Object (File)
Fri, Nov 15, 8:43 PM
Unknown Object (File)
Oct 16 2024, 12:00 PM
Unknown Object (File)
Oct 6 2024, 3:46 AM
Unknown Object (File)
Oct 2 2024, 3:28 AM
Unknown Object (File)
Oct 2 2024, 3:19 AM
Unknown Object (File)
Oct 2 2024, 3:19 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.