Page MenuHomeFreeBSD

fenv: Use slow path in C++
ClosedPublic

Authored by aokblast on Jun 4 2026, 5:48 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Sep 13, 11:09 PM
Unknown Object (File)
Sat, Sep 12, 3:42 AM
Unknown Object (File)
Mon, Sep 7, 11:33 PM
Unknown Object (File)
Wed, Sep 2, 6:35 AM
Unknown Object (File)
Mon, Aug 31, 9:45 AM
Unknown Object (File)
Mon, Aug 31, 6:38 AM
Unknown Object (File)
Mon, Aug 31, 6:31 AM
Unknown Object (File)
Sun, Aug 30, 2:38 PM
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