author | Wolfgang Rosenauer <wr@rosenauer.org> |
Thu, 23 Jul 2020 16:00:58 +0200 | |
branch | firefox78 |
changeset 1138 | 4ac678bd2a26 |
parent 1125 | 3fd9346c90a6 |
permissions | -rw-r--r-- |
1076 | 1 |
|
2 |
# HG changeset patch |
|
3 |
# User Mike Hommey <mh+mozilla@glandium.org> |
|
4 |
# Date 1526871862 -32400 |
|
5 |
# Node ID 94f21505ff13cd089f7129cd24927cf8b31a0f43 |
|
1125 | 6 |
# Parent 0b7e1398ca2e15e27da93144ba9fb30db38367b1 |
1076 | 7 |
Bug 1463035 - Remove MOZ_SIGNAL_TRAMPOLINE. r?darchons |
8 |
||
9 |
For some reason, GNU as is not happy with the assembly generated after |
|
10 |
bug 1238661 anymore on Debian armel. |
|
11 |
||
12 |
OTOH, as mentioned in bug 1238661 comment 4, we actually don't need this |
|
13 |
workaround anymore, so let's just kill it. |
|
14 |
||
1107
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
15 |
diff --git a/mozglue/baseprofiler/core/platform-linux-android.cpp b/mozglue/baseprofiler/core/platform-linux-android.cpp |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
16 |
--- a/mozglue/baseprofiler/core/platform-linux-android.cpp |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
17 |
+++ b/mozglue/baseprofiler/core/platform-linux-android.cpp |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
18 |
@@ -55,17 +55,16 @@ |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
19 |
#ifdef __GLIBC__ |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
20 |
# include <execinfo.h> // backtrace, backtrace_symbols |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
21 |
#endif // def __GLIBC__ |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
22 |
#include <strings.h> // index |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
23 |
#include <errno.h> |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
24 |
#include <stdarg.h> |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
25 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
26 |
#include "prenv.h" |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
27 |
-#include "mozilla/LinuxSignal.h" |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
28 |
#include "mozilla/PodOperations.h" |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
29 |
#include "mozilla/DebugOnly.h" |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
30 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
31 |
#include <string.h> |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
32 |
#include <list> |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
33 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
34 |
using namespace mozilla; |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
35 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
36 |
@@ -266,17 +265,17 @@ Sampler::Sampler(PSLockRef aLock) |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
37 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
38 |
// NOTE: We don't initialize LUL here, instead initializing it in |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
39 |
// SamplerThread's constructor. This is because with the |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
40 |
// profiler_suspend_and_sample_thread entry point, we want to be able to |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
41 |
// sample without waiting for LUL to be initialized. |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
42 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
43 |
// Request profiling signals. |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
44 |
struct sigaction sa; |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
45 |
- sa.sa_sigaction = MOZ_SIGNAL_TRAMPOLINE(SigprofHandler); |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
46 |
+ sa.sa_sigaction = SigprofHandler; |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
47 |
sigemptyset(&sa.sa_mask); |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
48 |
sa.sa_flags = SA_RESTART | SA_SIGINFO; |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
49 |
if (sigaction(SIGPROF, &sa, &mOldSigprofHandler) != 0) { |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
50 |
MOZ_CRASH("Error installing SIGPROF handler in the profiler"); |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
51 |
} |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
52 |
} |
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
53 |
|
a2aa55e10564
Firefox 69 as submitted to TW
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1089
diff
changeset
|
54 |
void Sampler::Disable(PSLockRef aLock) { |
1076 | 55 |
diff --git a/tools/profiler/core/platform-linux-android.cpp b/tools/profiler/core/platform-linux-android.cpp |
56 |
--- a/tools/profiler/core/platform-linux-android.cpp |
|
57 |
+++ b/tools/profiler/core/platform-linux-android.cpp |
|
1125 | 58 |
@@ -258,17 +258,17 @@ Sampler::Sampler(PSLockRef aLock) |
1076 | 59 |
|
60 |
// NOTE: We don't initialize LUL here, instead initializing it in |
|
61 |
// SamplerThread's constructor. This is because with the |
|
62 |
// profiler_suspend_and_sample_thread entry point, we want to be able to |
|
63 |
// sample without waiting for LUL to be initialized. |
|
64 |
||
65 |
// Request profiling signals. |
|
66 |
struct sigaction sa; |
|
67 |
- sa.sa_sigaction = MOZ_SIGNAL_TRAMPOLINE(SigprofHandler); |
|
68 |
+ sa.sa_sigaction = SigprofHandler; |
|
69 |
sigemptyset(&sa.sa_mask); |
|
70 |
sa.sa_flags = SA_RESTART | SA_SIGINFO; |
|
71 |
if (sigaction(SIGPROF, &sa, &mOldSigprofHandler) != 0) { |
|
72 |
MOZ_CRASH("Error installing SIGPROF handler in the profiler"); |
|
73 |
} |
|
74 |
} |
|
75 |
||
1085
87f893cf45b9
Firefox 65.0 release
Wolfgang Rosenauer <wr@rosenauer.org>
parents:
1076
diff
changeset
|
76 |
void Sampler::Disable(PSLockRef aLock) { |