Hi While compiling 5.x I am getting stuck at uboot
>>>>>>>>>> part_efi.c: In function 'gpt_fill_pte': part_efi.c:433:38: error: iteration 32u invokes undefined behavior [-Werror=aggressive-loop-optimizations] (efi_char16_t)(partitions[i].name[k]); ^ part_efi.c:431:3: note: containing loop for (k = 0; k < name_len; k++) ^ cc1: all warnings being treated as errors >>>>>>>>>>> the gcc is from the actual toolchain i486-unknown-linux-uclibc-gcc (GCC) 4.8.2 the code looks like >>>>>>>>>>> /* partition attributes */ memset(&gpt_e[i].attributes, 0, sizeof(gpt_entry_attributes)); /* partition name */ name_len = sizeof(gpt_e[i].partition_name) / sizeof(efi_char16_t); for (k = 0; k < name_len; k++) gpt_e[i].partition_name[k] = (efi_char16_t)(partitions[i].name[k]); >>>>>>>>>>>> I suspect the name_len to be the culprit, because >>>>> name_len = sizeof(gpt_e[i].partition_name) / sizeof(efi_char16_t); 98 typedef struct _gpt_entry { 99 efi_guid_t partition_type_guid; 100 efi_guid_t unique_partition_guid; 101 __le64 starting_lba; 102 __le64 ending_lba; 103 gpt_entry_attributes attributes; 104 efi_char16_t partition_name[72 / sizeof (efi_char16_t)]; 105 } __attribute__ ((packed)) gpt_entry; >>>>> partition name is of type efi_char16_t, so name_len will always be 1 Is it possible that the compiler gets confused when trying to optimize this loop? Any ideas how to tackle this? Thanks Erich
smime.p7s
Description: S/MIME Cryptographic Signature
------------------------------------------------------------------------------ Android apps run on BlackBerry 10 Introducing the new BlackBerry 10.2.1 Runtime for Android apps. Now with support for Jelly Bean, Bluetooth, Mapview and more. Get your Android app in front of a whole new audience. Start now. http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
_______________________________________________ leaf-devel mailing list leaf-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/leaf-devel