Skip to content

[AArch64] Fix to Neoverse V2 scheduling model #88130

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 11, 2024

Conversation

mgabka
Copy link
Contributor

@mgabka mgabka commented Apr 9, 2024

The size of ROB was incorrecty copied from the Neoverse N2, while it has actually higher value as descibed in
https://community.arm.com/arm-community-blogs/b/infrastructure-solutions-blog/posts/arm-neoverse-v2-platform-best-in-class-cloud-and-ai-ml-performance

@llvmbot
Copy link
Member

llvmbot commented Apr 9, 2024

@llvm/pr-subscribers-backend-aarch64

Author: Maciej Gabka (mgabka)

Changes

The size of ROB was incorrecty copied from the Neoverse N2, while it has actually higher value as descibed in
https://community.arm.com/arm-community-blogs/b/infrastructure-solutions-blog/posts/arm-neoverse-v2-platform-best-in-class-cloud-and-ai-ml-performance


Full diff: https://github.com/llvm/llvm-project/pull/88130.diff

1 Files Affected:

  • (modified) llvm/lib/Target/AArch64/AArch64SchedNeoverseV2.td (+1-1)
diff --git a/llvm/lib/Target/AArch64/AArch64SchedNeoverseV2.td b/llvm/lib/Target/AArch64/AArch64SchedNeoverseV2.td
index 4d7f44e7b9b9ab..7fed8fed900171 100644
--- a/llvm/lib/Target/AArch64/AArch64SchedNeoverseV2.td
+++ b/llvm/lib/Target/AArch64/AArch64SchedNeoverseV2.td
@@ -15,7 +15,7 @@
 
 def NeoverseV2Model : SchedMachineModel {
   let IssueWidth            =  16; // Micro-ops dispatched at a time.
-  let MicroOpBufferSize     = 160; // Entries in micro-op re-order buffer. NOTE: Copied from N2.
+  let MicroOpBufferSize     = 320; // Entries in micro-op re-order buffer.
   let LoadLatency           =   4; // Optimistic load latency.
   let MispredictPenalty     =  10; // Extra cycles for mispredicted branch.  NOTE: Copied from N2.
   let LoopMicroOpBufferSize =  16; // NOTE: Copied from Cortex-A57.

@davemgreen davemgreen changed the title Fix to Neoverse V2 scheduling model [AArch64] Fix to Neoverse V2 scheduling model Apr 9, 2024
@davemgreen
Copy link
Collaborator

Is adding a test for this is difficult, as it doesn't modify much in practice? The change sounds sensible.

@mgabka
Copy link
Contributor Author

mgabka commented Apr 10, 2024

Is adding a test for this is difficult, as it doesn't modify much in practice? The change sounds sensible.

Yeah, to me looks like this value does not impact much, in most cases it is just checked if it is !=0 or ==1, the only one place I found where the actual value matters is here

Rem.IsAcyclicLatencyLimited = InFlightCount > BufferLimit;
,

that code seems to be added by c01b004 and the EnableCyclicPath is now by defult true, but setting it to false does not break any tests for me.

Copy link
Collaborator

@davemgreen davemgreen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change looks good. Thanks

@mgabka mgabka merged commit 9c6e54b into llvm:main Apr 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants