Author: cognet
Date: Sat Jan 28 17:46:04 2017
New Revision: 312932
URL: https://svnweb.freebsd.org/changeset/base/312932
Log:
Use strexeq instead of needlessly branch.
Suggested by: ian
Modified:
head/sys/arm/include/atomic-v6.h
Modified: head/sys/arm/include/atomic-v6.h
==============================================================================
--- head/sys/arm/include/atomic-v6.h Sat Jan 28 17:40:37 2017
(r312931)
+++ head/sys/arm/include/atomic-v6.h Sat Jan 28 17:46:04 2017
(r312932)
@@ -201,9 +201,8 @@ atomic_fcmpset_32(volatile uint32_t *p,
"1: mov %0, #1 \n"
" ldrex %1, [%2] \n"
" cmp %1, %3 \n"
- " it ne \n"
- " bne 2f \n"
- " strex %0, %4, [%2] \n"
+ " it eq \n"
+ " strexeq %0, %4, [%2] \n"
"2:"
: "=&r" (ret), "=&r" (tmp), "+r" (p), "+r" (_cmpval), "+r" (newval)
: : "cc", "memory");
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"