[PATCH] D156497: [BPF] Emit UNDEF rather than constant 0

Yonghong Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 12 22:51:41 PDT 2023


yonghong-song added a comment.

In D156497#4578070 <https://reviews.llvm.org/D156497#4578070>, @tamird wrote:

> Yes, thank you. As mentioned earlier, we have fixed this bug. The purpose of this patch is to be defensive and avoid this footgun for future users of the LLVM C API.
>
> Do you feel that this patch degrades the quality of the implementation?

With current clang, could you show me the error message with 'constant 0' vs. 'undef'? We can then decide to pick the one which is more user friendly.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D156497



More information about the llvm-commits mailing list