[all-commits] [llvm/llvm-project] 0fcc3d: [flang] - Call _FortranAAssignSimple instead of _F...

Pranav Bhandarkar via All-commits all-commits at lists.llvm.org
Wed Aug 5 20:38:38 PDT 2026


  Branch: refs/heads/users/bhandarkar-pranav/issue_203915_ph2_pr2
  Home:   https://github.com/llvm/llvm-project
  Commit: 0fcc3df1c5cb8184436ad0fb53b194c37352552e
      https://github.com/llvm/llvm-project/commit/0fcc3df1c5cb8184436ad0fb53b194c37352552e
  Author: Pranav Bhandarkar <pranav.bhandarkar at amd.com>
  Date:   2026-08-05 (Wed, 05 Aug 2026)

  Changed paths:
    M flang/include/flang/Optimizer/Builder/Runtime/Assign.h
    M flang/lib/Optimizer/Builder/Runtime/Assign.cpp
    M flang/lib/Optimizer/HLFIR/Transforms/ConvertToFIR.cpp
    M flang/lib/Optimizer/OpenMP/LowerWorkdistribute.cpp
    M flang/test/HLFIR/assign-codegen.fir
    A flang/test/HLFIR/assign-simple-routing.fir
    M flang/test/HLFIR/fir-local-alloca-block.fir
    M flang/test/Lower/OpenMP/workdistribute-saxpy-and-scalar-assign.f90

  Log Message:
  -----------
  [flang] - Call _FortranAAssignSimple instead of _FortranAAssign for intrinsic-type array assignments.

This patch adds support for calling _FortranAAssignSimple, a faster-path for array assignments.
`_FortranAAssignSimple` is called when ALL the following conditions are true:
1. Intrinsic element type (not derived type)
2. Matching ranks (no scalar-to-array broadcasting)
3. Non-volatile
4. Not polymorphic
5. Not explicit-length character
6. Not temporary LHS

Otherwise, uses `_FortranAAssign` (or specialized variants like `_FortranAAssignPolymorphic`, `_FortranAAssignExplicitLengthCharacter`).

This is a (perhaps final) part of the fix for https://github.com/llvm/llvm-project/issues/203915



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