[PATCH] D37628: Cleanup: Merge isKnownNonNull into isKnownNonZero

Nuno Lopes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 8 09:09:05 PDT 2017


nlopes created this revision.

This patch just copies the relevant bits from isKnownNonNull into isKnownNonZero and replaces all uses of isKnownNonNull with isKnownNonZero.

As a bonus, this patch fixes a bug that made isKnownNonNull consider that alloca always returns a non-null ptr with address space != 0.


Repository:
  rL LLVM

https://reviews.llvm.org/D37628

Files:
  include/llvm/Analysis/ValueTracking.h
  lib/Analysis/InstructionSimplify.cpp
  lib/Analysis/LazyValueInfo.cpp
  lib/Analysis/Loads.cpp
  lib/Analysis/ValueTracking.cpp
  lib/Transforms/IPO/FunctionAttrs.cpp
  lib/Transforms/InstCombine/InstCombineCalls.cpp
  lib/Transforms/Utils/PromoteMemoryToRegister.cpp
  test/Other/cgscc-libcall-update.ll
  test/Transforms/FunctionAttrs/nonnull.ll
  test/Transforms/InstCombine/lifetime.ll
  test/Transforms/InstCombine/memcpy-addrspace.ll
  test/Transforms/InstCombine/memcpy-from-global.ll
  test/Transforms/InstCombine/strcpy_chk-64.ll
  test/Transforms/InstCombine/strlen-1.ll
  test/Transforms/InstCombine/wcslen-1.ll
  test/Transforms/InstCombine/wcslen-3.ll
  tools/clang/lib/CodeGen/CGCall.cpp
  tools/clang/test/CodeGenCXX/microsoft-abi-dynamic-cast.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D37628.114373.patch
Type: text/x-patch
Size: 30873 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170908/ad436afb/attachment.bin>


More information about the llvm-commits mailing list