Take entry point into account when inlining