[PATCH] D154488: [PowerPC] Define SchedModel for Power8
ChenZheng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 30 22:05:10 PDT 2023
shchenz added a comment.
Looks almost good to me. Some other comments related to the instruction definitions.
Please note the two failures in the premerge check on X86 target.
================
Comment at: llvm/lib/Target/PowerPC/PPCScheduleP8.td:68
+ // Two ports for fixed-point operations.
+ def P8_PORT_FX : ProcResource<2> { let Super = P8_PORT_ALLFX; }
+ // Two issue ports shared by two floating-point, two VSX, two VMX, one crypto,
----------------
nit: This issue port is not used?
================
Comment at: llvm/lib/Target/PowerPC/PPCScheduleP8.td:88
+ def P8_LS_LU : SchedWriteRes<[P8_LU, P8_LS]>;
+ def P8_LS_FP : SchedWriteRes<[P8_LU, P8_FPU]>;
+ def P8_LU_LS_3C : SchedWriteRes<[P8_LU_LS]> { let Latency = 3; }
----------------
should be `def P8_LS_FP : SchedWriteRes<[P8_LSU, P8_FPU]>;`?
================
Comment at: llvm/lib/Target/PowerPC/PPCScheduleP8.td:169
+ def : InstRW<[P8_LS_FP_FX_2C, P8_ISSUE_ST], (instrs STVEBX, STVEHX, STVEWX, STVX, STVXL)>;
+ def : InstRW<[P8_LS_FP_FX_3C, P8_ISSUE_ST], (instregex "^STF(D|S)U(X)?$")>;
+ def : InstRW<[P8_LS_FX_3C, P8_ISSUE_FXLD], (instrs LQ)>;
----------------
For cracked instructions, should we only use one issue port?
================
Comment at: llvm/lib/Target/PowerPC/PPCScheduleP8.td:171
+ def : InstRW<[P8_LS_FX_3C, P8_ISSUE_FXLD], (instrs LQ)>;
+ def : InstRW<[P8_LU_2C, P8_ISSUE_FXLD], (instregex "^(ADD|SUBF|NEG)(4|8)?_rec$")>;
+ def : InstRW<[P8_LU_FX_5C, P8_ISSUE_LD], (instregex "^LF(D|S)U(X)?$")>;
----------------
ADD_rec/SUBF_rec/NEG_rec seems can use both FXU or LSU?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D154488/new/
https://reviews.llvm.org/D154488
More information about the llvm-commits
mailing list