On Wed, 7 Dec 2016, Jeff Law wrote:
> On 12/06/2016 03:16 AM, Richard Biener wrote:
> > On Tue, 6 Dec 2016, Richard Biener wrote:
> >
> > > On Mon, 5 Dec 2016, Jeff Law wrote:
> > >
> > > > On 12/02/2016 01:33 AM, Richard Biener wrote:
> > > > > > The LHS on the assignment makes it easier to ide
On Thu, 8 Dec 2016, Jakub Jelinek wrote:
> Hi!
>
> The following testcases show two bugs in zero_one_operation (used during
> undistribute optimization) and functions it calls.
> The first one (wrong-code) is fixed by the
> + tree orig_def = *def;
> and
> - if (stmts_to_fix.length () > 0)
> +
On Thu, Dec 8, 2016 at 2:55 PM, Josh Conner wrote:
> This patch adds support to gcc for the Fuchsia OS
> (https://fuchsia.googlesource.com/).
>
> OK for mainline?
A few comments:
> +/* Build with PIC by default. */
> +#undef CC1_SPEC
> +#define CC1_SPEC "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: -
On Wed, Dec 7, 2016 at 12:18 AM, Jeff Law wrote:
>
>
> So I was going through the various DSE related bugs as stumbled across
> 67955.
>
> The basic issue in 67955 is that DSE is too simplistic when trying to
> determine if two writes hit the same memory address. There are cases were
> PTA analys
Hi Segher,
Working through my backlog of Darwin patches … this one is needed on trunk and
6.x
(although it’s marked as rtl-optimization, it actually prevents bootstrap on
the branch with
Java enabled). Therefore, if possible, I’d like to get this in before the 6.3
freeze.
The Darwin p
On 08/12/16 21:40 +0100, François Dumont wrote:
On 06/12/2016 12:54, Jonathan Wakely wrote:
On 20/11/16 19:14 +0100, François Dumont wrote:
Talking about _M_color I just realize that move semantic doesn't
copy _M_color. Shouldn't we capture it along with all the other
_M_header information ?
Hi Ian,
> This patch to libgo copies the memory hashing code from the Go 1.7
> runtime. This is particular important because we earlier copied the
> hashmap code from Go 1.7, and that changed hash table sizes from prime
> numbers to powers of two. The memory hashing code used before this
> patch
Hi,
The -mnan=2008 and -mabs=2008 options are not supported on pre-R2 targets.
This results in failures for tests which use these options, such as nan-2008.c,
fabs-2008.c etc.
This patch makes the testsuite upgrade to R2 if -mnan=2008 and -mabs=2008 are
used as test options.
Tested with mips-mti
The following fixes a jump-threading bug when threading through a backedge
(thus it's only applicable to GCC 5). The issue is that when we see
a backedge walking the SSA value chain might end up picking up values
from a previous iteration.
The fix is to add backedge_seen to yet another function
Hi Iain,
On Fri, Dec 09, 2016 at 08:45:11AM +, Iain Sandoe wrote:
> The Darwin pic base loads (and reloads for non-local-gotos) are not validly
> copied (since the pic base label would be duplicated). Thus, this patch marks
> them accordingly.
>
> OK for trunk?
> OK for GCC-6 branch?
Okay f
Toma Tabacu writes:
> The msa-builtins-err.c test is failing in the following configuration:
> -O2 -flto -fuse-linker-plugin -fno-fat-lto-objects
> This is because the errors it is checking for are triggered by assembly
> generation, which is prevented by -fno-fat-lto-objects.
>
> This patch fixe
On 9 December 2016 at 00:54, Martin Sebor wrote:
>>> +enabled with @option{-Wextra}.
>>
>> So I think we should in the immediate term not enable this in Wextra.
>> However, I think for gcc-8 we should revisit after fixing GCC to be
>> cleaner WRT alloc-zero.
>>
>> So disable alloc-zero by default,
On Thu, Dec 8, 2016 at 4:00 PM, Martin Liška wrote:
> There's a patch that adds a new test-case for that.
Ok.
> Martin
On Thu, Dec 8, 2016 at 2:37 PM, Martin Liška wrote:
> Hello.
>
> Following patch changes behavior in pretty_print_string, where all
> non-printable
> characters are encoded as \x%x. Currently, when some non-printable characters
> are directly
> printed to a dump file stream. That makes it compli
Following patch enhances scripts and fixed various small issues.
Ready to be installed?
Martin
>From 626b70eb3526d848e2f1741f8b2384c518d2067b Mon Sep 17 00:00:00 2001
From: marxin
Date: Fri, 9 Dec 2016 11:00:16 +0100
Subject: [PATCH] Enhance analyze_brprob script
contrib/ChangeLog:
2016-12-09
On Thu, Dec 8, 2016 at 5:38 PM, Nathan Sidwell wrote:
> This patch fixes 78550, where we ICE in varasm as we discover a
> code-generating NOP_EXPR of an INTEGER_CST. output_constructor (varasm.c)
> has a STRIP_NOPs, but that leaves the NOP alone, as it is truncating a
> regular QI mode operand to
On 12/09/2016 11:00 AM, Richard Biener wrote:
> On Thu, Dec 8, 2016 at 2:37 PM, Martin Liška wrote:
>> Hello.
>>
>> Following patch changes behavior in pretty_print_string, where all
>> non-printable
>> characters are encoded as \x%x. Currently, when some non-printable
>> characters are directly
On 08/12/16 17:37, Ian Lance Taylor wrote:
+// For gccgo, use go:linkname to rename compiler-called functions to
+// themselves, so that the compiler will export them.
+//
+//go:linkname memhash runtime.memhash
+
+const (
+ // Constants for multiplication: four random odd 64-bit numbers.
+
On Thu, Dec 8, 2016 at 10:44 PM, Uros Bizjak wrote:
> Hello!
>
> Attached patch fixes fall-out from excess-precision improvements
> patch. As shown in the PR, the code throughout the compiler assumes
> FLAG_PRECISION_FAST when flag_unsafe_math_optimizations flag is in
> effect. The patch puts back
On Fri, Dec 9, 2016 at 5:25 AM, kugan wrote:
> Hi,
>
> in propagate_vr_accross_jump_function, drop_tree_overflow should be after
> fold_convert. Attached patch changes this.
>
> Bootstrapped and regression tested on x86_64-linux-gnu with no new
> regressions. Is this OK for trunk?
Ok.
Richard.
On Fri, Dec 9, 2016 at 11:05 AM, Martin Liška wrote:
> On 12/09/2016 11:00 AM, Richard Biener wrote:
>> On Thu, Dec 8, 2016 at 2:37 PM, Martin Liška wrote:
>>> Hello.
>>>
>>> Following patch changes behavior in pretty_print_string, where all
>>> non-printable
>>> characters are encoded as \x%x.
Jeff Law writes:
> On 11/19/2016 02:04 PM, Martin Sebor wrote:
>> On 10/26/2016 02:46 PM, Joseph Myers wrote:
>>> On Wed, 26 Oct 2016, Martin Sebor wrote:
>>>
The attached patch implements one such approach by having the pretty
printer recognize the space format flag to suppress the typ
On 11/23/2016 11:49 AM, Richard Biener wrote:
> On Wed, Nov 23, 2016 at 11:26 AM, Martin Liška wrote:
>> Following patch fixes situation where we do a store to a bitfield which
>> is at boundary of a record. This leads to usage of wider store, leading
>> to overwriting a following memory location.
Hi,
PR78652 was fixed by patch for PR77856, this patch adds a test for it. Test
result checked, is it OK?
Thanks,
bin
gcc/testsuite/ChangeLog
2016-12-07 Bin Cheng
PR rtl-optimization/78652
* gcc.c-torture/execute/pr78652.c: New test.diff --git a/gcc/testsuite/gcc.c-torture/e
Toma Tabacu
> The -mnan=2008 and -mabs=2008 options are not supported on pre-R2 targets.
> This results in failures for tests which use these options, such as
> nan-2008.c,
> fabs-2008.c etc.
>
> This patch makes the testsuite upgrade to R2 if -mnan=2008 and -mabs=2008 are
> used as test options
On CPUs that implement popcnt[wd] but not cnttz[wd] we can do better for
the ctz sequences than we do today.
CL[TZ]_DEFINED_VALUE_AT_ZERO can return 2, since we always return the
same fixed value (only dependent on TARGET_* options).
I originally tried to have the generic code handle this; that w
On 12/09/2016 11:02 AM, Martin Liška wrote:
> Following patch enhances scripts and fixed various small issues.
>
> Ready to be installed?
>
> Martin
>
I forgot to squash commits, this is the right patch.
M.
>From c64469dcdf114ab3a432a9006be3d291df62b8a1 Mon Sep 17 00:00:00 2001
From: marxin
D
Hi,
On Fri, Dec 09, 2016 at 03:36:44PM +1100, kugan wrote:
> On 07/12/16 21:08, Martin Jambor wrote:
> > On Mon, Nov 28, 2016 at 04:25:00PM +1100, kugan wrote:
> >
> > ...
> >
> > > Here is a patch that does this. To fox PR78365, in
> > > ipa_get_callee_param_type, I am now checking DECL_ARGUMENTS
The following fixes the bug for the particular testcase by making
cst_and_fits_in_hwi look at the actual value of the constant.
There's still underlying issues in dependence analysis (using ints
to store HOST_WIDE_INTs, failing to check whether the constants
really fit). But this one makes us be
Hi Mikael,
thanks a lot for your comments. Note I also have added the reply to your latest
email here.
On Thu, 8 Dec 2016 23:49:57 +0100
Mikael Morin wrote:
> > diff --git a/gcc/fortran/data.c b/gcc/fortran/data.c
> > index 139ce88..4f835b3 100644
> > --- a/gcc/fortran/data.c
> > +++ b/gcc/fo
Hello.
I've spent quite some time reading sanopt pass and I eventually decided to come
up
with quite simplified optimization algorithm for ASAN_MARK internal functions.
As the
most interesting (common) cases are that an ASAN_MARK unpoison is dominated by
entry
block (where we unpoison all varia
Hi Steve,
In doing the final regtest of the fix for PR44265, I found that
charlen_15.f90 is still giving the original error for PR78350.
module.c:3419 is seeing (after continuing three times)
(gdb) print *e->ts.u.cl->length
$12 = {expr_type = 0, ts = {type = 81, kind = 0, u = {derived = 0x20ff570
On 12/03/2016 10:49 AM, Uros Bizjak wrote:
Based on the above explanation, the patch is OK.
I'll be treating the ifcvt part of it as obvious. However, testing
showed an issue with the i386 funcspec-11 test:
/* PR target/36936 */
/* { dg-do compile } */
/* { dg-require-effective-target ia32
On Fri, Dec 9, 2016 at 1:47 PM, Paul Richard Thomas
wrote:
> Hi Steve,
>
> In doing the final regtest of the fix for PR44265, I found that
> charlen_15.f90 is still giving the original error for PR78350.
>
> module.c:3419 is seeing (after continuing three times)
> (gdb) print *e->ts.u.cl->length
>
On Fri, Dec 09, 2016 at 12:39:24PM +0100, Martin Liška wrote:
> + if (is_gimple_call (stmt) && gimple_call_internal_p (stmt))
> + {
> + enum internal_fn ifn = gimple_call_internal_fn (stmt);
> + switch (ifn)
> + {
> + case IFN_ASAN_MARK:
> +
On 11/18/2016 06:22 PM, Pierre-Marie de Rodat wrote:
I agree with you, so I’ll revise to instead add a DW_AT_type attribute
to enumeration DIEs to point to a base type.
Here is the patch to implement this. Bootstrapped and regtested (GCC’s
testsuite) successfuly on x86_64-linux.
However, it
On 7 December 2016 at 17:36, Jakub Jelinek wrote:
> On Wed, Dec 07, 2016 at 05:02:46PM +0530, Prathamesh Kulkarni wrote:
>> + if (arg1_len == NULL_TREE)
>> + {
>> + gimple_stmt_iterator gsi;
>> + tree
Dear All,
Following a discussion on #gfortran with Andre and Dominique the patch
has been committed without char_result_[16,17].f90 as revision 243478.
This has been one of the most ill-starred of any patch that I have
submitted. At the last moment, I found that char_result_14.f90 was
suffering f
On Fri, Dec 9, 2016 at 11:51 AM, Martin Jambor wrote:
> Hi,
>
> On Fri, Dec 09, 2016 at 03:36:44PM +1100, kugan wrote:
>> On 07/12/16 21:08, Martin Jambor wrote:
>> > On Mon, Nov 28, 2016 at 04:25:00PM +1100, kugan wrote:
>> >
>> > ...
>> >
>> > > Here is a patch that does this. To fox PR78365, in
On Thu, Dec 08, 2016 at 01:42:44PM -0700, Martin Sebor wrote:
> On 12/08/2016 01:28 PM, Marek Polacek wrote:
> > On Thu, Dec 08, 2016 at 02:56:56PM -0500, Nathan Sidwell wrote:
> > > On 12/08/2016 01:05 PM, Jason Merrill wrote:
> > > > If the problem is the member initializer, we can diagnose that
On Fri, Dec 09, 2016 at 05:36:41PM +0530, Prathamesh Kulkarni wrote:
> --- a/gcc/tree-ssa-strlen.c
> +++ b/gcc/tree-ssa-strlen.c
> @@ -2302,7 +2302,81 @@ strlen_optimize_stmt (gimple_stmt_iterator *gsi)
> else if (gimple_assign_rhs_code (stmt) == POINTER_PLUS_EXPR)
> handle_pointe
Hi Jerry,
thanks for the review. Committed as r243480.
Regards,
Andre
On Thu, 8 Dec 2016 12:10:55 -0800
Jerry DeLisle wrote:
> On 12/08/2016 05:42 AM, Andre Vehreschild wrote:
> > Ping!
> >
> > On Fri, 2 Dec 2016 13:28:40 +0100
> > Andre Vehreschild wrote:
> >
> >> Hi all,
> >>
> >>
On 12/08/2016 03:42 PM, Martin Sebor wrote:
On 12/08/2016 01:28 PM, Marek Polacek wrote:
On Thu, Dec 08, 2016 at 02:56:56PM -0500, Nathan Sidwell wrote:
struct Foo {
int a;
char ary[];
Foo () : ary ("bob"){}
Clang accepts this test case although it does reject the originally
submitted test
Hi Janus,
yes, that was what I had in mind for the testcase. Now it looks ok to me.
- Andre
On Thu, 8 Dec 2016 16:41:23 +0100
Janus Weil wrote:
> Hi Andre,
>
> > so when I interpret the testcase correctly, than the finalizer should not be
> > called, right? So adding a call abort() in the Fin
Fixing the cost model for large permuted SLP groups broke this due to
the excessive amount of garbage we create. A previous fix for this
was (ab-)using the cost-model so this one simply makes a hard upper
bound for SLP group sizes.
Bootstrap and regtest running on x86_64-unknown-linux-gnu.
Rich
Hi Jerry,
thanks for the review. Committed as r243482.
Regards,
Andre
On Thu, 8 Dec 2016 12:12:02 -0800
Jerry DeLisle wrote:
> On 12/08/2016 05:43 AM, Andre Vehreschild wrote:
> > Ping!
> >
> > On Fri, 2 Dec 2016 16:46:29 +0100
> > Andre Vehreschild wrote:
> >
> >> Hi all,
> >>
> >>
This series includes most of the changes in group C from:
https://gcc.gnu.org/ml/gcc/2016-11/msg00033.html
The idea is to add wrapper classes around machine_mode_enum
for specific groups of modes, such as scalar integers, scalar floats,
complex values, etc. This has two main benefits: one sp
Later patches will add wrapper types for specific classes
of mode. E.g. SImode will be a scalar_int_mode, SFmode will
be a scalar_float_mode, etc. This patch prepares for that
change by adding an E_ prefix to the mode enum values.
It also adds #defines that map the unprefixed names
to the prefixe
Hi!
My tree-ssa-reassoc.c fix backport for 6 branch depends on 2 other patches,
where the testcases don't fail on the branch for those 2, but the issue has
been just latent. Are these ok to backport to 6.3 too?
Bootstrapped/regtested on x86_64-linux and i686-linux.
Jakub
2016-12-09 Jak
This patch renames enum machine_mode to enum machine_mode_enum
and adds a machine_mode wrapper class.
The previous patch mechanically replaced mode names in case
statements; this one updates other places that should continue
to use the enum directly.
The patch continues to use enums for static va
This patch adds gdb hooks for printing machine_modes in the
natural way.
gcc/
* gdbhooks.py (MachineModePrinter): New class.
(build_pretty_printer): Use it for machine_modes.
diff --git a/gcc/gdbhooks.py b/gcc/gdbhooks.py
index 1212312..95f4b95 100644
--- a/gcc/gdbhooks.py
+++ b/g
The new iterators are:
- FOR_EACH_MODE_IN_CLASS: iterate over all the modes in a mode class.
- FOR_EACH_MODE_FROM: iterate over all the modes in a class,
starting at a given mode.
- FOR_EACH_WIDER_MODE: iterate over all the modes in a class,
starting at the next widest mode after a given mod
Store the type mode in a variable so that a later,
more mechanical patch can change its type.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* tree-switch-conversion.c (array_value_type): Only read TYPE_MODE
once. Use get_narrowest_mo
GET_MODE_WIDER previously returned VOIDmode if no wider
mode exists. That would cause problems with stricter mode
classes, since VOIDmode isn't for example a valid scalar
integer or floating-point mode. This patch instead makes
it return a new opt_mode class, which holds either
a T or nothing.
g
On 02/12/2016 01:41, Jonathan Wakely wrote:
On 01/12/16 22:51 +0100, François Dumont wrote:
We needed the StdExpVerAnyPrinter just because of the loopkup for
'std::string' which has to be 'std::__7::string'. But I used similar
technique exposed previously to get rid of it.
But I don't see any
On Fri, 9 Dec 2016, Jakub Jelinek wrote:
> Hi!
>
> My tree-ssa-reassoc.c fix backport for 6 branch depends on 2 other patches,
> where the testcases don't fail on the branch for those 2, but the issue has
> been just latent. Are these ok to backport to 6.3 too?
Yes.
Thanks,
Richard.
This patch adds a scalar_float_mode class, which wraps a mode enum
that is known to satisfy SCALAR_FLOAT_MODE_P. Things like "SFmode"
now give a scalar_float_mode object instead of a machine_mode.
This in turn needs a change to the real.h format_helper, so that
it can accept both machine_modes and
Replace checks of:
GET_MODE_CLASS (fmode) != MODE_FLOAT && !DECIMAL_FLOAT_MODE_P (fmode)
with !is_a and use MODE_CLASS equality/inequality
instead of:
(GET_MODE_CLASS (tmode) == MODE_FLOAT && DECIMAL_FLOAT_MODE_P (fmode))
|| (GET_MODE_CLASS (fmode) == MODE_FLOAT && DECIMAL_FLOAT_MODE_P (t
This patch adds a macro that extracts the TYPE_MODE and forcibly
converts it to a scalar_float_mode. The forcible conversion
includes a gcc_checking_assert that the mode is a SCALAR_FLOAT_MODE_P.
This becomes important as more static type checking is added by
later patches. It has the additional
As per subject.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* output.h (assemble_real): Take a scalar_float_mode.
* config/arm/arm.c (arm_assemble_integer): Update accordingly.
* config/arm/arm.md (consttable_4): Likewise.
On Fri, Dec 9, 2016 at 1:48 PM, Richard Sandiford
wrote:
> This series includes most of the changes in group C from:
>
> https://gcc.gnu.org/ml/gcc/2016-11/msg00033.html
>
> The idea is to add wrapper classes around machine_mode_enum
> for specific groups of modes, such as scalar integers, sca
On Fri, 2016-12-09 at 12:59 +0100, Pierre-Marie de Rodat wrote:
> There seems to be only two legal DWARF alternatives to solve this issue:
> one is to add a DW_AT_type attribute to DW_TAG_enumerator_type DIEs to
> make it point to a base type that specifies the signedness. The other
> is to make s
This provides a type-safe way to ask for a float mode and get it as a
scalar_float_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* coretypes.h (opt_scalar_float_mode): New typedef.
* machmode.h (float_mode_for_size): New functio
This means that we know when accessing the modes that the size is
a compile-time constant, even for SVE. It also enables stricter
type safety in later patches.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* machmode.h (mode_iterator::start)
As per subject.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* target.def (default_floatn_mode): Return an opt_scalar_float_mode.
* doc/tm.texi: Regenerate.
* config/arm/arm.c (arm_floatn_mode): Return an opt_scalar_float_mod
As per subject.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* target.def (default_libgcc_floating_mode_supported_p): Take
a scalar_float_mode.
* doc/tm.texi: Regenerate.
* targhooks.h (default_floatn_mode): Take a sc
Similar to the previous scalar_float_mode patch, but for modes that
satisfy SCALAR_INT_MODE_P. There are very many uses of scalar integers,
so this patch only makes one token change to the types of byte_mode,
word_mode and ptr_mode. The next patches in the series gradually
replace more uses.
gcc
This patch adds a POD class for scalar integers, as an instance
of a new pod_mode template. Later patches will use pod_mode in
situations that really do need to be POD; in this patch we're
simply using PODs to remove load-time initialisation.
gcc/
2016-11-24 Richard Sandiford
Alan
This patch adds a wrapper around mode_for_size for cases in which
the mode class is MODE_INT (the commonest case). The return type
can then be an opt_scalar_int_mode instead of a machine_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
*
Also use int_mode_for_mode instead of (int_)mode_for_size
in cases where the requested size was the bitsize of an
existing mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* machmode.h (opt_mode::else_blk): New function.
(int_mode_
This patch adds a wrapper around smallest_mode_for_size
for cases in which the mode class is MODE_INT. Unlike
(int_)mode_for_size, smallest_mode_for_size always returns
a mode of the specified class, asserting if no such mode exists.
smallest_int_mode_for_size therefore returns a scalar_int_mode
r
Replace checks of "GET_MODE_CLASS (...) == MODE_INT" with
"is_int_mode (..., &var)", in cases where it becomes useful
to refer to the mode as a scalar_int_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* machmode.h (is_int_mode): New fuc
Replace checks of "SCALAR_INT_MODE_P (...)" with
"is_a (..., &var)" in cases where it
becomes useful to refer to the mode as a scalar_int_mode.
Also:
- Replace some lingering checks for the two constituent
classes (MODE_INT and MODE_PARTIAL_INT)
- Introduce is_a checks for some uses of
HWI_
This patch replaces some checks of !VECTOR_MODE_P with checks
of is_a , in cases where the scalar integer
modes were the only useful alternatives left.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* simplify-rtx.c (simplify_binary_operation_
This patch replaces some checks against VOIDmode with checks
of is_a , in cases where scalar integer modes
were the only useful alternatives left.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* cfgexpand.c (expand_debug_expr): Use is_a
This patch replaces a check against BLKmode with a check
of is_a , in a case where scalar integer
modes were the only useful alternatives left.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* gimple-fold.c (gimple_fold_builtin_memory_op): Use
Explicitly check for scalar_int_mode in code that checks for full-mode
bit operations. These operations wouldn't work correctly for vector
modes, for example. In many cases this is enforced also by checking
whether an operand is CONST_INT_P, but there were other cases where the
condition is more
Add is_a checks to various places that were
optimising subregs or extractions in ways that only made sense
for scalar integers. Often the subreg transformations were
looking for extends, truncates or shifts and trying to remove
the subreg, which wouldn't be correct if the SUBREG_REG was
a vector
Add is_a checks before load_extend_op/
LOAD_EXTEND_OP calls, if that becomes useful for later patches.
(load_extend_op will return UNKNOWN for any other type of mode.)
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* cse.c (cse_insn): Add is_
This patch adds is_a checks to various places
that were explicitly or implicitly restricted to integers already,
in cases where adding an explicit is_a is useful
for later patches.
In simplify_if_then_else, the:
GET_MODE (XEXP (XEXP (t, 0), N))
expressions were equivalent to:
GET_MODE (XE
The *_loc_descriptor routines for clz, popcount, bswap and rotate
all required SCALAR_INT_MODE_P. This patch moves the checks into
the caller (mem_loc_descriptor) so that the types of the mode
parameters can be scalar_int_mode instead of machine_mode.
The MOD handling in mem_loc_descriptor is als
Add is_a tests to a couple of places that
were splitting doubleword integer operations into word_mode
operations. Also use scalar_int_mode in the expand_expr_real_2
handling of doubleword shifts.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
The postreload move2add optimisations are specific to scalar
integers. This patch adds an explicit check to the main guarding
"if" and propagates the information through subroutines.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* postreload
A future patch will make valid_pointer_mode take a scalar_int_mode
instead of a machine_mode. is_a <...> rather than as_a <...> is
needed here because we're checking a mode supplied by the user.
gcc/c-family/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
Replace uses of GET_CLASS_NARROWEST_MODE (MODE_INT) with a new
NARROWEST_INT_MODE macro, which has type scalar_int_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* machmode.h (NARROWEST_INT_MODE): New macro.
* expr.c (alignment_f
This patch adds a SCALAR_INT_TYPE_MODE macro that asserts
that the type has a scalar integer mode and returns it as
a scalar_int_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* tree.h (SCALAR_INT_TYPE_MODE): New macro.
* builtin
This patch adds asserting as_a conversions
in contexts where the input is known to be a scalar integer mode.
In expand_divmod, op1 is always a scalar_int_mode if
op1_is_constant (but might not be otherwise).
In expand_binop, the patch reverses a < comparison in order to
avoid splitting a long li
This patch changes the iv modes in rtx_iv from machine_mode
to scalar_int_mode. It also passes the mode of the iv down
to subroutines; this avoids the previous situation in which
the mode information was sometimes lost and had to be added
by the caller on return.
Some routines already took a mode
cstore patterns always have a scalar integer result, which has the
value 0 for "false" and STORE_FLAG_VALUE for "true". This patch
makes that explicit using scalar_int_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* target.def (cstore_
strict_volatile_bitfield_p returns false for any mode that isn't
a scalar integer. This patch moves the check to the caller and
makes strict_volatile_bitfield_p take the mode as a scalar_int_mode.
The handling of a true return can then also use the mode as a
scalar_int_mode.
gcc/
2016-11-24 Rich
get_best_mode always returns a scalar_int_mode on success,
so this patch makes that explicit in the type system. Also,
the "largest_mode" argument is used simply to provide a maximum
size, and in practice that size is always a compile-time constant,
even when the concept of variable-sized modes is
insv, extv and eztzv modify or read a field in a register or
memory. The field always has a scalar integer mode, while the
register or memory either has a scalar integer mode or BLKmode.
The mode of the bit position is also a scalar integer.
This patch uses the type system to make that explicit.
force_to_mode exits partway through for modes that aren't scalar
integers. This patch splits the remainder of the function out
into a subroutine, force_int_to_mode, so that the modes from that
point on can have type scalar_int_mode.
The patch also makes sure that xmode is kept up-to-date with x
a
This patch makes simplify_shift_const_1 use scalar_int_modes
for all code that is specific to scalars rather than vectors.
This includes situations in which the new shift mode is different
from the original one, since the function never changes the mode
of vector shifts. That in turn makes it more
The main loop of simplify_comparison starts with:
if (GET_MODE_CLASS (mode) != MODE_INT
&& ! (mode == VOIDmode
&& (GET_CODE (op0) == COMPARE || COMPARISON_P (op0
break;
So VOIDmode is only acceptable when comparing a COMPARE,
EQ, NE, etc. operand agains
After previous patches, top-level calls to simplify_and_const_int
always pass a scalar_int_mode. The only call site that needs to
be updated is the recursive one in simplify_and_const_int_1,
at which point we know "varop" has a scalar integer mode.
gcc/
2016-11-24 Richard Sandiford
On Fri, Dec 9, 2016 at 2:08 PM, Richard Sandiford
wrote:
> This patch replaces a check against BLKmode with a check
> of is_a , in a case where scalar integer
> modes were the only useful alternatives left.
So why's BLKmode no longer sth valid to check against? The check is only there
to guard G
Hi Andre,
> yes, that was what I had in mind for the testcase. Now it looks ok to me.
thanks for reviewing, committed as r243483.
Cheers,
Janus
> On Thu, 8 Dec 2016 16:41:23 +0100
> Janus Weil wrote:
>
>> Hi Andre,
>>
>> > so when I interpret the testcase correctly, than the finalizer should
This patch passes the mode of the shifted value to extract_left_shift
and updates the only caller so that the mode is a scalar_int_mode.
gcc/
2016-11-24 Richard Sandiford
Alan Hayward
David Sherwood
* combine.c (extract_left_shift): Add a mode argument and u
The comment for widest_int_mode said that it returns "the widest integer
mode no wider than SIZE", but it actually returns the widest integer
mode that is narrower than SIZE. In practice SIZE is always greater
than 1, so it can always pick QImode in the worst case. The VOIDmode
paths seem to be d
1 - 100 of 211 matches
Mail list logo