aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineFunction.cpp
diff options
context:
space:
mode:
authoreahcmrh <chris.hamilton@ericsson.com>2021-06-08 19:00:42 +0200
committereahcmrh <chris.hamilton@ericsson.com>2021-06-11 19:34:03 +0200
commitce44fe199bbfd4b5a44764b678c431fdc117116a (patch)
treea0a614d0549dec4aa4a3f8a29dbc81558b5d2196 /llvm/lib/CodeGen/MachineFunction.cpp
parentfdc0d4360b4e072bd91cdf9133fdf570d8fb16a2 (diff)
downloadllvm-ce44fe199bbfd4b5a44764b678c431fdc117116a.zip
llvm-ce44fe199bbfd4b5a44764b678c431fdc117116a.tar.gz
llvm-ce44fe199bbfd4b5a44764b678c431fdc117116a.tar.bz2
[Sema] Address-space sensitive check for unbounded arrays (v2)
Check applied to unbounded (incomplete) arrays and pointers to spot cases where the computed address is beyond the largest possible addressable extent of the array, based on the address space in which the array is delcared, or which the pointer refers to. Check helps to avoid cases of nonsense pointer math and array indexing which could lead to linker failures or runtime exceptions. Of particular interest when building for embedded systems with small address spaces. This is version 2 of this patch -- version 1 had some testing issues due to a sign error in existing code. That error is corrected and lit test for this chagne is extended to verify the fix. Originally reviewed/accepted by: aaron.ballman Original revision: https://reviews.llvm.org/D86796 Reviewed By: aaron.ballman, ebevhan Differential Revision: https://reviews.llvm.org/D88174
Diffstat (limited to 'llvm/lib/CodeGen/MachineFunction.cpp')
0 files changed, 0 insertions, 0 deletions