[all-commits] [llvm/llvm-project] c30d77: [OpenMP] Change debugging symbol to weak_odr linkage

Joseph Huber via All-commits all-commits at lists.llvm.org
Fri Sep 17 18:26:04 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c30d7730ebde18d61b33ae1de9ded69dac6ea6be
      https://github.com/llvm/llvm-project/commit/c30d7730ebde18d61b33ae1de9ded69dac6ea6be
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2021-09-17 (Fri, 17 Sep 2021)

  Changed paths:
    M clang/test/OpenMP/target_debug_codegen.cpp
    M llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp

  Log Message:
  -----------
  [OpenMP] Change debugging symbol to weak_odr linkage

The new device runtime uses an internal variable to set debugging. This
variable was originally privately linked because every module will have
a copy of it. This caused problems with merging the device bitcode
library because it would get renamed and there was not a way to refer to
an external, private symbol. This changes the symbol to weak_odr so it
can be defined multiply, but will not be renamed.

Reviewed By: jdoerfert

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


  Commit: b266bcb13557f6a9fcf58a2d2be271a631aee72f
      https://github.com/llvm/llvm-project/commit/b266bcb13557f6a9fcf58a2d2be271a631aee72f
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2021-09-17 (Fri, 17 Sep 2021)

  Changed paths:
    M openmp/libomptarget/DeviceRTL/include/Debug.h
    M openmp/libomptarget/DeviceRTL/src/Debug.cpp

  Log Message:
  -----------
  [OpenMP] Implement __assert_fail in the new device runtime

This patch implements the `__assert_fail` function in the new device
runtime. This allows users and developers to use the standars assert
function inside of the device.

Reviewed By: tianshilei1992

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


  Commit: ec02c34b6df1efc643e5889bf3f181d55c4fed38
      https://github.com/llvm/llvm-project/commit/ec02c34b6df1efc643e5889bf3f181d55c4fed38
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2021-09-17 (Fri, 17 Sep 2021)

  Changed paths:
    M openmp/libomptarget/DeviceRTL/include/Configuration.h
    M openmp/libomptarget/DeviceRTL/src/Configuration.cpp
    M openmp/libomptarget/deviceRTLs/common/device_environment.h
    M openmp/libomptarget/plugins/cuda/src/rtl.cpp

  Log Message:
  -----------
  [OpenMP] Add additional fields to device environment

This patch adds fields for the device number and number of devices into
the device environment struct and debugging values.

Reviewed By: jdoerfert

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


  Commit: f1c821fa850b5168e0cc120f2497ac54d8ad325b
      https://github.com/llvm/llvm-project/commit/f1c821fa850b5168e0cc120f2497ac54d8ad325b
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2021-09-17 (Fri, 17 Sep 2021)

  Changed paths:
    M openmp/docs/design/Runtimes.rst
    M openmp/libomptarget/DeviceRTL/include/Configuration.h
    M openmp/libomptarget/DeviceRTL/include/Interface.h
    M openmp/libomptarget/DeviceRTL/include/State.h
    M openmp/libomptarget/DeviceRTL/src/Configuration.cpp
    M openmp/libomptarget/DeviceRTL/src/State.cpp
    M openmp/libomptarget/plugins/cuda/src/rtl.cpp
    A openmp/libomptarget/test/api/omp_dynamic_shared_memory.c

  Log Message:
  -----------
  [OpenMP] Add support for dynamic shared memory in new RTL

This patch adds support for using dynamic shared memory in the new
device runtime. The new function `__kmpc_get_dynamic_shared` will return a
pointer to the buffer of dynamic shared memory. Currently the amount of memory
allocated is set by an environment variable.

In the future this amount will be added to the amount used for the smart stack
which will be configured in a similar way.

Reviewed By: tianshilei1992

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


Compare: https://github.com/llvm/llvm-project/compare/724a1dff8a8e...f1c821fa850b


More information about the All-commits mailing list