aboutsummaryrefslogtreecommitdiff
path: root/src/parser.cpp
diff options
context:
space:
mode:
authorYawning Angel <yawning@schwanenlied.me>2021-11-13 20:21:52 +0000
committerYawning Angel <yawning@schwanenlied.me>2021-11-13 20:40:27 +0000
commit6ea68869c934807f1ecdc411e58bdce6b64ee7e2 (patch)
tree0dc02ea2d1996cb6559006c949d136d359cdfb6e /src/parser.cpp
parentbfa23f1352d0df719b84e467d9c7df29f98c7834 (diff)
src: "Fix" the system call intrinsic for FreeBSD
FreeBSD's systemcall handler clears out R8, R9, and R10 prior to `sysretq`, and additionally returns positive errno (with CF) set on error. This modifies the syscall intrinsic such that LLVM knows about the additional clobbered registers. Note that propagating CF back to the caller of the syscall intrinsic is left for a future PR. As far as I can tell, Darwin does not use the syscall intrinsic at all, and FreeBSD only uses it for SYS_GETTID, so this should be "ok" for now. See: sys/amd64/amd64/exception.S in the FreeBSD src for more details.
Diffstat (limited to 'src/parser.cpp')
0 files changed, 0 insertions, 0 deletions