[Openmp-commits] [PATCH] D45528: [OpenMP] Remove compilation warning when using clang to compile bc files.

George Rokos via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Fri Apr 13 15:39:17 PDT 2018


grokos added a comment.

In https://reviews.llvm.org/D45528#1067615, @guansong wrote:

> In https://reviews.llvm.org/D45528#1067520, @grokos wrote:
>
> > In https://reviews.llvm.org/D45528#1067487, @guansong wrote:
> >
> > > update as suggested (except PRId64)
> >
> >
> > Isn't `PRId64` working?
>
>
> I did not find any usage of it on the device side. Not confident on using it. We can remove the warning first, and improve the format later?


It's not giving a warning because in CUDA `long long int` happens to be 64 bits long, so you can use `%lld` to print an `int64_t`. This is not guaranteed to be true on every platform, therefore the portable way to print an `int64_t` is using the `PRId64` macro. That's what we do in the base library.


https://reviews.llvm.org/D45528





More information about the Openmp-commits mailing list