PR_GET_FPEXC(2const)
π PR_GET_FPEXC π
okay bestie, so this is PR_GET_FPEXC, and it lives in section 2const of the manual β like, it's one of the prctl(2) crew, you know the vibe. And yes, it is exactly as niche as it sounds, but it's also kind of iconic, so let's go. π«Ά
β¨ NAME β¨
PR_GET_FPEXC β get the floating-point exception mode
π LIBRARY π
Standard C library (libc, -lc) β the classic, no cap.
π SYNOPSIS π
#include <linux/prctl.h> /* Definition of PR_* constants */
#include <sys/prctl.h>
int prctl(PR_GET_FPEXC, unsigned int *mode);
πΈ DESCRIPTION πΈ
So what does it actually do? It returns the floating-point exception mode, and it drops that value into the location pointed to by mode. That's it. That's the whole thing. Lowkey elegant honestly. β¨
π₯ RETURN VALUE π₯
- On success,
0is returned. slay. π - On error,
-1is returned, anderrnois set to indicate the error. not slay. π
π ERRORS π
EFAULTβ mode is an invalid address. like girl, that pointer is not pointing anywhere real. π
π STANDARDS π
Linux. PowerPC only. so if you're on x86 this is giving "not for you" energy, sorry bestie. π
π¦ HISTORY π¦
Linux 2.4.21, 2.5.32. (PowerPC) β yeah, it's been around a minute. vintage. π
β SEE ALSO β
prctl(2)PR_SET_FPEXC(2const)β the other half of this duo, the one that sets instead of gets. iykyk. π
and that's the whole page, bestie!! go forth and get your floating-point exception mode πβ¨
this little cutie came to you from Linux man-pages 6.20, dated 2026-02-08, and it's filed under PR_GET_FPEXC(2const) β periodt. ππ¦
π¦ where this page comes from
- arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages 6.20
- π the page's license: Linux-man-pages-copyleft
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms