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]

Re: Need advice with store_bit_field and its call chain


Zack Weinberg wrote:
I have not unsnarled the third clause, but it doesn't matter, because the second one is the problem. The
bitsize is 128, but GET_MODE_BITSIZE (XFmode) is 96
(really should be 80, but that breaks too much other
stuff). The bitsize is coming from store_constructor:

The problem arises because we have GET_MODE_SIZE (XFmode) == 16, and GET_MODE_BITSIZE (XFmode) == 96, and thus the byte size is not bitsize * BITS_PER_UNIT. So I think you should test for that.


Perhaps
  && (bitsize == GET_MODE_BITSIZE (fieldmode)
      || bitsize == GET_MODE_SIZE (fieldmode) * BITS_PER_UNIT)

This would deserve a comment, as anyone looking at this is going to be very confused about why we need both tests, when they are obviously the same test.

Or maybe we only need the GET_MODE_SIZE test, because that one is always be the correct test?
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]