HomePhabricator

Add method to TargetInfo to get CPU cache line size

Authored by zoecarver on Mar 25 2020, 9:48 AM.

Description

Add method to TargetInfo to get CPU cache line size

Summary:
This patch adds a virtual method getCPUCacheLineSize() to TargetInfo. Currently, I've only implemented the method in X86TargetInfo. It's extremely important that each CPU's cache line size correct (e.g., we can't just define it as 64 across the board) so, it has been a little slow getting to this point.

I'll work on the ARM CPUs next, but that will probably come later in a different patch.

Tags: #clang

Differential Revision: https://reviews.llvm.org/D74918

Details

Committed
zoecarverMar 25 2020, 9:50 AM
Differential Revision
D74918: Add method to TargetInfo to get CPU cache line size
Parents
rG7520cf03eeb8: [clang] Reformat cindex. NFC.
Branches
Unknown
Tags
Unknown