| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1 @@ | |||
| 1 | + Support Linux perf profiler to see Python calls on RISC-V architecture | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1 @@ | |||
| 1 | + Support Linux perf profiler to see Python calls on RISC-V architecture. | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -22,6 +22,14 @@ _Py_trampoline_func_start: | |||
| 22 | 22 | blr x3 | |
| 23 | 23 | ldp x29, x30, [sp], 16 | |
| 24 | 24 | ret | |
| 25 | + #endif | ||
| 26 | + #ifdef __riscv | ||
| 27 | + addi sp,sp,-16 | ||
| 28 | + sd ra,8(sp) | ||
| 29 | + jalr a3 | ||
| 30 | + ld ra,8(sp) | ||
| 31 | + addi sp,sp,16 | ||
| 32 | + jr ra | ||
| 25 | 33 | #endif | |
| 26 | 34 | .globl _Py_trampoline_func_end | |
| 27 | 35 | _Py_trampoline_func_end: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3641,6 +3641,7 @@ AC_MSG_CHECKING([perf trampoline]) | |||
| 3641 | 3641 | AS_CASE([$PLATFORM_TRIPLET], | |
| 3642 | 3642 | [x86_64-linux-gnu], [perf_trampoline=yes], | |
| 3643 | 3643 | [aarch64-linux-gnu], [perf_trampoline=yes], | |
| 3644 | + [riscv64-linux-gnu], [perf_trampoline=yes], | ||
| 3644 | 3645 | [perf_trampoline=no] | |
| 3645 | 3646 | ) | |
| 3646 | 3647 | AC_MSG_RESULT([$perf_trampoline]) | |
| Back | FazBrowse Home | New Git URL |
0 commit comments