diff options
author | Slava Zakharin <szakharin@nvidia.com> | 2024-08-01 09:39:25 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-01 09:39:25 -0700 |
commit | 2177a1767b88d684830b83ac7f06d0f9f15102e2 (patch) | |
tree | bcaf723f89ce30d583483aefde061dd31187a867 /llvm/lib/Object/MachOObjectFile.cpp | |
parent | 98e4413a38f286147b863a6ead9625228ab0ec7d (diff) | |
download | llvm-2177a1767b88d684830b83ac7f06d0f9f15102e2.zip llvm-2177a1767b88d684830b83ac7f06d0f9f15102e2.tar.gz llvm-2177a1767b88d684830b83ac7f06d0f9f15102e2.tar.bz2 |
[flang][runtime] Avoid call recursion in CopyElement runtime. (#101421)
Device compilers may fail to identify maximum stack size required
by a kernel that calls CopyElement due to potential recursive calls.
To avoid this, we can use dynamically allocated Stack. To avoid
dynamic allocations on the host for simple cases, the Stack
implementation
has a reserved space (that ends up being allocated on the program
stack).
I tested both pre-allocated and 0-reserve implementations on the host,
and all passed. The actual reserve values might be tuned as needed.
Diffstat (limited to 'llvm/lib/Object/MachOObjectFile.cpp')
0 files changed, 0 insertions, 0 deletions