[PATCH] D70143: Check result of emitStrLen before passing it to CreateGEP

Dimitry Andric via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 12 14:03:09 PST 2019


dim added a comment.

In D70143#1742885 <https://reviews.llvm.org/D70143#1742885>, @lebedev.ri wrote:

> This should have a llvm ir test in `llvm/test/transforms/instcombine` i think, not a clang test.


Yes, I thought so too, but I could not get it to work (i.e. crash) with LLVM IR.  I just don't understand how `opt` works, and it does not have a `-fno-builtin-strlen` option either.  Therefore, I made it work with clang, as having a working test is better than no test at all.  But I'm fine with leaving out the test, it was just for completeness' sake.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D70143





More information about the cfe-commits mailing list