mbox series

[liburing,v1,0/3] Clean up clang `-Wshorten-64-to-32` warnings

Message ID 20221020114814.63133-1-ammar.faizi@intel.com (mailing list archive)
Headers show
Series Clean up clang `-Wshorten-64-to-32` warnings | expand

Message

Ammar Faizi Oct. 20, 2022, 11:52 a.m. UTC
From: Ammar Faizi <ammarfaizi2@gnuweeb.org>

Hi Jens,

Please consider this small cleanup series before the release.

This series is a follow up of the clean up `-Wshorten-64-to-32`
warnings that I discussed with Dylan previously. It only addresses
the warnings in the src/ dir (main library). We ignore the tests
for now.

`-Wshorten-64-to-32` is a clang-specific flag, it currently doesn't
exist in GCC.

There are 3 patches in this series:

- Patch 1 is to clean up the warnings in the main library
  (this is based on a patch from Dylan).

  Taken from: https://github.com/DylanZA/liburing/commit/cdd6dfbb9019.patch

- Patch 2 is to introduce LIBURING_CFLAGS variable in the Makefile. We
  need this varaible to apply specific compiler flags to the main
  library only. Currently, this flag is only used by the GitHub bot.

- Patch 3 is to integrate `-Wshorten-64-to-32` flag to the GitHub bot.

Signed-off-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
---

Ammar Faizi (2):
  Makefile: Introduce `LIBURING_CFLAGS` variable
  github: Append `-Wshorten-64-to-32` flag for clang build

Dylan Yudaken (1):
  liburing: Clean up `-Wshorten-64-to-32` warnings from clang

 .github/workflows/build.yml |  4 ++++
 src/Makefile                |  5 ++++-
 src/arch/syscall-defs.h     |  4 ++--
 src/register.c              |  5 ++++-
 src/setup.c                 | 12 ++++++------
 src/syscall.h               |  4 ++--
 6 files changed, 22 insertions(+), 12 deletions(-)


base-commit: 2950c0c1b23ef6bc3cfa3646adbfeffc23fc59cf

Comments

Dylan Yudaken Oct. 20, 2022, 12:53 p.m. UTC | #1
On Thu, 2022-10-20 at 18:52 +0700, Ammar Faizi wrote:
> From: Ammar Faizi <ammarfaizi2@gnuweeb.org>
> 
> - Patch 2 is to introduce LIBURING_CFLAGS variable in the Makefile.
> We
>   need this varaible to apply specific compiler flags to the main
>   library only. Currently, this flag is only used by the GitHub bot.
> 
> - Patch 3 is to integrate `-Wshorten-64-to-32` flag to the GitHub
> bot.


I think better to take my co-authored and signed-off tags from patch
2/3, as its not really similar to what I had done

Thanks,
Dylan
Ammar Faizi Oct. 20, 2022, 12:57 p.m. UTC | #2
On 10/20/22 7:53 PM, Dylan Yudaken wrote:
> I think better to take my co-authored and signed-off tags from patch
> 2/3, as its not really similar to what I had done

I'll send v2 with that fixed.