This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[wide-int] Restore SPARC build
- From: Richard Sandiford <rdsandiford at googlemail dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Kenneth Zadeck <zadeck at naturalbridge dot com>, mikestump at comcast dot net
- Date: Sun, 03 Nov 2013 10:23:13 +0000
- Subject: [wide-int] Restore SPARC build
- Authentication-results: sourceware.org; auth=none
...since I'd forgotten to update it when doing the wi:: stuff.
Installed as obvious.
Richard
Index: gcc/config/sparc/sparc.c
===================================================================
--- gcc/config/sparc/sparc.c 2013-11-03 10:04:56.004019113 +0000
+++ gcc/config/sparc/sparc.c 2013-11-03 10:21:25.557126367 +0000
@@ -10621,26 +10621,26 @@ sparc_fold_builtin (tree fndecl, int n_a
&& TREE_CODE (arg2) == INTEGER_CST)
{
bool overflow, overall_overflow = false;
- wide_int result = wide_int::from_tree (arg2);
+ wide_int result = arg2;
wide_int tmp;
unsigned i;
for (i = 0; i < VECTOR_CST_NELTS (arg0); ++i)
{
- wide_int e0 = wide_int::from_tree (VECTOR_CST_ELT (arg0, i));
- wide_int e1 = wide_int::from_tree (VECTOR_CST_ELT (arg1, i));
+ tree e0 = VECTOR_CST_ELT (arg0, i);
+ tree e1 = VECTOR_CST_ELT (arg1, i);
- tmp = e1.neg (&overflow);
+ tmp = wi::neg (e1, &overflow);
overall_overflow |= overall_overflow;
- tmp = e0.add (tmp, SIGNED, &overflow);
+ tmp = wi::add (e0, tmp, SIGNED, &overflow);
overall_overflow |= overall_overflow;
- if (tmp.neg_p ())
+ if (wi::neg_p (tmp))
{
- tmp = tmp.neg (&overflow);
+ tmp = wi::neg (tmp, &overflow);
overall_overflow |= overall_overflow;
}
- result = result.add (tmp, SIGNED, &overflow);
+ result = wi::add (result, tmp, SIGNED, &overflow);
overall_overflow |= overall_overflow;
}