Page MenuHomeFreeBSD

fenv: Use slow path in C++
ClosedPublic

Authored by aokblast on Jun 4 2026, 5:48 PM.
Tags
None
Referenced Files
F167358557: D57450.id179440.diff
Fri, Aug 21, 7:00 AM
Unknown Object (File)
Wed, Aug 12, 10:12 AM
Unknown Object (File)
Tue, Aug 11, 12:30 PM
Unknown Object (File)
Tue, Aug 11, 10:54 AM
Unknown Object (File)
Fri, Aug 7, 5:59 AM
Unknown Object (File)
Fri, Aug 7, 3:32 AM
Unknown Object (File)
Thu, Aug 6, 1:54 PM
Unknown Object (File)
Thu, Aug 6, 10:09 AM
Subscribers

Details

Summary

C++ exposes cfenv functions svia using ::func. Our name-mangling
mechanism rewrites all function calls causing symbols such as
std::feclearexcept to be transformed into std::__feclearexcept_int.
Since no such function exists, compilation fails.

The using ::feclearexpect declarations themselves are unaffected because
they are not function calls, which further exposes the mispatch

As a result, enable the fast path only for C and fall back to the slow
path in C++.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable