[PATCH] D73898: [analyzer] StdLibraryFunctionsChecker: Add argument constraints

Balázs Kéri via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 14 08:14:18 PST 2020


balazske added a comment.

Probably a better solution can be:
For every "case" build a single `SVal` that contains all argument constraints for that case. It is possible using multiple `evalBinOp` calls (with <=, >=, logical or) to build such a condition (or repeated calls to other assume functions to cut off outer ranges). If the condition can be satisfied (by assume) add the new state, the condition for return value can be added here too. Repeat this for every different case. If no applicable case is found none of the conditions can be assumed, this means argument constraint error.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73898/new/

https://reviews.llvm.org/D73898





More information about the cfe-commits mailing list