- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I would like to completely disable inlining to understand how optimizations are done,
and I couldn't get from documentation if -O0 disables inlining as doing -fno-inline.
Is -O0implying -fno-inline?
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
-inline-level=0 (Linuxand Mac) or /Ob0 (Windows)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, -O0 should disable in-lining optimization. For linux, to disable in-lining at higher levels of optimization, -fno-inline-functions (a gcc option) is recommended.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
__declspec( noinline )
void foo()
{
...
}
Jim Dempsey
void foo()
{
...
}
Jim Dempsey


Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page