|
dune-common 2.12-git
|
Loading...
Searching...
No Matches
forceinline.hh File Reference
Provide the macro DUNE_FORCE_INLINE that expands to attribute always_inline or similar depending on the compiler (version).
More...
Go to the source code of this file.
Macros | |
| #define | DUNE_FORCE_INLINE inline |
Detailed Description
Provide the macro DUNE_FORCE_INLINE that expands to attribute always_inline or similar depending on the compiler (version).
Some information is extracted from https://meghprkh.github.io/blog/posts/c++-force-inline.
The effect of DUNE_FORCE_INLINE is typically as follows:
- Inlining heuristics are disabled and inlining is always attempted regardless of optimization level.
- Ignore
-fno-inline - Ignore the inlining limits hence inlining the function regardless. It also inlines functions with allocation calls, which
inlinekeyword never does.
Even when marked with DUNE_FORCE_INLINE, the compiler cannot always inline a function. Examples for such exceptions are
- The function is virtual and is called virtually.
- The program calls a function indirectly via a pointer to the function.
- The function uses a variable argument list.
Example:
Macro Definition Documentation
◆ DUNE_FORCE_INLINE
| #define DUNE_FORCE_INLINE inline |
Legal Statements / Impressum | Hosted by TU Dresden & Uni Heidelberg | Generated by
1.9.8