------- Comment #13 from ian at airs dot com 2008-01-18 16:01 ------- I think you're right. If the call to placement new is not inlined, and if we don't know anything special about it (which we currently don't), then it seems to me that everything is bound to work OK. It is only the inlining that makes a difference.
Pity we didn't realize that before. Still, the heart of CHANGE_DYNAMIC_TYPE_EXPR is compute_tbaa_pruning, and that will remain. What can be removed is the code in cp/init.c which creates CHANGE_DYNAMIC_TYPE_EXPR and the code in find_func_aliases which sets the no_tbaa_pruning flag. I have a vague memory that there was some weird test case in PR 29286 which we would need to reconsider. But I couldn't find it in a quick look, and I'm not sure my memory is correct. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33407