Skip to contentSkip to conversation

Default to no unaligned access on unsupported archs

PATCH Mathieu Desnoyers 1 participant 1 message Jun 30, 2015 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Merged with a small configure output layout modification.

Thanks!

Mathieu

Quoted 37 lines · ----- On Jun 30, 2015, at 11:55 AM, Michael Jeanson [email protected] wrote:

---
configure.ac | 10 +++++++++-

1 file changed, 9 insertions(+), 1 deletion(-)
configure.ac +4 -1
index 03483a7..5901dfb 100644
@@ -241,7 +241,10 @@ changequote([,])dnl
 	aarch64) NO_UNALIGNED_ACCESS=1 ;;
 	mips*) NO_UNALIGNED_ACCESS=1 ;;
 	tile*) NO_UNALIGNED_ACCESS=1 ;;
-	*) AC_MSG_ERROR([unable to detect alignment requirements (unsupported
 architecture ($host_cpu)?)]) ;;
+	*)
+		UNSUPPORTED_ARCH=1
+		NO_UNALIGNED_ACCESS=1
+		;;

esac
AC_MSG_RESULT([$host_cpu])

configure.ac +5 -0
@@ -423,5 +426,10 @@ AS_ECHO_N("sdt.h integration:  ")
 AS_IF([test "x$with_sdt" = "xyes"], [AS_ECHO("Enabled")], [AS_ECHO("Disabled")])
 
 AS_ECHO()
+AS_ECHO_N("Architecture ($host_cpu) has efficient unaligned memory access: ")
+AS_IF([test "x$NO_UNALIGNED_ACCESS" != "x1"], [AS_ECHO("yes")], [AS_IF([test
 "x$UNSUPPORTED_ARCH" != "x1"], [AS_ECHO("no")], [AS_ECHO("unknown")])])
+AS_IF([test "x$UNSUPPORTED_ARCH" = "x1"], [AC_MSG_WARN([Your architecture
 ($host_cpu) is unsupported, using safe default of no unaligned access])])
+AS_ECHO()
+

AS_ECHO("Type 'make' to compile.")

--
1.9.1

Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com