[PATCH] D81269: Fix null pointer dereference in `ProfileSummaryInfo::getPSI()`

Vedant Kumar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 8 10:30:24 PDT 2020


vsk added a comment.

@fez thanks for explaining. Changing the library to initialize passes properly seems like the way to go, otherwise we'd be advertising that the pass initialization API is in general optional to call (which it's not). Re: chasing down the UB, I realize that's not a great experience, but istm the way to fix that is to modernize getPSI usage to expect a reference and test with -fsanitize=null to qualify the change.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D81269





More information about the llvm-commits mailing list