Merge lp:~linaro-toolchain-dev/gcc-linaro/64bitatomics into lp:gcc-linaro/4.6

Proposed by Dr. David Alan Gilbert
Status: Merged
Approved by: Ramana Radhakrishnan
Approved revision: not available
Merge reported by: Dr. David Alan Gilbert
Merged at revision: not available
Proposed branch: lp:~linaro-toolchain-dev/gcc-linaro/64bitatomics
Merge into: lp:gcc-linaro/4.6
To merge this branch: bzr merge lp:~linaro-toolchain-dev/gcc-linaro/64bitatomics
Reviewer Review Type Date Requested Status
Linaro Toolchain Developers Pending
Review via email: mp+79428@code.launchpad.net

Description of the change

 This is a set of patches relating to ARM atomic operations;

  1) Correct the definition of TARGET_HAVE_DMB_MCR so that it doesn't
     produce the mcr instruction in Thumb1 (and enable on ARMv6 not just 6k
     as per the docs).
  2) Fix pr48126 which is a misplaced barrier in the atomic generation
  3) Provide 64 bit atomic operations using the new ldrexd/strexd in ARMv6k
     and above.
  4) Provide fallbacks so that when compiled for earlier CPUs a Linux kernel
     asssist is called (as per 32bit and smaller ops)
  5) Add test cases and support for those test cases, for the operations
     added in (3) and (4).

This is a backport from gcc svn of rev r19979-r19983 for Linaro spec
https://wiki.linaro.org/WorkingGroups/ToolChain/Specs/64bitsync

Dave

To post a comment you must log in.
Revision history for this message
Michael Hope (michaelh1) wrote :

cbuild has taken a snapshot of this branch at r106830 and queued it for build.

The diff against the ancestor r106825 is available at:
 http://builds.linaro.org/toolchain/snapshots/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics.diff

and will be built on the following builders:
 a9-builder armv5-builder i686 x86_64

You can track the build queue at:
 http://ex.seabright.co.nz/helpers/scheduler

cbuild-snapshot: gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics
cbuild-ancestor: lp:gcc-linaro+bzr106825
cbuild-state: check

Revision history for this message
Michael Hope (michaelh1) wrote :

cbuild successfully built this on i686-natty-cbuild199-oort2-i686r1.

The build results are available at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/i686-natty-cbuild199-oort2-i686r1

+UNSUPPORTED: gcc.dg/di-longlong64-sync-1.c
+UNSUPPORTED: gcc.dg/di-sync-multithread.c

The full diff is at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/i686-natty-cbuild199-oort2-i686r1/testsuite-diff.txt

The full testsuite results are at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/i686-natty-cbuild199-oort2-i686r1/gcc-testsuite.txt

cbuild-checked: i686-natty-cbuild199-oort2-i686r1

Revision history for this message
Michael Hope (michaelh1) wrote :

cbuild successfully built this on x86_64-natty-cbuild199-oort1-x86_64r1.

The build results are available at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/x86_64-natty-cbuild199-oort1-x86_64r1

+UNSUPPORTED: gcc.dg/di-longlong64-sync-1.c
+UNSUPPORTED: gcc.dg/di-sync-multithread.c

The full diff is at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/x86_64-natty-cbuild199-oort1-x86_64r1/testsuite-diff.txt

The full testsuite results are at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/x86_64-natty-cbuild199-oort1-x86_64r1/gcc-testsuite.txt

cbuild-checked: x86_64-natty-cbuild199-oort1-x86_64r1

Revision history for this message
Michael Hope (michaelh1) wrote :

cbuild successfully built this on armv7l-natty-cbuild199-tcpanda04-armv5r2.

The build results are available at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-tcpanda04-armv5r2

+UNSUPPORTED: gcc.dg/di-longlong64-sync-1.c
+UNSUPPORTED: gcc.dg/di-sync-multithread.c
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for excess errors)
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c In file included (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler __sync_
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler-not ldrexd
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler-not strexd
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for excess errors)
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c In file included (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not __sync_
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not ldrex\t
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not strex\t
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-times \tldrexd 46
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-times \tstrexd 46

The full diff is at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-tcpanda04-armv5r2/testsuite-diff.txt

The full testsuite results are at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-tcpanda04-armv5r2/gcc-testsuite.txt

cbuild-checked: armv7l-natty-cbuild199-tcpanda04-armv5r2

Revision history for this message
Michael Hope (michaelh1) wrote :

cbuild successfully built this on armv7l-natty-cbuild199-ursa4-cortexa9r1.

The build results are available at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-ursa4-cortexa9r1

+PASS: gcc.dg/di-longlong64-sync-1.c (test for warnings, line )
+PASS: gcc.dg/di-longlong64-sync-1.c (test for warnings, line )
+PASS: gcc.dg/di-longlong64-sync-1.c (test for excess errors)
+PASS: gcc.dg/di-longlong64-sync-1.c execution test
+PASS: gcc.dg/di-sync-multithread.c (test for excess errors)
+PASS: gcc.dg/di-sync-multithread.c execution test
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c (test for excess errors)
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c In file included (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler __sync_
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler-not ldrexd
+PASS: gcc.target/arm/di-longlong64-sync-withhelpers.c scan-assembler-not strexd
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c (test for excess errors)
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c In file included (test for warnings, line )
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not __sync_
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not ldrex\t
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-not strex\t
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-times \tldrexd 46
+PASS: gcc.target/arm/di-longlong64-sync-withldrexd.c scan-assembler-times \tstrexd 46

The full diff is at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-ursa4-cortexa9r1/testsuite-diff.txt

The full testsuite results are at:
 http://ex.seabright.co.nz/build/gcc-linaro-4.6+bzr106830~davidgil-uk~64bitatomics/logs/armv7l-natty-cbuild199-ursa4-cortexa9r1/gcc-testsuite.txt

cbuild-checked: armv7l-natty-cbuild199-ursa4-cortexa9r1

Revision history for this message
Ramana Radhakrishnan (ramana) wrote :

> +UNSUPPORTED: gcc.dg/di-longlong64-sync-1.c
> +UNSUPPORTED: gcc.dg/di-sync-multithread.c

Why is this unsupported on x86-64 ?

Ramana

Revision history for this message
Dr. David Alan Gilbert (davidgil-uk) wrote :

On 17 October 2011 09:23, Ramana Radhakrishnan
<email address hidden> wrote:
>
>> +UNSUPPORTED: gcc.dg/di-longlong64-sync-1.c
>> +UNSUPPORTED: gcc.dg/di-sync-multithread.c
>
> Why is this unsupported on x86-64 ?

They're enabled by a check that the target has the suitable instruction
available at runtime; this is check_effective_target_sync_longlong in
target-supports.exp; for
ARM I do an ldrexd to check it's got it; I didn't look to add an
appropriate test
for other arch's, but the placeholder is there so they can.

(Another way would be for arch's where long is 64bit it would be possible
to pass the buck to check_effective_target_sync_int_long).

Dave

Subscribers

People subscribed via source and target branches