public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Kenneth Zadeck <zadeck@naturalbridge.com>
To: Mike Stump <mikestump@comcast.net>,
	 Richard Sandiford <rdsandiford@googlemail.com>,
	Richard Biener <rguenther@suse.de>,
	 gcc-patches <gcc-patches@gcc.gnu.org>
Subject: [wide-int] fixed several regressions in branch.
Date: Wed, 15 Jan 2014 01:27:00 -0000	[thread overview]
Message-ID: <52D5E3F9.3020503@naturalbridge.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 219 bytes --]

This patch fixes what appears to have been a long standing failure in 
the conversion of tree-vect-generic.c:build_replicated_const. This 
failure caused several regressions on the branch.

Committed as revision 206616

[-- Attachment #2: fix1.diff --]
[-- Type: text/x-patch, Size: 573 bytes --]

Index: gcc/tree-vect-generic.c
===================================================================
--- gcc/tree-vect-generic.c	(revision 206609)
+++ gcc/tree-vect-generic.c	(working copy)
@@ -57,7 +57,8 @@ static tree
 build_replicated_const (tree type, tree inner_type, HOST_WIDE_INT value)
 {
   int width = tree_to_uhwi (TYPE_SIZE (inner_type));
-  int n = TYPE_PRECISION (type) / width;
+  int n = (TYPE_PRECISION (type) + HOST_BITS_PER_WIDE_INT - 1) 
+    / HOST_BITS_PER_WIDE_INT;
   unsigned HOST_WIDE_INT low, mask;
   HOST_WIDE_INT a[WIDE_INT_MAX_ELTS];
   int i;

                 reply	other threads:[~2014-01-15  1:27 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52D5E3F9.3020503@naturalbridge.com \
    --to=zadeck@naturalbridge.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=mikestump@comcast.net \
    --cc=rdsandiford@googlemail.com \
    --cc=rguenther@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).