[PATCH] Teach the analyzer about multi-dimensional VLAs

Daniel Fahlgren daniel at fahlgren.se
Thu Sep 4 07:21:18 PDT 2014


Hi,

This patch handles the fixme about multi-dimensional VLAs in
VLASizeChecker. I tried to keep the changeset as small as possible by
cutting the checkPreStmt method into two parts. The checker first
iterates over all dimensions and reports if a bug is found. It later
iterates again, calculating the size. By scanning the dimensions twice
it can report bugs even if an unknown size is found.

Feedback and comments are, as always, welcome.

Best regards,
Daniel Fahlgren
-------------- next part --------------
A non-text attachment was scrubbed...
Name: multi_dimensional_vla.patch
Type: text/x-patch
Size: 8550 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140904/d3a41f7c/attachment.bin>


More information about the cfe-commits mailing list