Thanks for splitting this out XiangLing.
Comment explaining why we need to emit the extra error in this case for AIX.
I would rearrange the order of the conditions so that we first check if we are on AIX for the short-circuiting.
Maybe Value.ugt(32) instead of (unsigned)Value.getZExtValue() > 32
I believe this is running the test twice as C++/
As we discussed offline, the strategy to handle long long type bitfield under 32bit mode would be the bitcontainer shall be 32-bits unless if a single long long bitfield has length greater than 32 bits (what would have been a diagnostic in xlc/xlclang/xlclang++), then the bitcontainer shall be 64-bits.