Dataflow hardware designs enable efficient FPGA implementations via high-level synthesis (HLS), but correctly sizing first-in-first-out (FIFO) channel buffers remains challenging. FIFO sizes are user-defined and balance latency and area-undersized FIFOs cause stalls and potential deadlocks, while oversized ones waste memory. Determining optimal sizes is non-trivial: existing methods rely on restrictive assumptions, conservative over-allocation, or slow RTL simulations. We emphasize that runtime-based analyses (i.e., simulation) are the only reliable way to ensure deadlock-free FIFO optimization for data-dependent designs. We present FIFOAdvisor, a framework that automatically determines FIFO sizes in HLS designs. It leverages LightningSim, a 99.9\% cycle-accurate simulator supporting millisecond-scale incremental runs with new FIFO configurations. FIFO sizing is formulated as a dual-objective black-box optimization problem, and we explore heuristic and search-based methods to characterize the latency-resource trade-off. FIFOAdvisor also integrates with Stream-HLS, a framework for optimizing affine dataflow designs lowered from C++, MLIR, or PyTorch, enabling deeper optimization of FIFOs in these workloads. We evaluate FIFOAdvisor on Stream-HLS design benchmarks spanning linear algebra and deep learning workloads. Our results reveal Pareto-optimal latency-memory frontiers across optimization strategies. Compared to baseline designs, FIFOAdvisor achieves much lower memory usage with minimal delay overhead. Additionally, it delivers significant runtime speedups over traditional HLS/RTL co-simulation, making it practical for rapid design space exploration. We further demonstrate its capability on a complex accelerator with data-dependent control flow. Code and results: https://github.com/sharc-lab/fifo-advisor


翻译:数据流硬件设计通过高层次综合(HLS)实现了高效的FPGA实现,但正确确定先入先出(FIFO)通道缓冲器的容量仍然具有挑战性。FIFO容量由用户定义,需要在延迟和面积之间取得平衡——容量不足的FIFO会导致停顿和潜在死锁,而过大的容量则会浪费内存。确定最优容量并非易事:现有方法依赖于限制性假设、保守的过度分配或缓慢的RTL仿真。我们强调,基于运行时的分析(即仿真)是确保数据依赖型设计实现无死锁FIFO优化的唯一可靠方法。本文提出FIFOAdvisor,一个自动确定HLS设计中FIFO容量的框架。该框架利用LightningSim——一个支持毫秒级增量运行(可测试新FIFO配置)且周期精度达99.9%的仿真器。FIFO容量确定被表述为一个双目标黑盒优化问题,我们探索了启发式和基于搜索的方法来刻画延迟-资源权衡关系。FIFOAdvisor还与Stream-HLS(一个用于优化从C++、MLIR或PyTorch降级得到的仿射数据流设计的框架)集成,从而能够对这些工作负载中的FIFO进行更深层次的优化。我们在涵盖线性代数和深度学习工作负载的Stream-HLS设计基准测试上评估了FIFOAdvisor。我们的结果揭示了不同优化策略下的帕累托最优延迟-内存边界。与基线设计相比,FIFOAdvisor在实现极低延迟开销的同时,显著降低了内存使用量。此外,相较于传统的HLS/RTL协同仿真,它带来了显著的运行时加速,使其适用于快速的设计空间探索。我们进一步在一个具有数据依赖控制流的复杂加速器上展示了其能力。代码与结果:https://github.com/sharc-lab/fifo-advisor

0
下载
关闭预览

相关内容

FlowQA: Grasping Flow in History for Conversational Machine Comprehension
专知会员服务
34+阅读 · 2019年10月18日
Keras François Chollet 《Deep Learning with Python 》, 386页pdf
专知会员服务
163+阅读 · 2019年10月12日
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
meta learning 17年:MAML SNAIL
CreateAMind
11+阅读 · 2019年1月2日
STRCF for Visual Object Tracking
统计学习与视觉计算组
15+阅读 · 2018年5月29日
Focal Loss for Dense Object Detection
统计学习与视觉计算组
12+阅读 · 2018年3月15日
IJCAI | Cascade Dynamics Modeling with Attention-based RNN
KingsGarden
13+阅读 · 2017年7月16日
国家自然科学基金
13+阅读 · 2017年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
相关资讯
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
meta learning 17年:MAML SNAIL
CreateAMind
11+阅读 · 2019年1月2日
STRCF for Visual Object Tracking
统计学习与视觉计算组
15+阅读 · 2018年5月29日
Focal Loss for Dense Object Detection
统计学习与视觉计算组
12+阅读 · 2018年3月15日
IJCAI | Cascade Dynamics Modeling with Attention-based RNN
KingsGarden
13+阅读 · 2017年7月16日
相关基金
国家自然科学基金
13+阅读 · 2017年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员