[all-commits] [llvm/llvm-project] 64d5ae: [TableGen] Add log bang operator

Michael Maitland via All-commits all-commits at lists.llvm.org
Wed Oct 26 09:17:02 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 64d5aedd0637892c5b19c145f3cebf487510d9bf
      https://github.com/llvm/llvm-project/commit/64d5aedd0637892c5b19c145f3cebf487510d9bf
  Author: Michael Maitland <michaeltmaitland at gmail.com>
  Date:   2022-10-26 (Wed, 26 Oct 2022)

  Changed paths:
    M llvm/docs/TableGen/ProgRef.rst
    M llvm/include/llvm/TableGen/Record.h
    M llvm/lib/TableGen/Record.cpp
    M llvm/lib/TableGen/TGLexer.cpp
    M llvm/lib/TableGen/TGLexer.h
    M llvm/lib/TableGen/TGParser.cpp
    M llvm/test/TableGen/math.td

  Log Message:
  -----------
  [TableGen] Add log bang operator

This patch adds base 2 logarithm that returns integer result. I initially wanted to name it `!log2`,
but numbers are not permitted in the name. The documentation makes sure to clarify that it is
base 2 since it is not explicit in the operator name.

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




More information about the All-commits mailing list