[Bug middle-end/110379] Unnecessary copies after early opts

2023-06-27 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110379 --- Comment #3 from Jan Hubicka --- I thought that ADDR_EXPR of refenence is just fancy way to represent NOP_EXPR or POINTER_PLUS in today gimple. How that affects builtin_object_size? :) However I think ipa-sra will eventually need to handel a

[Bug middle-end/110379] Unnecessary copies after early opts

2023-06-23 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110379 --- Comment #2 from Andrew Pinski --- Plus this is basically the same as the following C code: ``` struct a { int t; }; void foo (struct a *); struct b { struct a f; }; void test(struct b *t) { foo(&t->f); } ```

[Bug middle-end/110379] Unnecessary copies after early opts

2023-06-23 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110379 --- Comment #1 from Andrew Pinski --- IIRC this is needed for __builtin_object_size still