Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 1 | From 2b2c6e96c3aefc86c880be05d93685a4ce97c9f1 Mon Sep 17 00:00:00 2001 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 2 | From: Nagaraju Mekala <nmekala@xilix.com> |
| 3 | Date: Tue, 11 Sep 2018 14:58:00 +0530 |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 4 | Subject: [PATCH 34/54] Fixed issues like: 1 Interrupt alignment issue 2 Sign |
| 5 | extension issue |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 6 | |
| 7 | --- |
| 8 | gcc/config/microblaze/microblaze.c | 16 ++++++++++------ |
| 9 | gcc/config/microblaze/microblaze.md | 2 +- |
| 10 | 2 files changed, 11 insertions(+), 7 deletions(-) |
| 11 | |
| 12 | 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] | 13 | index 046bfd05558..498c8ca191f 100644 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 14 | --- a/gcc/config/microblaze/microblaze.c |
| 15 | +++ b/gcc/config/microblaze/microblaze.c |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 16 | @@ -2177,9 +2177,14 @@ compute_frame_size (HOST_WIDE_INT size) |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 17 | |
| 18 | total_size += gp_reg_size; |
| 19 | |
| 20 | - /* Add 4 bytes for MSR. */ |
| 21 | + /* Add 4/8 bytes for MSR. */ |
| 22 | if (microblaze_is_interrupt_variant ()) |
| 23 | - total_size += 4; |
| 24 | + { |
| 25 | + if (TARGET_MB_64) |
| 26 | + total_size += 8; |
| 27 | + else |
| 28 | + total_size += 4; |
| 29 | + } |
| 30 | |
| 31 | /* No space to be allocated for link register in leaf functions with no other |
| 32 | stack requirements. */ |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 33 | @@ -2464,7 +2469,6 @@ print_operand (FILE * file, rtx op, int letter) |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 34 | else if (letter == 'h' || letter == 'j') |
| 35 | { |
| 36 | long val[2]; |
| 37 | - int val1[2]; |
| 38 | long l[2]; |
| 39 | if (code == CONST_DOUBLE) |
| 40 | { |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 41 | @@ -2479,10 +2483,10 @@ print_operand (FILE * file, rtx op, int letter) |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 42 | } |
| 43 | else if (code == CONST_INT || code == CONST)// || code == SYMBOL_REF ||code == LABEL_REF) |
| 44 | { |
| 45 | - val1[0] = (INTVAL (op) & 0xffffffff00000000LL) >> 32; |
| 46 | - val1[1] = INTVAL (op) & 0x00000000ffffffffLL; |
| 47 | + val[0] = (INTVAL (op) & 0xffffffff00000000LL) >> 32; |
| 48 | + val[1] = INTVAL (op) & 0x00000000ffffffffLL; |
| 49 | } |
| 50 | - fprintf (file, "0x%8.8lx", (letter == 'h') ? val1[0] : val1[1]); |
| 51 | + fprintf (file, "0x%8.8lx", (letter == 'h') ? val[0] : val[1]); |
| 52 | } |
| 53 | else if (code == CONST_DOUBLE) |
| 54 | { |
| 55 | diff --git a/gcc/config/microblaze/microblaze.md b/gcc/config/microblaze/microblaze.md |
Andrew Geissler | 10fa149 | 2020-12-11 16:25:29 -0600 | [diff] [blame] | 56 | index 592757baf2f..e7c7cf3e8b5 100644 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 57 | --- a/gcc/config/microblaze/microblaze.md |
| 58 | +++ b/gcc/config/microblaze/microblaze.md |
Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame] | 59 | @@ -1096,7 +1096,7 @@ |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 60 | case 1: |
| 61 | case 2: |
| 62 | { |
| 63 | - output_asm_insn ("ll%i1\t%0,%1", operands); |
| 64 | + output_asm_insn ("lw%i1\t%0,%1", operands); |
| 65 | return "sextl32\t%0,%0"; |
| 66 | } |
| 67 | } |
| 68 | -- |
Andrew Geissler | a9ff2b3 | 2020-10-16 10:11:54 -0500 | [diff] [blame] | 69 | 2.17.1 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 70 | |