[all-commits] [llvm/llvm-project] 578cf7: [RISCV] Add support for getHostCPUFeatures using h...

Yingwei Zheng via All-commits all-commits at lists.llvm.org
Mon Jul 15 19:12:00 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 578cf724de56e6c6768859bb1b6a597ee5d14ea0
      https://github.com/llvm/llvm-project/commit/578cf724de56e6c6768859bb1b6a597ee5d14ea0
  Author: Yingwei Zheng <dtcxzyw2333 at gmail.com>
  Date:   2024-07-16 (Tue, 16 Jul 2024)

  Changed paths:
    M clang/lib/Driver/ToolChains/Arch/RISCV.cpp
    M llvm/docs/ReleaseNotes.rst
    M llvm/lib/TargetParser/Host.cpp

  Log Message:
  -----------
  [RISCV] Add support for getHostCPUFeatures using hwprobe (#94352)

This patch adds support for `sys::getHostCPUFeatures` using the RISC-V
hardware probing interface.
References:
+ Loongarch patch:
https://github.com/llvm/llvm-project/commit/e53f41c39f3eb5052965c720d2cb517d2945fd12
+ asm/hwprobe.h:
https://github.com/torvalds/linux/blob/2ab79514109578fc4b6df90633d500cf281eb689/arch/riscv/include/uapi/asm/hwprobe.h
+ glibc support:
https://inbox.sourceware.org/glibc-cvs/20240301151728.AD5963858C53@sourceware.org/T/#Z2e.:..:20240301151728.AD5963858C53::40sourceware.org:1sysdeps:unix:sysv:linux:riscv:sys:hwprobe.h
+ __NR_riscv_hwprobe syscall tutorial:
https://github.com/cyyself/hwprobe
+ hwprobe docs: https://docs.kernel.org/arch/riscv/hwprobe.html

---------

Co-authored-by: Yangyu Chen <cyy at cyyself.name>



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list