Georg-Johann Lay 0237179843 re PR target/57516 ([avr] Incorrect fixed-point rounding result in the overflow case)
gcc/
	PR target/57516
	* config/avr/avr-fixed.md (round<mode>3_const): Turn expander to insn.
	* config/avr/avr.md (adjust_len): Add `round'.
	* config/avr/avr-protos.h (avr_out_round): New prototype.
	(avr_out_plus): Add `out_label' argument.
	* config/avr/avr.c (avr_out_plus_1): Add `out_label' argument.
	(avr_out_plus): Pass down `out_label' to avr_out_plus_1.
	Handle the case where `insn' is just a pattern.
	(avr_out_bitop): Handle the case where `insn' is just a pattern.
	(avr_out_round): New function.
	(avr_adjust_insn_length): Handle ADJUST_LEN_ROUND.

libgcc/
	PR target/57516
	* config/avr/lib1funcs-fixed.S (__roundqq3, __rounduqq3)
	(__round_s2_const, __round_u2_const)
	(__round_s4_const, __round_u4_const, __round_x8):
	Saturate result if addition result cannot be represented.

gcc/testsuite/
	PR target/57516
	* gcc.target/avr/torture/builtins-4-roundfx.c (test2hr, test2k):
	Adjust to corrected rounding.

From-SVN: r201051
2013-07-19 11:10:08 +00:00
..
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2011-06-01 14:46:24 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2013-02-04 19:06:20 +00:00
2011-08-05 15:13:48 +00:00
2011-11-02 15:23:48 +00:00
2011-08-05 14:37:48 +00:00
2011-11-02 15:23:48 +00:00
2011-11-02 15:23:48 +00:00
2013-02-04 19:06:20 +00:00
2011-11-02 10:49:46 +00:00
2011-11-07 17:12:33 +00:00
2013-02-04 19:06:20 +00:00
2011-06-01 14:39:17 +00:00
2013-02-04 19:06:20 +00:00
2011-06-01 14:39:17 +00:00
2013-02-04 19:06:20 +00:00
2011-08-05 15:13:48 +00:00
2011-08-05 15:13:48 +00:00
2011-08-05 15:13:48 +00:00
2013-02-04 19:06:20 +00:00
2007-07-06 07:00:46 -07:00
2013-02-04 19:06:20 +00:00