[all-commits] [llvm/llvm-project] e77221: [llvm] Make Sequence reverse-iterable

Guillaume Chatelet via All-commits all-commits at lists.llvm.org
Tue Jun 8 06:19:26 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e772216e708937988c039420d2c559568f91ae27
      https://github.com/llvm/llvm-project/commit/e772216e708937988c039420d2c559568f91ae27
  Author: Guillaume Chatelet <gchatelet at google.com>
  Date:   2021-06-08 (Tue, 08 Jun 2021)

  Changed paths:
    M llvm/include/llvm/ADT/Sequence.h
    M llvm/unittests/ADT/SequenceTest.cpp
    M mlir/include/mlir/IR/BuiltinAttributes.td
    M mlir/lib/Conversion/PDLToPDLInterp/PDLToPDLInterp.cpp
    M mlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp

  Log Message:
  -----------
  [llvm] Make Sequence reverse-iterable

This patch simplifies the implementation of Sequence and makes it compatible with llvm::reverse.
It exposes the reverse iterators through rbegin/rend which prevents a dangling reference in std::reverse_iterator::operator++().

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




More information about the All-commits mailing list