Ensure non-null ProfileSummaryInfo passed to ModuleSummaryIndex builder

Description

Ensure non-null ProfileSummaryInfo passed to ModuleSummaryIndex builder

This fixes a ubsan bot failure after r302597, which made getProfileCount
non-static, but ended up invoking it on a null ProfileSummaryInfo object
in some cases from buildModuleSummaryIndex.

Most testing passed because the non-static getProfileCount currently
doesn't access any member variables, but I found this when testing a
follow on patch (D32877) that adds a member variable access.

Details

Committed
tejohnsonMay 10 2017, 11:52 AM
Parents
rL302704: [APInt] Make toString use udivrem instead of calling the divide helper method…
Branches
Unknown
Tags
Unknown