Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame^] | 1 | From 7349def8102c09fd09e735daa9fc890bee323e79 Mon Sep 17 00:00:00 2001 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 2 | From: Mahesh Bodapati <mbodapat@xilinx.com> |
| 3 | Date: Wed, 18 Jan 2017 11:49:58 +0530 |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame^] | 4 | Subject: [PATCH 22/54] [Fix, microblaze]: Fix internal compiler error with |
| 5 | msmall-divides This patch will fix the internal error |
| 6 | microblaze_expand_divide function which comes because of rtx PLUS where the |
| 7 | mem_rtx is of type SI and the operand is of type QImode. This patch modifies |
| 8 | the mem_rtx as QImode and Plus as QImode to fix the error. |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 9 | |
| 10 | Signed-off-by :Nagaraju Mekala <nmekala@xilix.com> |
| 11 | Ajit Agarwal <ajitkum@xilinx.com> |
| 12 | ChangeLog: |
| 13 | 2016-02-23 Nagaraju Mekala <nmekala@xilix.com> |
| 14 | Ajit Agarwal <ajitkum@xilinx.com> |
| 15 | |
| 16 | *microblaze.c (microblaze_expand_divide): Update |
| 17 | --- |
| 18 | gcc/config/microblaze/microblaze.c | 2 +- |
| 19 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 20 | |
| 21 | diff --git a/gcc/config/microblaze/microblaze.c b/gcc/config/microblaze/microblaze.c |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame^] | 22 | index 5d395f047f7..29b2f6b016b 100644 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 23 | --- a/gcc/config/microblaze/microblaze.c |
| 24 | +++ b/gcc/config/microblaze/microblaze.c |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame^] | 25 | @@ -3767,7 +3767,7 @@ microblaze_expand_divide (rtx operands[]) |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 26 | emit_insn (gen_ashlsi3_bshift (regt1, operands[1], GEN_INT(4))); |
| 27 | emit_insn (gen_addsi3 (regt1, regt1, operands[2])); |
| 28 | mem_rtx = gen_rtx_MEM (QImode, |
| 29 | - gen_rtx_PLUS (Pmode, regt1, div_table_rtx)); |
| 30 | + gen_rtx_PLUS (QImode, regt1, div_table_rtx)); |
| 31 | |
| 32 | insn = emit_insn (gen_zero_extendqisi2(operands[0],mem_rtx)); |
| 33 | jump = emit_jump_insn_after (gen_jump (div_end_label), insn); |
| 34 | -- |
Andrew Geissler | a9ff2b3 | 2020-10-16 10:11:54 -0500 | [diff] [blame] | 35 | 2.17.1 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 36 | |