Ensure no frame is created for assembly functions

This commit is contained in:
Kovid Goyal 2024-03-15 07:58:09 +05:30
parent d329cb3fff
commit 32f0da2e77
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -1151,7 +1151,7 @@ func (s *Function) OutputASM(w io.Writer) {
}
fmt.Fprint(w, "// ")
s.print_signature(w)
fmt.Fprintf(w, "\nTEXT ·%s(SB), NOSPLIT, $0-%d\n", s.Name, s.Size)
fmt.Fprintf(w, "\nTEXT ·%s(SB), NOSPLIT|TOPFRAME|NOFRAME, $0-%d\n", s.Name, s.Size)
has_trailing_return := false
for _, i := range s.Instructions {