PR26426, ASAN: neon_quad tc-arm.c:15175

Alan Modra amodra@gmail.com
Tue Aug 25 13:27:41 GMT 2020


	PR 26426
	* config/tc-arm.c (do_neon_mvn, do_neon_swp): Bail out on
	NS_NULL shape.

diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index 1cc0cea25e..830cbda618 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -19555,6 +19555,9 @@ do_neon_mvn (void)
       else
 	rs = neon_select_shape (NS_DD, NS_QQ, NS_NULL);
 
+      if (rs == NS_NULL)
+	return;
+
       NEON_ENCODE (INTEGER, inst);
       inst.instruction |= LOW4 (inst.operands[0].reg) << 12;
       inst.instruction |= HI1 (inst.operands[0].reg) << 22;
@@ -20634,6 +20637,8 @@ static void
 do_neon_swp (void)
 {
   enum neon_shape rs = neon_select_shape (NS_DD, NS_QQ, NS_NULL);
+  if (rs == NS_NULL)
+    return;
   neon_two_same (neon_quad (rs), 1, -1);
 }
 

-- 
Alan Modra
Australia Development Lab, IBM


More information about the Binutils mailing list