Use pushsection/popsection

This commit is contained in:
bjorn3 2023-10-06 11:02:11 +00:00
parent 9facf0bf72
commit ecf271cfb6

View File

@ -14,10 +14,10 @@ fn my_func() {}
global_asm!("
.globl call_foobar
.type call_foobar,@function
.section .text.call_foobar,\"ax\",@progbits
.pushsection .text.call_foobar,\"ax\",@progbits
call_foobar: jmp {}
.size call_foobar, .-call_foobar
.text
.popsection
", sym foobar);
fn foobar() {}