[all-commits] [llvm/llvm-project] 939117: [Assignment Tracking] Check getTypeSizeInBits resu...
Orlando Cazalet-Hyams via All-commits
all-commits at lists.llvm.org
Fri Apr 28 01:12:08 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9391177cbcb0e5fb051f7a867683d7a0817f1648
https://github.com/llvm/llvm-project/commit/9391177cbcb0e5fb051f7a867683d7a0817f1648
Author: OCHyams <orlando.hyams at sony.com>
Date: 2023-04-28 (Fri, 28 Apr 2023)
Changed paths:
M llvm/lib/IR/DebugInfo.cpp
A llvm/test/DebugInfo/assignment-tracking/AArch64/lit.local.cfg
A llvm/test/DebugInfo/assignment-tracking/AArch64/scalable-vectors.ll
Log Message:
-----------
[Assignment Tracking] Check getTypeSizeInBits result for scalable vector types
Without this patch, in `getAssignmentInfo` the result of `getTypeSizeInBits` is
cast to `uint64_t`, which a) is an operation that will eventually be
unsupported by the API according to the comments, and b) causes an assertion
failure if the type is a scalable vector. Don't cast the `TypeSize` to
`uint64_t` and check `isScalable` before getting the fixed size.
This can result in incorrect variable locations, see llvm.org/PR62346 (but is
better than crashing).
Reviewed By: paulwalker-arm
Differential Revision: https://reviews.llvm.org/D149137
More information about the All-commits
mailing list