summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch')
-rw-r--r--meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch47
1 files changed, 47 insertions, 0 deletions
diff --git a/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch b/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch
new file mode 100644
index 0000000000..6df295f8a2
--- /dev/null
+++ b/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch
@@ -0,0 +1,47 @@
1From 63ce36396348e7c4c021cffa652d2e3d20f7963a Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 27 Jul 2018 17:51:54 +0800
4Subject: [PATCH 2/2] fix broken inline asm in tests on mips32-linux
5
6While build tests(`make check') with gcc 8.1.0 on mips32-linux,
7there is a failure
8[snip]
9|mips-wrsmllib32-linux-gcc -meb -mabi=32 -mhard-float -march=mips32
10-c -o tc08_hbl2-tc08_hbl2.o `test -f 'tc08_hbl2.c' || echo '../../../
11valgrind-3.13.0/helgrind/tests/'`tc08_hbl2.c
12|/tmp/cc37aJxQ.s: Assembler messages:
13|/tmp/cc37aJxQ.s:275: Error: symbol `L1xyzzy1main' is already defined
14|Makefile:1323: recipe for target 'tc08_hbl2-tc08_hbl2.o' failed
15[snip]
16
17Remove the duplicated L1xyzzy1main, and use local symbol to replace.
18http://tigcc.ticalc.org/doc/gnuasm.html#SEC46
19
20Upstream-Status: Submitted [https://bugs.kde.org/show_bug.cgi?id=396906]
21Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
22---
23 helgrind/tests/tc08_hbl2.c | 4 ++--
24 1 file changed, 2 insertions(+), 2 deletions(-)
25
26diff --git a/helgrind/tests/tc08_hbl2.c b/helgrind/tests/tc08_hbl2.c
27index 2a757a008..f660d82dd 100644
28--- a/helgrind/tests/tc08_hbl2.c
29+++ b/helgrind/tests/tc08_hbl2.c
30@@ -121,12 +121,12 @@
31 #elif defined(PLAT_mips32_linux) || defined(PLAT_mips64_linux)
32 # define INC(_lval,_lqual) \
33 __asm__ __volatile__ ( \
34- "L1xyzzy1" _lqual":\n" \
35+ "1:\n" \
36 " move $t0, %0\n" \
37 " ll $t1, 0($t0)\n" \
38 " addiu $t1, $t1, 1\n" \
39 " sc $t1, 0($t0)\n" \
40- " beqz $t1, L1xyzzy1" _lqual \
41+ " beqz $t1, 1b\n" \
42 : /*out*/ : /*in*/ "r"(&(_lval)) \
43 : /*trash*/ "t0", "t1", "memory" \
44 )
45--
462.17.1
47