Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 3 Oct 2014 15:07:44 +0000 (UTC)
From:      Andrew Turner <andrew@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r272476 - head/contrib/binutils/gas/config
Message-ID:  <201410031507.s93F7iT4018368@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: andrew
Date: Fri Oct  3 15:07:43 2014
New Revision: 272476
URL: https://svnweb.freebsd.org/changeset/base/272476

Log:
  Allow vld and vst instructions to use the canonical form from ARM ARM when
  including an alignment. Previously binutils would only allow instructions
  in the form "vld1.64 {d0, d1}, [r0, :128]" where the final comma should
  not be there, instead the above instruction should be
  "vld1.64 {d0, d1}, [r0:128]".
  
  This change duplicates the alignment code from within the function to
  handle this case.

Modified:
  head/contrib/binutils/gas/config/tc-arm.c

Modified: head/contrib/binutils/gas/config/tc-arm.c
==============================================================================
--- head/contrib/binutils/gas/config/tc-arm.c	Fri Oct  3 15:03:44 2014	(r272475)
+++ head/contrib/binutils/gas/config/tc-arm.c	Fri Oct  3 15:07:43 2014	(r272476)
@@ -4688,6 +4688,23 @@ parse_address_main (char **str, int i, i
 	      return PARSE_OPERAND_FAIL;
 	}
     }
+  else if (skip_past_char (&p, ':') == SUCCESS)
+    {
+      /* FIXME: '@' should be used here, but it's filtered out by generic
+         code before we get to see it here. This may be subject to
+         change.  */
+      expressionS exp;
+      my_get_expression (&exp, &p, GE_NO_PREFIX);
+      if (exp.X_op != O_constant)
+        {
+          inst.error = _("alignment must be constant");
+          return PARSE_OPERAND_FAIL;
+        }
+      inst.operands[i].imm = exp.X_add_number << 8;
+      inst.operands[i].immisalign = 1;
+      /* Alignments are not pre-indexes.  */
+      inst.operands[i].preind = 0;
+    }
 
   if (skip_past_char (&p, ']') == FAIL)
     {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201410031507.s93F7iT4018368>