[all-commits] [llvm/llvm-project] 8c3b6b: [flang][cuda] Do not lower device variables in mai...

Valentin Clement (バレンタイン クレメン) via All-commits all-commits at lists.llvm.org
Thu Aug 8 13:13:21 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8c3b6bd0cb04a6edc3b294f9048cbfb1ea6c200c
      https://github.com/llvm/llvm-project/commit/8c3b6bd0cb04a6edc3b294f9048cbfb1ea6c200c
  Author: Valentin Clement (バレンタイン クレメン) <clementval at gmail.com>
  Date:   2024-08-08 (Thu, 08 Aug 2024)

  Changed paths:
    M flang/include/flang/Evaluate/tools.h
    M flang/lib/Evaluate/tools.cpp
    M flang/test/Lower/CUDA/cuda-program-global.cuf

  Log Message:
  -----------
  [flang][cuda] Do not lower device variables in main program as globals (#102512)

Flang considers arrays in main program larger than 32 bytes having the
SAVE attribute and lowers them as globals. In CUDA Fortran, device
variables are not allowed to have the SAVE attribute and should be
allocated dynamically in the main program scope.
This patch updates lowering so CUDA Fortran device variables are not
considered with the SAVE attribute.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list