2011/4/27 Andrew Stubbs <andrew.stu...@linaro.org>: > On 27/04/11 09:44, Barry Song wrote: >> >> Thanks. I am totally thinking it is a gcc bug not an optimization >> feature. in fact, __aeabi_uldivmod is never called as seen by objdump. >> It only exists in symbol reference list. > > Your code contains "Nmod = target % source" so the only reason divmod > wouldn't get called is if it got optimized away somehow. > > If that were the case then it would be a compiler bug somehow, but when I > build the test case in Michael's bug report it looks like __aeabi_uidivmod > does get called, AFAICT. > > I don't see any reference to __aeabi_uldivmod so you must have different > compiler or testcase?
__aeabi_u*i*divmod does get called in asm codes. I mean __aeabi_u*l*divmod has never existed in asm codes after objdump the target ko. __aeabi_u*l*divmod only exists in refrence list. the list means what symbols are depent by this module. So we got a link error. but in fact, the module doesn't need link this symbol since it never call __aeabi_u*l*divmod in asm level. > > Andrew > _______________________________________________ linaro-toolchain mailing list linaro-toolchain@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-toolchain