Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
C standard library
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Compiler built-in functions === Some compilers (for example, [[GNU Compiler Collection|GCC]]<ref>{{cite book |author=FSF |author-link=Free Software Foundation |date=2024 |chapter=6.64 Other Built-in Functions Provided by GCC |chapter-url=https://gcc.gnu.org/onlinedocs/gcc/Other-Builtins.html |title=A GNU Manual |url=https://gcc.gnu.org/onlinedocs/gcc/index.html |publisher=self-published}}</ref>) provide built-in versions of many of the functions in the C standard library; that is, the implementations of the functions are written into the compiled [[object file]], and the program calls the built-in versions instead of the functions in the C library [[shared object]] file. This reduces function-call overhead, especially if function calls are replaced with [[inline function|inline]] variants, and allows other forms of [[compiler optimization|optimization]] (as the compiler knows the [[control flow|control-flow]] characteristics of the built-in variants), but may cause confusion when debugging (for example, the built-in versions cannot be replaced with [[instrumentation (computer programming)|instrumented]] variants). However, the built-in functions must behave like ordinary functions in accordance with ISO C. The main implication is that the program must be able to create a pointer to these functions by taking their address, and invoke the function by means of that pointer. If two pointers to the same function are derived in two different translation units in the program, these two pointers must compare equal; that is, the address comes by resolving the name of the function, which has external (program-wide) linkage.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)