[all-commits] [llvm/llvm-project] 213124: [LLVM][MemCpyOpt] Unify alias tags if we optimize ...
Dominik Adamski via All-commits
all-commits at lists.llvm.org
Tue Apr 15 13:18:47 PDT 2025
Branch: refs/heads/release/20.x
Home: https://github.com/llvm/llvm-project
Commit: 2131242240f71926e45e58ad6ec66aced4756e48
https://github.com/llvm/llvm-project/commit/2131242240f71926e45e58ad6ec66aced4756e48
Author: Dominik Adamski <dominik.adamski at amd.com>
Date: 2025-04-15 (Tue, 15 Apr 2025)
Changed paths:
M llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
A llvm/test/Transforms/MemCpyOpt/memcpy-tbaa.ll
M llvm/test/Transforms/MemCpyOpt/stack-move.ll
Log Message:
-----------
[LLVM][MemCpyOpt] Unify alias tags if we optimize allocas (#129537)
Optimization of alloca instructions may lead to invalid alias tags.
Incorrect alias tags can result in incorrect optimization outcomes for
Fortran source code compiled by Flang with flags: `-O3 -mmlir
-local-alloc-tbaa -flto`.
This commit removes alias tags when memcpy optimization replaces two
arrays with one array, thus ensuring correct compilation of Fortran
source code using flags: `-O3 -mmlir -local-alloc-tbaa -flto`.
This commit is also a proposal to fix the reported issue:
https://github.com/llvm/llvm-project/issues/133984
---------
Co-authored-by: Shilei Tian <i at tianshilei.me>
(cherry picked from commit 716b02d8c575afde7af1af13df145019659abca2)
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