History

ftrace: specify $alignment for sh architecture

Impact: extend scripts/recordmcount.pl with default alignment for SH Set $alignment=2 for the sh architecture so that a ".align 2" directive will be emitted for all __mcount_loc sections. Fix a whitspace error while I'm here (converted spaces to tabs).

Matt Fleming committed 17 years ago

Commit 3a3d04a1 parent c204f721 file · +2 −1Browse files

Showing the changes to scripts (1 of 1 file). Show all

Unified · Split

scripts/recordmcount.pl+2−1
@@ -135,7 +135,7 @@ my $section_regex; # Find the start of a section · 134 unmodified lines
135my $function_regex; # Find the name of a function135my $function_regex; # Find the name of a function
136 # (return offset and func name)136 # (return offset and func name)
137my $mcount_regex; # Find the call site to mcount (return offset)137my $mcount_regex; # Find the call site to mcount (return offset)
138my $alignment; # The .align value to use for $mcount_section138my $alignment; # The .align value to use for $mcount_section
139 139
140if ($arch eq "x86") {140if ($arch eq "x86") {
141 if ($bits == 64) {141 if ($bits == 64) {
@@ -176,6 +176,7 @@ if ($arch eq "x86_64") { · 34 unmodified lines
176 $cc .= " -m32";176 $cc .= " -m32";
177 177
178} elsif ($arch eq "sh") {178} elsif ($arch eq "sh") {
179 $alignment = 2;
179 180
180 # force flags for this arch181 # force flags for this arch
181 $ld .= " -m shlelf_linux";182 $ld .= " -m shlelf_linux";