• 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/binutils/binutils-2.20/400-arm_link_speed.patch
Gustavo ZacariasGustavo Zacarias committed 009407e6be831 Dec 2010
Raw file
Source viewDiff to previous
xxxxxxxxxx
 
1
From Binutils CVS:
2
​
3
http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/elf32-arm.c?rev=1.230&content-type=text/x-cvsweb-markup&cvsroot=src
4
​
5
Improves linking time from large projects on ARM.
6
diff -dupr binutils-2.20.orig/bfd/elf32-arm.c binutils-2.20/bfd/elf32-arm.c
7
--- binutils-2.20.orig/bfd/elf32-arm.c  2010-04-19 10:08:50.000000000 -0700
8
+++ binutils-2.20/bfd/elf32-arm.c   2010-04-19 10:12:45.000000000 -0700
9
@@ -12736,108 +12736,15 @@ elf32_arm_section_from_shdr (bfd *abfd,
10
   return TRUE;
11
 }
12
​
13
-/* A structure used to record a list of sections, independently
14
-   of the next and prev fields in the asection structure.  */
15
-typedef struct section_list
16
-{
17
-  asection * sec;
18
-  struct section_list * next;
19
-  struct section_list * prev;
20
-}
21
-section_list;
22
-
23
-/* Unfortunately we need to keep a list of sections for which
24
-   an _arm_elf_section_data structure has been allocated.  This
25
-   is because it is possible for functions like elf32_arm_write_section
26
-   to be called on a section which has had an elf_data_structure
27
-   allocated for it (and so the used_by_bfd field is valid) but
28
-   for which the ARM extended version of this structure - the
29
-   _arm_elf_section_data structure - has not been allocated.  */
30
-static section_list * sections_with_arm_elf_section_data = NULL;
31
-
32
-static void
33
-record_section_with_arm_elf_section_data (asection * sec)
34
-{
35
-  struct section_list * entry;
36
-
37
-  entry = bfd_malloc (sizeof (* entry));
38
-  if (entry == NULL)
39
-    return;
40
-  entry->sec = sec;
41
-  entry->next = sections_with_arm_elf_section_data;
42
-  entry->prev = NULL;
43
-  if (entry->next != NULL)
44
-    entry->next->prev = entry;
45
-  sections_with_arm_elf_section_data = entry;
46
-}
47
-
48
-static struct section_list *
49
-find_arm_elf_section_entry (asection * sec)
50
-{
51
-  struct section_list * entry;
52
-  static struct section_list * last_entry = NULL;
53
-
54
-  /* This is a short cut for the typical case where the sections are added
55
-     to the sections_with_arm_elf_section_data list in forward order and
56
-     then looked up here in backwards order.  This makes a real difference
57
-     to the ld-srec/sec64k.exp linker test.  */
58
-  entry = sections_with_arm_elf_section_data;
59
-  if (last_entry != NULL)
60
-    {
61
-      if (last_entry->sec == sec)
62
-   entry = last_entry;
63
-      else if (last_entry->next != NULL
64
-          && last_entry->next->sec == sec)
65
-   entry = last_entry->next;
66
-    }
67
-
68
-  for (; entry; entry = entry->next)
69
-    if (entry->sec == sec)
70
-      break;
71
-
72
-  if (entry)
73
-    /* Record the entry prior to this one - it is the entry we are most
74
-       likely to want to locate next time.  Also this way if we have been
75
-       called from unrecord_section_with_arm_elf_section_data() we will not
76
-       be caching a pointer that is about to be freed.  */
77
-    last_entry = entry->prev;
78
-
79
-  return entry;
80
-}
81
-
82
 static _arm_elf_section_data *
83
 get_arm_elf_section_data (asection * sec)
84
 {
85
-  struct section_list * entry;
86
-
87
-  entry = find_arm_elf_section_entry (sec);
88
-
89
-  if (entry)
90
-    return elf32_arm_section_data (entry->sec);
91
+  if (sec && sec->owner && is_arm_elf (sec->owner))
92
+    return elf32_arm_section_data (sec);
  • 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.