diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2024-03-01 22:38:48 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-01 22:38:48 +0100 |
| commit | 4f32f78fc662493059bdf797c75e377050290ffc (patch) | |
| tree | 310731b08dd1e8875ae05c3cb766d740f650622f | |
| parent | 1fbc53af48fce3a6c3a48ca2212820dbabd2ccd1 (diff) | |
| parent | 9d713862521f70c610b687d1629ee8fc4fb1e5ce (diff) | |
| download | rust-4f32f78fc662493059bdf797c75e377050290ffc.tar.gz rust-4f32f78fc662493059bdf797c75e377050290ffc.zip | |
Rollup merge of #121730 - ecnelises:aix_pgo, r=wesleywiser
Add profiling support to AIX AIX ld needs special option to merge objects with profiling. Also, profiler_builtins should include builtins for AIX from compiler-rt.
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/linker.rs | 4 | ||||
| -rw-r--r-- | library/profiler_builtins/build.rs | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/linker.rs b/compiler/rustc_codegen_ssa/src/back/linker.rs index 1f3383815e2..e52efd86955 100644 --- a/compiler/rustc_codegen_ssa/src/back/linker.rs +++ b/compiler/rustc_codegen_ssa/src/back/linker.rs @@ -1631,7 +1631,9 @@ impl<'a> Linker for AixLinker<'a> { fn optimize(&mut self) {} - fn pgo_gen(&mut self) {} + fn pgo_gen(&mut self) { + self.cmd.arg("-bdbg:namedsects:ss"); + } fn control_flow_guard(&mut self) {} diff --git a/library/profiler_builtins/build.rs b/library/profiler_builtins/build.rs index 8e7b72f8372..9d1c1ba305b 100644 --- a/library/profiler_builtins/build.rs +++ b/library/profiler_builtins/build.rs @@ -26,6 +26,7 @@ fn main() { "InstrProfilingMerge.c", "InstrProfilingMergeFile.c", "InstrProfilingNameVar.c", + "InstrProfilingPlatformAIX.c", "InstrProfilingPlatformDarwin.c", "InstrProfilingPlatformFuchsia.c", "InstrProfilingPlatformLinux.c", |
