[PATCH] D63876: [OpenCL] Define CLK_NULL_EVENT without cast

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 1 10:07:18 PDT 2019


Anastasia added a comment.

btw, there seems to be the same issue with `reserve_id_t`?



================
Comment at: lib/Headers/opencl-c-base.h:416
 #define CLK_NULL_QUEUE                              0
-#define CLK_NULL_EVENT (__builtin_astype(((void*)(__SIZE_MAX__)), clk_event_t))
+#define CLK_NULL_EVENT (__builtin_astype(((__SIZE_MAX__)), clk_event_t))
 
----------------
Also I don't quite get why we are not just using value 0. I can't see anything relevant in the commit history. Not sure if @yaxunl can help.

Although it doesn't really block this change.


Repository:
  rC Clang

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D63876/new/

https://reviews.llvm.org/D63876





More information about the cfe-commits mailing list