[Bug c++/93557] __builtin_convertvector doesn't mark input as used
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93557 Jakub Jelinek changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED Target Milestone|--- |9.3 --- Comment #5 from Jakub Jelinek --- Fixed.
[Bug c++/93557] __builtin_convertvector doesn't mark input as used
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93557 --- Comment #4 from CVS Commits --- The releases/gcc-9 branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:520b364da0b20dcb492229757190cc3f30322052 commit r9-8219-g520b364da0b20dcb492229757190cc3f30322052 Author: Jakub Jelinek Date: Wed Feb 5 23:35:08 2020 +0100 c++: Mark __builtin_convertvector operand as read [PR93557] In C++ we weren't calling mark_exp_read on the __builtin_convertvector first argument. I guess it could misbehave even with lambda implicit captures. Fixed by calling decay_conversion on the argument, we use the argument as rvalue so we want the standard lvalue to rvalue conversions, but as the argument must be a vector type, e.g. integral promotions aren't really needed. 2020-02-05 Jakub Jelinek PR c++/93557 * semantics.c (cp_build_vec_convert): Call decay_conversion on arg prior to passing it to c_build_vec_convert. * c-c++-common/Wunused-var-17.c: New test.
[Bug c++/93557] __builtin_convertvector doesn't mark input as used
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93557 --- Comment #3 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:5a8ad97b6e4823d4ded00a3ce8d80e4bf93368d4 commit r10-6460-g5a8ad97b6e4823d4ded00a3ce8d80e4bf93368d4 Author: Jakub Jelinek Date: Wed Feb 5 23:35:08 2020 +0100 c++: Mark __builtin_convertvector operand as read [PR93557] In C++ we weren't calling mark_exp_read on the __builtin_convertvector first argument. I guess it could misbehave even with lambda implicit captures. Fixed by calling decay_conversion on the argument, we use the argument as rvalue so we want the standard lvalue to rvalue conversions, but as the argument must be a vector type, e.g. integral promotions aren't really needed. 2020-02-05 Jakub Jelinek PR c++/93557 * semantics.c (cp_build_vec_convert): Call decay_conversion on arg prior to passing it to c_build_vec_convert. * c-c++-common/Wunused-var-17.c: New test.
[Bug c++/93557] __builtin_convertvector doesn't mark input as used
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93557 --- Comment #2 from Jakub Jelinek --- Created attachment 47776 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=47776=edit gcc10-pr93557.patch Untested fix.
[Bug c++/93557] __builtin_convertvector doesn't mark input as used
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93557 Jakub Jelinek changed: What|Removed |Added Status|UNCONFIRMED |ASSIGNED Last reconfirmed||2020-02-03 CC||jakub at gcc dot gnu.org Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #1 from Jakub Jelinek --- I'll take this.