1
0
mirror of https://github.com/golang/go synced 2024-07-08 20:29:48 +00:00

doc/asm: add BP is callee-save paragraph

Change-Id: Id38e639c66a42acf0b1c4488cdfd0b7b6cf71c78
Reviewed-on: https://go-review.googlesource.com/c/go/+/250397
Reviewed-by: Keith Randall <khr@golang.org>
This commit is contained in:
Egon Elbre 2020-08-25 10:38:50 +03:00 committed by Keith Randall
parent 4d89b3231d
commit d7a6a44deb

View File

@ -687,6 +687,13 @@ MOVQ g(CX), AX // Move g into AX.
MOVQ g_m(AX), BX // Move g.m into BX.
</pre>
<p>
Register <code>BP</code> is callee-save.
The assembler automatically inserts <code>BP</code> save/restore when frame size is larger than zero.
Using <code>BP</code> as a general purpose register is allowed,
however it can interfere with sampling-based profiling.
</p>
<h3 id="arm">ARM</h3>
<p>