[all-commits] [llvm/llvm-project] 0e7c77: Introduce a "gc-live" bundle for the gc arguments ...

Philip Reames via All-commits all-commits at lists.llvm.org
Wed Jun 3 15:00:48 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 0e7c77053f560d391fecbec5d5e0e42082865c8a
      https://github.com/llvm/llvm-project/commit/0e7c77053f560d391fecbec5d5e0e42082865c8a
  Author: Philip Reames <listmail at philipreames.com>
  Date:   2020-06-03 (Wed, 03 Jun 2020)

  Changed paths:
    M llvm/docs/LangRef.rst
    M llvm/docs/Statepoints.rst
    M llvm/include/llvm/IR/LLVMContext.h
    M llvm/include/llvm/IR/Statepoint.h
    M llvm/lib/IR/LLVMContext.cpp
    M llvm/lib/IR/Verifier.cpp
    M llvm/test/Bitcode/operand-bundles-bc-analyzer.ll
    A llvm/test/CodeGen/X86/statepoint-gc-live.ll

  Log Message:
  -----------
  Introduce a "gc-live" bundle for the gc arguments of a statepoint

Currently, gc.relocates are defined in terms of indices into the statepoint's operand list. Given the gc args are at the end of a variable length list of operands, this makes interpreting their indices by hand a tad challenging. We can simplify the statepoint sequence and improve readability quite a bit by pulling these new operands into their own named operand bundle.

This patch defines a new operand bundle tag "gc-live". The semantics of the bundle are the same as the existing gc arguments of a statepoint. This patch simply introduces the definition and codegen for the bundle, future patches will migrate RS4GC to emitting the new form.

Interestingly, with this done and the recent migration to using deopt and gc-transition bundles, we really don't have much left in the statepoint itself. It really looks like the existing ID and flags fields are redundant; we have (existing!) attributes for all of them. I think we'll be able to reduce the gc.statepoint signature to simply a wrapped call (e.g. actual target and actual arguments).

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




More information about the All-commits mailing list