Page MenuHomeFreeBSD

tip: Fix pointer-vs-integer confusion
ClosedPublic

Authored by jrtc27 on Jun 8 2021, 3:07 PM.
Tags
None
Referenced Files
F162352155: D30697.diff
Sun, Jul 12, 9:18 AM
Unknown Object (File)
Wed, Jul 8, 1:27 PM
Unknown Object (File)
Sat, Jul 4, 2:29 PM
Unknown Object (File)
Sat, Jul 4, 4:42 AM
Unknown Object (File)
Thu, Jul 2, 5:02 PM
Unknown Object (File)
Wed, Jul 1, 1:59 AM
Unknown Object (File)
Tue, Jun 30, 4:46 AM
Unknown Object (File)
Thu, Jun 25, 1:53 AM
Subscribers
None

Details

Summary

Currently IREMOTE assumes that every value is (initially) a pointer to a
long. This is true for NUMBERs, but false for STRINGs, which are instead
pointers to pointers, though on ILP32 and LP64 systems these happen to
have the same representation, but this is still a strict aliasing
violation, and of course breaks on systems where the representations are
not the same, such as CHERI. We do not currently have any BOOLs (short,
curiously) or CHARs used with IREMOTE, though the code should not be
relying on that.

This removes the unused setaddress macro, and the now-unused address
macro due to the above issue.

Obtained from: CheriBSD

Diff Detail

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