File tree 1 file changed +4
-3
lines changed
compiler/rustc_codegen_llvm/src/back
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -225,9 +225,10 @@ pub(crate) fn target_machine_factory(
225
225
let use_init_array =
226
226
!sess. opts . unstable_opts . use_ctors_section . unwrap_or ( sess. target . use_ctors_section ) ;
227
227
228
- // this annotes in the debug file that code is hotpatchable. In addtion without it -functionpadmin will be ignored.
229
- // See: https://github.com/llvm/llvm-project/blob/d703b922961e0d02a5effdd4bfbb23ad50a3cc9f/lld/COFF/Writer.cpp#L1298
230
- let use_hotpatch = sess. opts . unstable_opts . hotpatch && sess. target . is_x86 ( ) ;
228
+ // this makes LLVM add a hotpatch flag in the codeview S_COMPILE3 record,
229
+ // which is required by linkers for the functionpadmin option
230
+ // aarch64 is always hotpatchable
231
+ let use_hotpatch = sess. opts . unstable_opts . hotpatch || sess. target . arch . contains ( "aarch64" ) ;
231
232
232
233
let path_mapping = sess. source_map ( ) . path_mapping ( ) . clone ( ) ;
233
234
You can’t perform that action at this time.
0 commit comments