On 02/03/14 05:41, Kugan wrote:
With the 2013-09-21 version of trunk, attached test case results in bus
error when simultaneously enabling both -mno-unaligned-access and
-ftree-vectorize.
The error is caused by unaligned vector load via two vldr instructions:

  vldr d16, [r3, #-16]
  vldr d17, [r3, #-8]


So, does this mean that we get unaligned vector loads when munaligned-access is on, using vldr instructions ? This worries me because we shouldn't be putting out vldr's. I was hoping to have dug a bit further today but don't think I will make much more progress. Can you dig a bit further to make sure that this is only code path that triggers this ?


Cause for this error is, even when -mno-unaligned-access is enabled,
backend will inform vectorizer that it supports misaligned accesses
via TARGET_VECTORIZE_SUPPORT_VECTOR_MISALIGNMENT.

Attached patch fixes this. Is this OK for trunk?

How has it been tested ?


Ramana


Thanks,
Kugan

+2014-02-03  Yury Gribov  <tetra2...@gmail.com>
+            Kugan Vivekanandarajah  <kug...@linaro.org>
+
+       * config/arm/arm.c (arm_vector_alignment_reachable): Check
+       unaligned_access.
+       * config/arm/arm.c (arm_builtin_support_vector_misalignment): Likewise.
+



+2014-02-03  Yury Gribov  <tetra2...@gmail.com>
+            Kugan Vivekanandarajah  <kug...@linaro.org>
+
+       * gcc.target/arm/vect-noalign.c: New file.
+



--
Ramana Radhakrishnan
Principal Engineer
ARM Ltd.

Reply via email to