Skip to content

Syscall arch functions make assumptions about the ABI #544

@2over12

Description

@2over12

The ARMSyscall function assumes a certain set of registers as arguments:

ARMSyscall :: WI.W 24

The function also references the x86 syscall

X86Syscall :: (1 <= w)

In my opinion these functions should not make assumptions about the system ABI. It makes it quite difficult for downstream consumers to handle ad-hoc non-linux platforms.

The comment references that this is due to the fact that translation does not hold onto current register identity (e.g. issues mentioned in #460)

I firstly am not totally convinced we couldn't just expose and populate these syscalls with more GPRs (at least on arm exposing r0-r14 seems reasonable to me). Secondarily regardless of the technical difficulties this limitations is going to cause some larger issues downstream and it also may be worth going after some solution to #460 to pass the full reg state to syscalls.

Regardless of approach I do think ideally we would lift this restriction

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions