Hi i found IVOPTS didn't work well on some case if the loop contain some unaligned access. it didn't take this kind of memory access into account because this check in function:find_interesting_uses_address
/* Moreover, on strict alignment platforms, check that it is sufficiently aligned. */ if (STRICT_ALIGNMENT && may_be_unaligned_p (base, step)) goto fail; and this is used to fix http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17949 because it converting byte loads into a unaligned word load on strict alignment platform. but there are some platform which is strict alignment and it also support unaligned access for special mode. for example, ARM NEON support vector mode unaligned access via VLD1/VST1, and they both support write back address mode. Moreover, lately ARM add unaligned access support for all ARMv6 , ARMv7-A, ARMv7-R, and ARMv7-M architecture-based processors which controlled by the option: munaligned-access. see http://gcc.gnu.org/ml/gcc-patches/2011-05/msg00513.html. so what should we do now? should we use target hook to check this or something else? -- Yuehai Du