This is an archive of the discontinued LLVM Phabricator instance.

Regression test for simple devirtualization (microsoft abi)
AbandonedPublic

Authored by andrew.zhogin on Jul 17 2015, 3:52 PM.

Details

Reviewers
majnemer
Summary

Clang generates aliases for vtable access getelementptr (microsoft ABI only). It breaks devirtualization due to constprop failing on GlobalAlias. Here is simple test aka "return ptr->f() + ptr->f_const()".

Linked with:
llvm patch for aliases constprop

Diff Detail

Event Timeline

andrew.zhogin retitled this revision from to Regression test for simple devirtualization (microsoft abi).
andrew.zhogin updated this object.
andrew.zhogin added a reviewer: majnemer.
andrew.zhogin added subscribers: zinovy.nis, cfe-commits.
asl added a subscriber: asl.Jul 17 2015, 4:03 PM

Added "// REQUIRES: x86-registered-target"

majnemer edited edge metadata.Jul 17 2015, 4:22 PM

The "test/Analysis" directory is used for tests targeting the static analyzer. That being said, I don't think we should have this test in clang. In general, it is not considered desirable to have a test in clang which exercises the optimizer. I think the test case included in D11306 is sufficient.

andrew.zhogin abandoned this revision.Jul 21 2015, 12:41 PM

Cancelled as unnecessary.