Don't clobber the frame pointer (nsrip.com)
from tedu@inks.tedunangst.com to inks@inks.tedunangst.com on 05 Jan 09:34
https://inks.tedunangst.com/l/5157

Recently I diagnosed and fixed two frame pointer unwinding crashes in Go. The root causes were two flavors of the same problem: buggy assembly code clobbered a frame pointer. By “clobbered” I mean wrote over the value without saving & restoring it. One bug clobbered the frame pointer register. The other bug clobbered a frame pointer saved on the stack. This post explains the bugs, talks a bit about ABIs and calling conventions, and makes some recommendations for how to avoid the bugs.

#bugfix #compiler #cpu #go #programming

#bugfix #compiler #cpu #go #inks #programming

threaded - newest