strace: Please don't do unaligned access in the testsuite on ARM

Dmitry V. Levin ldv at altlinux.org
Thu Jul 13 22:44:31 UTC 2017


Hi Steve,

On Thu, Jun 15, 2017 at 10:01:55PM -0700, Steve Langasek wrote:
> Package: strace
> Version: 4.15-2
> Severity: normal
> Tags: patch
> User: ubuntu-devel at lists.ubuntu.com
> Usertags: origin-ubuntu artful ubuntu-patch
> 
> Hi Steve,
> 
> As you're probably aware, unaligned access on ARM is not guaranteed to
> succeed; depending on the CPU and the kernel configuration, in may raise
> SIGBUS instead.
> 
> The strace test suite avoids unaligned accesses for POWER and Sparc, but for
> other archs, including ARM, it deliberately tests with unaligned access. 
> This is not a problem on Debian's builders, but it is on Ubuntu's. 
> Therefore, I've uploaded the attached patch to Ubuntu.
> 
> Please consider whether this is appropriate to apply in Debian as well.
> 
> Thanks,
> -- 
> Steve Langasek                   Give me a lever long enough and a Free OS
> Debian Developer                   to set it on, and I can move the world.
> Ubuntu Developer                                    http://www.debian.org/
> slangasek at ubuntu.com                                     vorlon at debian.org

> diff -Nru strace-4.15/debian/patches/no-arm-unaligned-access strace-4.15/debian/patches/no-arm-unaligned-access
> --- strace-4.15/debian/patches/no-arm-unaligned-access	1969-12-31 16:00:00.000000000 -0800
> +++ strace-4.15/debian/patches/no-arm-unaligned-access	2017-06-15 21:57:38.000000000 -0700
> @@ -0,0 +1,18 @@
> +Description: Don't allow unaligned access on ARM in the tests
> + The testsuite already handles alignment requirements on POWER and Sparc, add
> + ARM to the list as well.  Not all ARM enviroments raise SIGBUS on unaligned
> + access, but some (including the Ubuntu autobuilders) do.
> +Author: Steve Langasek <steve.langasek at ubuntu.com>
> +Last-Update: 2017-06-16
> +
> +--- strace-4.15.orig/tests/perf_event_open.c
> ++++ strace-4.15/tests/perf_event_open.c
> +@@ -500,7 +500,7 @@ end:
> + }
> + 
> + /* These require aligned access, so no byte-grain checks possible */
> +-# if defined SPARC || defined SPARC64 || defined POWERPC || defined POWERPC64
> ++# if defined SPARC || defined SPARC64 || defined POWERPC || defined POWERPC64 || defined ARM
> + #  define ATTR_REC(sz) { tail_alloc((sz + 7) & ~7), sz }
> + # else
> + #  define ATTR_REC(sz) { tail_alloc(sz), sz }
> diff -Nru strace-4.15/debian/patches/series strace-4.15/debian/patches/series
> --- strace-4.15/debian/patches/series	2017-01-19 06:02:56.000000000 -0800
> +++ strace-4.15/debian/patches/series	2017-06-15 21:57:38.000000000 -0700
> @@ -1,1 +1,2 @@
>  disable-failing-tests.patch
> +no-arm-unaligned-access

Could you submit the patch in a git-am friendly form to the mailing list,
please?  Thanks.


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20170714/b20dd15e/attachment.bin>


More information about the Strace-devel mailing list