This is a "slight" update from the last revision, with your issues addressed as I explained in the last email. However, everything turned out to be much tricker than I expected (variable length offsets with arrays, bit fields spanning multiple words, surprising padding gymnastics by GCC, etc etc). It turns out that what we need is to know the precise bit region size at all times, and adjust it as we rearrange and cut things into pieces throughout the RTL bit field machinery. I enabled the C++ memory model, and forced a boostrap and regression test with it. This brought about many interesting cases, which I was able to distill and add to the testsuite. Of particular interest was the struct-layout-1.exp tests. Since many of the tests set a global bit field, only to later check it against a local variable containing the same value, it is the perfect stressor because, while globals are restricted under the memory model, locals are not. So we can check that we can interoperate with the less restrictive model, and that the patch does not introduce ABI inconsistencies. After much grief, we are now passing all the struct-layout-1.exp tests. Eventually, I'd like to force the struct-layout-1.exp tests to run for "--param allow-store-data-races=0" as well. Unfortunately, this will increase testing time. I have (unfortunately) introduced an additional call to get_inner_reference(), but only for the field itself (one time). I can't remember the details, but it was something to effect of the bit position + padding being impossible to calculate in one variable array reference case. I can dig up the case if you'd like. I am currently tackling a reload miscompilation failure while building a 32-bit library. I am secretly hoping your review will uncover the flaw without me having to pick this up. Otherwise, this is a much more comprehensive approach than what is currently in mainline, and we now pass all the bitfield tests the GCC testsuite could throw at it. Fire away.