• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/gcc/4.9.4/880-nios2_legitimize_address.patch
Thomas PetazzoniThomas Petazzoni committed 50c02bd72b103 Aug 2016
Raw file
Source viewDiff to previous
 
1
From b0ea54f3f995754881e0ea6651133aa7b58eeaa2 Mon Sep 17 00:00:00 2001
2
From: cltang <cltang@138bc75d-0d04-0410-961f-82ee72b054a4>
3
Date: Tue, 22 Sep 2015 12:23:20 +0000
4
Subject: [PATCH] nios2_legitimize_address 2015-09-22  Chung-Lin Tang 
5
 <cltang@codesourcery.com>
6
​
7
    Backport from mainline
8
    2015-09-22  Chung-Lin Tang  <cltang@codesourcery.com>
9
​
10
    * config/nios2/nios2.c (nios2_legitimize_address): When handling
11
    'reg + reloc' cases, allow first operand to be non-REG, and use
12
    force_reg() to enforce address pattern.
13
​
14
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-5-branch@228013 138bc75d-0d04-0410-961f-82ee72b054a4
15
​
16
Fixes:
17
http://autobuild.buildroot.net/results/901/90186d1fe134b804c0101554296b1235dc0ccbb0
18
​
19
[backported to 4.9.3]
20
Signed-off-by: Romain Naour <romain.naour@gmail.com>
21
---
22
 gcc/config/nios2/nios2.c | 4 ++--
23
 1 file changed, 2 insertions(+), 2 deletions(-)
24
​
25
diff --git a/gcc/config/nios2/nios2.c b/gcc/config/nios2/nios2.c
26
index 047b615..41dd6f9 100644
27
--- a/gcc/config/nios2/nios2.c
28
+++ b/gcc/config/nios2/nios2.c
29
@@ -1786,15 +1786,15 @@ nios2_legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
30
 
31
      Which will be output as '%tls_le(var+48)(r23)' in assembly.  */
32
   if (GET_CODE (x) == PLUS
33
-      && GET_CODE (XEXP (x, 0)) == REG
34
       && GET_CODE (XEXP (x, 1)) == CONST)
35
     {
36
-      rtx unspec, offset, reg = XEXP (x, 0);
37
+      rtx unspec, offset;
38
       split_const (XEXP (x, 1), &unspec, &offset);
39
       if (GET_CODE (unspec) == UNSPEC
40
      && !nios2_large_offset_p (XINT (unspec, 1))
41
      && offset != const0_rtx)
42
    {
43
+     rtx reg = force_reg (Pmode, XEXP (x, 0));
44
      unspec = copy_rtx (unspec);
45
      XVECEXP (unspec, 0, 0)
46
        = plus_constant (Pmode, XVECEXP (unspec, 0, 0), INTVAL (offset));
47
-- 
48
2.5.0
49
​
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.