@@ -157,18 +157,25 @@ function Base.show(io::IO, e::EventType)
157157 end
158158end
159159
160+ # To support a new architecture, look for the code corresponding to the `perf_event_open`
161+ # syscall in https://gpages.juszkiewicz.com.pl/syscalls-table/syscalls.html
160162const SYS_perf_event_open = if Sys. ARCH === :x86_64
163+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/x86/entry/syscalls/syscall_64.tbl
161164 Clong (298 )
162165elseif Sys. ARCH === :i686
166+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/x86/entry/syscalls/syscall_32.tbl
163167 Clong (336 )
164168elseif Sys. ARCH === :aarch64
169+ # See also https://arm64.syscall.sh/
165170 Clong (241 )
166171elseif Sys. ARCH === :arm
172+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/arm/tools/syscall.tbl
167173 Clong (364 )
168174elseif Sys. ARCH === :powerpc64le || Sys. ARCH === :ppc64le
175+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/powerpc/kernel/syscalls/syscall.tbl
169176 Clong (319 )
170177elseif Sys. ARCH === :riscv64 || Sys. ARCH === :rv64
171- # See syscalls table at https://jborza.com/post/2021-05-11-riscv-linux-syscalls/
178+ # See also https://jborza.com/post/2021-05-11-riscv-linux-syscalls/
172179 Clong (241 )
173180else
174181 Clong (- 1 ) # sentinel for unknown syscall ID
@@ -343,18 +350,25 @@ function Base.show(io::IO, g::EventGroup)
343350 print (io, " \t " , g. event_types[end ], " )" )
344351end
345352
353+ # To support a new architecture, look for the code corresponding to the `prctl` syscall in
354+ # https://gpages.juszkiewicz.com.pl/syscalls-table/syscalls.html
346355const SYS_prctl = if Sys. ARCH === :x86_64
356+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/x86/entry/syscalls/syscall_64.tbl
347357 Clong (157 )
348358elseif Sys. ARCH === :i686
359+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/x86/entry/syscalls/syscall_32.tbl
349360 Clong (172 )
350361elseif Sys. ARCH === :aarch64
362+ # See also https://arm64.syscall.sh/
351363 Clong (167 )
352364elseif Sys. ARCH === :arm
365+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/arm/tools/syscall.tbl
353366 Clong (172 )
354367elseif Sys. ARCH === :powerpc64le || Sys. ARCH === :ppc64le
368+ # See also https://github.com/torvalds/linux/blob/b62cef9a5c673f1b8083159f5dc03c1c5daced2f/arch/powerpc/kernel/syscalls/syscall.tbl
355369 Clong (171 )
356370elseif Sys. ARCH === :riscv64 || Sys. ARCH === :rv64
357- # See syscalls table at https://jborza.com/post/2021-05-11-riscv-linux-syscalls/
371+ # See also https://jborza.com/post/2021-05-11-riscv-linux-syscalls/
358372 Clong (167 )
359373else
360374 Clong (- 1 ) # sentinel for unknown syscall ID
0 commit comments