[all-commits] [llvm/llvm-project] 434cf2: [Attributor] Check nonnull attribute violation in ...

Shinji Okumura via All-commits all-commits at lists.llvm.org
Mon Aug 3 01:13:20 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 434cf2ded3836075daa34bb4bd6286ff571d24e1
      https://github.com/llvm/llvm-project/commit/434cf2ded3836075daa34bb4bd6286ff571d24e1
  Author: Shinji Okumura <okuraofvegetable at gmail.com>
  Date:   2020-08-03 (Mon, 03 Aug 2020)

  Changed paths:
    M llvm/lib/Transforms/IPO/AttributorAttributes.cpp
    M llvm/test/Transforms/Attributor/undefined_behavior.ll

  Log Message:
  -----------
  [Attributor] Check nonnull attribute violation in AAUndefinedBehavior

This patch makes it possible to handle nonnull attribute violation at callsites in AAUndefinedBehavior.
If null pointer is passed to callee at a callsite and the corresponding argument of callee has nonnull attribute, the behavior of the callee is undefined.
In this patch, violations of argument nonnull attributes is only handled.
But violations of returned nonnull attributes can be handled and I will implement that in a follow-up patch.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D84733




More information about the All-commits mailing list