Skip to content

Commit f372b22

Browse files
committed
vsnprintf: inline skip_atoi() again
At some point skip_atoi() had been marked 'noinline_for_stack', but it turns out that this is now a pessimization, and not inlining it actually results in a stack frame in format decoding due to the call and thus hurts stack usage rather than helping. With the simplistic atoi function inlined, the format decoding now needs no frame at all. Signed-off-by: Linus Torvalds <[email protected]>
1 parent 614d134 commit f372b22

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/vsprintf.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,7 @@ long long simple_strtoll(const char *cp, char **endp, unsigned int base)
160160
}
161161
EXPORT_SYMBOL(simple_strtoll);
162162

163-
static noinline_for_stack
164-
int skip_atoi(const char **s)
163+
static inline int skip_atoi(const char **s)
165164
{
166165
int i = 0;
167166

0 commit comments

Comments
 (0)