diff options
Diffstat (limited to 'scripts/recordmcount.pl')
-rwxr-xr-x | scripts/recordmcount.pl | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/scripts/recordmcount.pl b/scripts/recordmcount.pl index 56ea99a12ab7..826470d7f000 100755 --- a/scripts/recordmcount.pl +++ b/scripts/recordmcount.pl @@ -242,8 +242,13 @@ if ($arch eq "x86_64") { $cc .= " -m32"; } elsif ($arch eq "s390" && $bits == 64) { - $mcount_regex = "^\\s*([0-9a-fA-F]+):\\s*R_390_(PC|PLT)32DBL\\s+_mcount\\+0x2\$"; - $mcount_adjust = -14; + if ($cc =~ /-DCC_USING_HOTPATCH/) { + $mcount_regex = "^\\s*([0-9a-fA-F]+):\\s*c0 04 00 00 00 00\\s*brcl\\s*0,[0-9a-f]+ <([^\+]*)>\$"; + $mcount_adjust = 0; + } else { + $mcount_regex = "^\\s*([0-9a-fA-F]+):\\s*R_390_(PC|PLT)32DBL\\s+_mcount\\+0x2\$"; + $mcount_adjust = -14; + } $alignment = 8; $type = ".quad"; $ld .= " -m elf64_s390"; @@ -255,7 +260,6 @@ if ($arch eq "x86_64") { # force flags for this arch $ld .= " -m shlelf_linux"; $objcopy .= " -O elf32-sh-linux"; - $cc .= " -m32"; } elsif ($arch eq "powerpc") { $local_regex = "^[0-9a-fA-F]+\\s+t\\s+(\\.?\\S+)"; |