[all-commits] [llvm/llvm-project] 95b981: [CodeExtractor] Enable partial aggregate arguments

Giorgis Georgakoudis via All-commits all-commits at lists.llvm.org
Tue Jan 25 18:25:06 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 95b981ca2ae3915464a63d42eb53b0dde4a88227
      https://github.com/llvm/llvm-project/commit/95b981ca2ae3915464a63d42eb53b0dde4a88227
  Author: Giorgis Georgakoudis <georgakoudis1 at llnl.gov>
  Date:   2022-01-25 (Tue, 25 Jan 2022)

  Changed paths:
    M llvm/include/llvm/Transforms/Utils/CodeExtractor.h
    M llvm/lib/Transforms/Utils/CodeExtractor.cpp
    M llvm/unittests/Transforms/Utils/CodeExtractorTest.cpp

  Log Message:
  -----------
  [CodeExtractor] Enable partial aggregate arguments

Summary:
Enable CodeExtractor to construct output functions that partially
aggregate inputs/outputs in their argument list. A use case is the
OMPIRBuilder to create outlined functions for parallel regions that
aggregate in a struct the payload variables for the region while passing
as scalars thread and bound identifiers.

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


  Commit: 7cb4c2617391b80993e7c10f3a34c9e172f7ad41
      https://github.com/llvm/llvm-project/commit/7cb4c2617391b80993e7c10f3a34c9e172f7ad41
  Author: Giorgis Georgakoudis <georgakoudis1 at llnl.gov>
  Date:   2022-01-25 (Tue, 25 Jan 2022)

  Changed paths:
    M clang/test/OpenMP/cancel_codegen.cpp
    M clang/test/OpenMP/irbuilder_nested_openmp_parallel_empty.c
    M clang/test/OpenMP/irbuilder_nested_parallel_for.c
    M clang/test/OpenMP/parallel_codegen.cpp
    M llvm/include/llvm/Frontend/OpenMP/OMPIRBuilder.h
    M llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
    M llvm/lib/Transforms/IPO/OpenMPOpt.cpp
    M llvm/test/Transforms/OpenMP/parallel_region_merging.ll
    M llvm/unittests/Frontend/OpenMPIRBuilderTest.cpp

  Log Message:
  -----------
  [OMPIRBuilder] Generate aggregate argument for parallel region outlined functions

Summary:
This patch modifies code generation in OpenMPIRBuilder to pass arguments
to the parallel region outlined function in an aggregate (struct),
besides the global_tid and bound_tid arguments. It depends on the
updated CodeExtractor (see D96854) for support. It mirrors functionality
of Clang codegen (see D102107).

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


Compare: https://github.com/llvm/llvm-project/compare/510710d03749...7cb4c2617391


More information about the All-commits mailing list