Messages in this thread | | | From | Nick Desaulniers <> | Date | Thu, 11 Aug 2022 15:04:29 -0700 | Subject | Re: mainline build failure for arm64 allmodconfig with clang |
| |
On Thu, Aug 11, 2022 at 12:35 PM Linus Torvalds <torvalds@linux-foundation.org> wrote: > > On Thu, Aug 11, 2022 at 11:39 AM Nick Desaulniers > <ndesaulniers@google.com> wrote: > > > > Generally, printing an int with %hhu may truncate depending on the > > value of the int. > > Yes. > > HOWEVER. > > That truncation is *LITERALLY THE MAIN REASON TO EVER USE %hhu IN THE > FIRST PLACE*. > > See the issue? > > Warning about "this may truncate bits" when the main reason to use > that format string in the first place is said bit truncation is kind > of stupid, isn't it?
Yeah, I guess adding a truncate to the caller is kind of unnecessary if you're still going to use %hhd anyways. What are your thoughts on this bug I've filed? https://github.com/llvm/llvm-project/issues/57102
-- Thanks, ~Nick Desaulniers
| |