Hi,
as of last Friday, the default compiler on android is now clang (
https://crbug.com/481675). The change is still in, and by now it looks like it will stick.
I believe Android was the last platform using gcc. Now that the Android bots no longer use gcc, I believe we have no CQ bots that use gcc. We still support patches for gcc compat from the community, but it's possible building with gcc will now require more community maintenance than before.
If you don't work on Android, this shouldn't affect you and you can stop reading now.
If you do work on Android, it shouldn't affect you much either. One thing that I've seen is that clang produces code that makes more alignment assumptions: ARM processors raise SIGBUS if you e.g. try to read a 4-byte int off an unaligned address, and clang seems to emit these aligned read isntructions more frequently. For example, if you have this function:
uint32_t GetHeaderValue(void* data, int offset) const {
uint32_t value = *reinterpret_cast<uint32_t*>(data + offset)
return value;
}
then this will in general read 4 bytes off an unaligned address (unless data + offset happens to be divisible by 4). The fix is to do bytewise loads (or use base's bit_cast):
uint32_t GetHeaderValue(int offset) const {
uint32_t value;
memcpy(&value, data_ + offset, sizeof(value));
return value;
}
Nico