-
Notifications
You must be signed in to change notification settings - Fork 15
Upstream ARC-V RMX-100 #171
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
base: trunk
Are you sure you want to change the base?
Conversation
This commit introduces a new -mtune=rmx100 tuning option together with relevant scheduler definitions. Instruction latencies and costs are based on the "RMX-100 Technical Reference Manual" document (revision 0.4, 13 September 2023) and are subject to change. The changes have been verified by running the Dhrystone and Coremark benchmarks and observing expected (small) improvements compared to the -mtune=generic results. Signed-off-by: Artemiy Volkov <[email protected]>
This commit adds the new arcv-mpy-option compilation parameter with the valid (string) values of 1c, 2c, and 10c. This corresponds to different versions of the MPY/DIV unit of the RMX100 core, each of which has different latencies for imul/idiv instructions. Internally, this option is propagated to the pipeline description information in rmx100.md with the use of new helper functions defined in riscv.cc. Signed-off-by: Artemiy Volkov <[email protected]>
Since it is critical to scheduling for the RMX-100 core, allow setting load latency via a newly create target-specific arcv-ld-cycles parameter. The worst case latency is 3, and so is the parameter's default value. Signed-off-by: Artemiy Volkov <[email protected]>
0efc8b2
to
2fa36eb
Compare
|
||
-param=arcv-mpy-option= | ||
Target RejectNegative Joined Enum(arcv_mpy_option) Var(arcv_mpy_option) Init(ARCV_MPY_OPTION_2C) | ||
The type of MPY unit used by the RMX-100 core (to be used in combination with -mtune=rmx100) (default: 2c). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FIXME
} | ||
|
||
/* Implement one boolean function for each of the values of the | ||
arcv_mpy_option enum, for the needs of rhx100.md. */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FIXME
(define_automaton "arcv_rmx100") | ||
|
||
(define_cpu_unit "arcv_rmx100_ALU" "arcv_rmx100") | ||
;(define_cpu_unit "arcv_rmx100_CSR" "arcv_rmx100") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FIXME
;;(define_insn_reservation "core" 1 | ||
;; (eq_attr "type" "block, brk, dmb, flag, lr, sr, sync") | ||
;; "arcv_rmx100_ALU0 + arcv_rmx100_ALU1 + arcv_rmx100_DMP + arcv_rmx100_MPY + arcv_rmx100_MPY64 + arcv_rmx100_DIV") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FIXME
The purpose of the PR is solely to review the patch set that will be submitted to upstream.