* tree-vrp.c (range_fits_type_p): Move to earlier point in file.
        (simplify_cond_using_ranges): Generalize code to simplify
        COND_EXPRs where one argument is a constant and the other
        is an SSA_NAME created by an integral type conversion.

	* gcc.dg/tree-ssa/vrp88.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@198413 138bc75d-0d04-0410-961f-82ee72b054a4
Preserve loops in tail-merge

2013-04-29  Tom de Vries  <tom@codesourcery.com>

	* tree-ssa-tail-merge.c (find_same_succ_bb): Skip loop latch bbs.
	(replace_block_by): Don't set LOOPS_NEED_FIXUP.
	(tail_merge_optimize): Handle current_loops == NULL.

	* gcc.dg/pr50763.c: Update test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@198414 138bc75d-0d04-0410-961f-82ee72b054a4
This patch fixes PR bootstrap/57077. Certain new uses of apply_probability
are actually scaling the counts up, and the scale factor should not 
be treated as a probability as the value may exceed REG_BR_PROB_BASE.
One example (from the PR) is when scaling counts up in LTO when merging
profiles. Another example I found when preparing the patch to use
the rounding divide in more places is when inlining COMDAT functions.

Add new helper function apply_scale that does the scaling without
the probability range check. I audited the new uses of apply_probability
and changed the calls as appropriate.

2013-04-29  Teresa Johnson  <tejohnson@google.com>

	PR bootstrap/57077
	* basic-block.h (apply_scale): New function.
	(apply_probability): Use apply_scale.
	* gimple-streamer-in.c (input_bb): Ditto.
	* lto-streamer-in.c (input_cfg): Ditto.
	* lto-cgraph.c (merge_profile_summaries): Ditto.
	* tree-optimize.c (execute_fixup_cfg): Ditto.
	* tree-inline.c (copy_bb): Update comment to use
	apply_scale.
	(copy_edges_for_bb): Ditto.
	(copy_cfg_body): Ditto.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@198416 138bc75d-0d04-0410-961f-82ee72b054a4
c-family:
2013-04-03  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

	* c-common.c (check_user_alignment): Emit error for negative values.

testsuite:
2013-04-03  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

	* gcc.dg/c1x-align-3.c: Add test for negative power of 2.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@198417 138bc75d-0d04-0410-961f-82ee72b054a4