[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260130080128.17cde0d3@pumpkin>
Date: Fri, 30 Jan 2026 08:01:28 +0000
From: David Laight <david.laight.linux@...il.com>
To: Cheng Li <im.lechain@...il.com>
Cc: Willy Tarreau <w@....eu>, Thomas Weißschuh
<linux@...ssschuh.net>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 1/2] tools/nolibc: support left alignment (-) and
zero padding (0) in printf
On Fri, 30 Jan 2026 09:05:39 +0800
Cheng Li <im.lechain@...il.com> wrote:
> David Laight <david.laight.linux@...il.com> 于2026年1月29日周四 18:30写道:
...
> These are great suggestions for a larger refactoring of printf to
> improve performance and standard compliance.
> However, to keep this current change minimal and safe, I prefer to
> focus on fixing the alignment feature first.
>
> @Willy, I will send a v3 that removes the '0' flag handling logic to
> avoid the bug pointed out above.
>
> I will rethink how to implement leading zero pad support.
You made me look at the code.
A simple refactor saved 98 bytes (about 10%).
I will look at adding support for field precision - which is what
is needed for leading zeros.
Will use up some of the saved space, but probably not all of it.
I'll base any patch on top of your change.
David
Powered by blists - more mailing lists