Page MenuHomeFreeBSD

Make truss(8) work for i686-unknown-cloudabi binaries on FreeBSD/amd64.
ClosedPublic

Authored by ed on Dec 16 2017, 6:19 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Jan 30, 3:38 AM
Unknown Object (File)
Sat, Jan 25, 7:58 PM
Unknown Object (File)
Sat, Jan 25, 7:26 PM
Unknown Object (File)
Fri, Jan 24, 1:46 AM
Unknown Object (File)
Thu, Jan 23, 3:16 AM
Unknown Object (File)
Jan 16 2025, 8:27 PM
Unknown Object (File)
Jan 15 2025, 9:56 PM
Unknown Object (File)
Jan 12 2025, 9:29 PM
Subscribers

Details

Summary

This change copies the existing amd64_cloudabi64.c to amd64_cloudabi32.c
and reimplements the functions for fetching system call arguments and
return values to use the same scheme as used by the vDSO that is used
when running cloudabi32 executables.

As arguments are automatically padded to 64-bit words by the vDSO in
userspace, we can copy the arguments directly into the array used by
truss(8) internally.

This change also has some changes for libsysdecode. These will be
committed separately. For libsysdecode, we add a new ABI type,
SYSDECODE_ABI_CLOUDABI32. We also remove all of the #ifdef bits, as
these are not needed. The cloudabi32 and cloudabi64 system call tables
and headers can be built on any FreeBSD architecture without any issues.

Test Plan

make universe seems to pass. Tracing 32-bit processes on FreeBSD/amd64
seems to work fine.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 13616
Build 13839: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Dec 16 2017, 6:32 PM
This revision was automatically updated to reflect the committed changes.