[all-commits] [llvm/llvm-project] 4aaa92: [llvm][CodeExtractor] fix bug in parameter naming ...
Tom Eccles via All-commits
all-commits at lists.llvm.org
Mon Nov 4 03:20:54 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 4aaa92578686176243a294eeb2ca5697a99edcaa
https://github.com/llvm/llvm-project/commit/4aaa92578686176243a294eeb2ca5697a99edcaa
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-11-04 (Mon, 04 Nov 2024)
Changed paths:
M llvm/lib/Transforms/Utils/CodeExtractor.cpp
M llvm/unittests/Transforms/Utils/CodeExtractorTest.cpp
Log Message:
-----------
[llvm][CodeExtractor] fix bug in parameter naming (#114237)
The code extractor tries to apply the names of source input and output
values to function arguments. Not all input and output values get added
as arguments: some are instead placed inside of a struct passed to the
function. The existing renaming code skipped trying to set these
struct-packed arguments names (as there is no corresponding function
argument to rename), but it still incremented the iterator over the
function arguments. This could result in dereferencing an end iterator
if struct-packed inputs/outputs preceded non-struct-packed
inputs/outputs.
This patch rewrites this loop to avoid the end iterator dereference.
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