summaryrefslogtreecommitdiffstats
path: root/crypto/armv4cpuid.pl
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2019-02-15 09:44:39 +0100
committerRichard Levitte <levitte@openssl.org>2019-02-16 16:59:23 +0100
commit3405db97e5448c784729b56837f3f8c776a01067 (patch)
tree3038d1d73fb0964915fdfd6377bb717722c02ea7 /crypto/armv4cpuid.pl
parentb2b580fe445e064da50c13d3e00f71022da16ece (diff)
ARM assembly pack: make it Windows-friendly.
"Windows friendliness" means a) flipping .thumb and .text directives, b) always generate Thumb-2 code when asked(*); c) Windows-specific references to external OPENSSL_armcap_P. (*) so far *some* modules were compiled as .code 32 even if Thumb-2 was targeted. It works at hardware level because processor can alternate between the modes with no overhead. But clang --target=arm-windows's builtin assembler just refuses to compile .code 32... Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/8252)
Diffstat (limited to 'crypto/armv4cpuid.pl')
-rw-r--r--crypto/armv4cpuid.pl3
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/armv4cpuid.pl b/crypto/armv4cpuid.pl
index 3a7be6e541..f8aeec64f0 100644
--- a/crypto/armv4cpuid.pl
+++ b/crypto/armv4cpuid.pl
@@ -21,7 +21,6 @@ open OUT,"| \"$^X\" $xlate $flavour $output";
$code.=<<___;
#include "arm_arch.h"
-.text
#if defined(__thumb2__) && !defined(__APPLE__)
.syntax unified
.thumb
@@ -30,6 +29,8 @@ $code.=<<___;
#undef __thumb2__
#endif
+.text
+
.align 5
.global OPENSSL_atomic_add
.type OPENSSL_atomic_add,%function