[all-commits] [llvm/llvm-project] 3c5476: [funcattrs] Consistently check call site attributes

Philip Reames via All-commits all-commits at lists.llvm.org
Mon Apr 19 13:21:17 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3c54762226ed9bcb84dfdef9f8e6e6a2c6a971a0
      https://github.com/llvm/llvm-project/commit/3c54762226ed9bcb84dfdef9f8e6e6a2c6a971a0
  Author: Philip Reames <listmail at philipreames.com>
  Date:   2021-04-19 (Mon, 19 Apr 2021)

  Changed paths:
    M llvm/lib/Transforms/IPO/FunctionAttrs.cpp
    M llvm/test/Transforms/FunctionAttrs/noreturn.ll
    M llvm/test/Transforms/FunctionAttrs/willreturn-callsites.ll

  Log Message:
  -----------
  [funcattrs] Consistently check call site attributes

This is mostly stylistic cleanup after D100226, but not entirely. When skimming the code, I found one case where we weren't accounting for attributes on the callsite at all. I'm also suspicious we had some latent bugs related to operand bundles (which are supposed to be able to *override* attributes on declarations), but I don't have concrete test cases for those, just suspicions.

Aside: The only case left in the file which directly checks attributes on the declaration is the norecurse logic. I left that because I didn't understand it; it looks obviously wrong, so I suspect I'm misinterpreting the intended semantics of the attribute.

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




More information about the All-commits mailing list