This is an archive of the discontinued LLVM Phabricator instance.

fix test failure for clang/test/CodeGen/builtin-expect-with-probability.cpp
ClosedPublic

Authored by LukeZhuang on Jun 23 2020, 12:35 PM.

Details

Summary

Fix test case added by D79830
Rewrite the test case, which did similar thing as builtin-expect.c does(test generated llvm intrinsic instead of test branch weights).
Currently pass by "-disable-llvm-passes" option.

Diff Detail

Event Timeline

LukeZhuang created this revision.Jun 23 2020, 12:35 PM
LukeZhuang edited the summary of this revision. (Show Details)Jun 23 2020, 12:38 PM
erichkeane accepted this revision.Jun 23 2020, 12:58 PM

1 suggestion to the test, but otherwise looks OK. Let me know if you'd like this committed for you.

clang/test/CodeGen/builtin-expect-with-probability.cpp
48

You might consider making this 'extern C' so that you can do a more exact check on line 53.

This revision is now accepted and ready to land.Jun 23 2020, 12:58 PM

Fixed. If it looks good to you, could you please help me commit it? Thank you very much!

This revision was automatically updated to reflect the committed changes.