This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Agreed.Now, if I read 6.7.3 (7) correct, the second output is correct for the first case, too. And in fact, the Intel compiler produces the optimized output in _both_ cases.
Is GCC right in not doing the optimization in the first case,No.
or has it just missed the optimization opportunity?Just missed it.
[#3] In what follows, a pointer expression E is said to be based on object P if (at some sequence point in the execution of B prior to the evaluation of E) modifying P to point to a copy of the array object into which it formerly pointed would change the value of E.106) Note that | ``based'' is defined only for expressions with pointer types.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |