当前位置:首页 > 报告详情

003--肖玮.pdf

上传人: 山哈 编号:725275 2025-07-04 21页 1.24MB

1、LLVM RISC-V Retrospect&Outlook回顾与展望肖玮 Wei Xiao()Contributors:刘天乐 Tianle Liu()王天晴 Tianqing Wang()闻浩海 Haohai Wen()裴根 Gen Pei()AgendaSATG|SOFTWARE AND ADVANCED TECHNOLOGY GROUP2 LLVM RISC-V Target Support Overview LLVM Architecture Overview RISC-V&LLVM FE RISC-V&LLVM ME RISC-V&LLVM BE RISC-V Performanc

2、e Analysis w/QEMULLVM RISC-V Target Support Overview Base ISAs Extensions Experimental Extensionsexperimental-zacasexperimental-zihintntlexperimental-zvfhexperimental-zca Vendor ExtensionsXVentanaCondOpsXTHeadVdotXSfvcp Profilesrvi20u32rvi20u64SATG|SOFTWARE AND ADVANCED TECHNOLOGY GROUP3LLVM Archite

3、cture Overview Classical design to support multiple source languages or target architectures Serves a broader set of programmers which naturally leads to more enhancements andimprovements to the compiler LLVM IR is a Complete Code Representation LLVM is a Collection of LibrariesSATG|SOFTWARE AND ADV

4、ANCED TECHNOLOGY GROUP4Source codeX86 IR from FERISCV IR from FEComment of RISCV(Xlen=64)struct A intint%struct.A=type i32,i32 define dso_local i64 _Z5myfunv()%struct.A=type i32,i32 define dso_local i64 _Z5myfunv()Aggregates which are=2*XLEN will be passed in registers if possiblestruct A longint%st

5、ruct.A=type i64,i32 define dso_local i64,i32 _Z5myfunv()%struct.A=type i64,i32 define dso_local 2 x i64 _Z5myfunv()Use a single XLEN int if possible,2*XLEN if 2*XLEN alignment is required,and a 2-element XLEN array if only XLEN alignment is required.struct A long*int%struct.A=type ptr,i32 define dso

6、_local ptr,i32 _Z5myfunv()%struct.A=type ptr,i32 define dso_local 2 x i64 _Z5myfunv()struct A long double%struct.A=type i64,double define dso_local i64,double _Z5myfunv()%struct.A=type i64,double define dso_local i64,double _Z5myfunv()Determine if a struct is eligible for passing according to the fl

word格式文档无特别注明外均可编辑修改,预览文件经过压缩,下载原文更清晰!
三个皮匠报告文库所有资源均是客户上传分享,仅供网友学习交流,未经上传用户书面授权,请勿作商用。
本文主要介绍了LLVM对RISC-V架构的支持情况及其未来展望。关键点如下: 1. **LLVM RISC-V目标支持概述**:介绍了基础ISA、扩展、实验性扩展和厂商扩展等支持情况。 2. **LLVM架构概述**:强调了其支持多源语言和目标架构的经典设计,以及LLVM IR的完整代码表示。 3. **RISC-V与LLVM前端**:讨论了RISC-V ABI对结构体返回类型生成的不同类型,以及与X86架构的差异。 4. **RISC-V与LLVM中端**:分析了RISC-V在地址计算、内联优化和IPO等方面的实现差异。 5. **RISC-V与LLVM后端**:涉及向量扩展、代码压缩优化等,以及特定于RISC-V架构的后端优化。 6. **性能分析**:提出了使用QEMU模拟缓存行为的方法,并指出Linux性能工具在某些RISC-V平台上的限制。 7. **优化与展望**:Intel提出对非Intel微处理器的优化不保证同等程度的效果,未来将继续对RISC-V进行更多优化工作。 综上,文章全面展示了LLVM对RISC-V架构的支持现状及面临的挑战,同时展望了未来的优化方向。
"RISC-V与LLVM的哪些扩展最吸引你?" "如何通过QEMU分析RISC-V性能?" "LLVM对RISC-V架构有何独特优化?"
客服
商务合作
小程序
服务号
折叠