[Bug middle-end/71700] [5 Regression] wrong code with struct assignment with sub-word signed bitfields
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71700 ktkachov at gcc dot gnu.org changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #7 from ktkachov at gcc dot gnu.org --- Fixed for 5.5, 6.3, 7.0
[Bug middle-end/71700] [5 Regression] wrong code with struct assignment with sub-word signed bitfields
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71700 --- Comment #6 from ktkachov at gcc dot gnu.org --- Author: ktkachov Date: Thu Aug 25 09:26:15 2016 New Revision: 239754 URL: https://gcc.gnu.org/viewcvs?rev=239754&root=gcc&view=rev Log: [expr.c] PR middle-end/71700: zero-extend sub-word value when widening constructor element Backport from mainline 2016-07-12 Kyrylo Tkachov PR middle-end/71700 * expr.c (store_constructor): Mask sign-extended bits when widening sub-word constructor element at the start of a word. * gcc.c-torture/execute/pr71700.c: New test. Added: branches/gcc-5-branch/gcc/testsuite/gcc.c-torture/execute/pr71700.c Modified: branches/gcc-5-branch/gcc/ChangeLog branches/gcc-5-branch/gcc/expr.c branches/gcc-5-branch/gcc/testsuite/ChangeLog