Change information
Commit message:
internal/runtime/sys: improve DIT assembly
In EnableDIT, if DIT is already enabled, return early instead of
executing MSR and DSB/ISB, since they are not particularly cheap
instructions.
Also, if we have support for the SB (Speculation Barrier) instruction,
use it instead of DSB+ISB when enabling DIT, since SB is cheaper.
Change-Id: I1b3ecbd95ed42bfd10d646125704abf4e80b6d2e
Files:
- M src/internal/runtime/sys/dit_arm64.go
- M src/internal/runtime/sys/dit_arm64.s
Change size: S
Delta: 2 files changed, 11 insertions(+), 3 deletions(-)
Branch: refs/heads/master
Submit Requirements:
Code-Review: +2 by Keith Randall, +1 by Keith Randall
TryBots-Pass: LUCI-TryBot-Result+1 by Go LUCI