| Summary: | mins/maxs with (RB|0) or (RA|0) option? | ||
|---|---|---|---|
| Product: | Libre-SOC's first SoC | Reporter: | Luke Kenneth Casson Leighton <lkcl> |
| Component: | Specification | Assignee: | Jacob Lifshay <programmerjake> |
| Status: | RESOLVED FIXED | ||
| Severity: | enhancement | CC: | ghostmansd, libre-soc-isa, programmerjake |
| Priority: | --- | ||
| Version: | unspecified | ||
| Hardware: | Other | ||
| OS: | Linux | ||
| URL: | https://libre-soc.org/openpower/sv/av_opcodes/ | ||
| See Also: |
https://bugs.libre-soc.org/show_bug.cgi?id=794 https://bugs.libre-soc.org/show_bug.cgi?id=863 https://bugs.libre-soc.org/show_bug.cgi?id=234 https://bugs.libre-soc.org/show_bug.cgi?id=915 https://bugs.libre-soc.org/show_bug.cgi?id=676 https://bugs.libre-soc.org/show_bug.cgi?id=1057 |
||
| NLnet milestone: | --- | total budget (EUR) for completion of task and all subtasks: | 0 |
| budget (EUR) for this task, excluding subtasks' budget: | 0 | parent task for budget allocation: | |
| child tasks for budget allocation: | The table of payments (in EUR) for this task; TOML format: | ||
| Bug Depends on: | |||
| Bug Blocks: | 952, 1057 | ||
|
Description
Luke Kenneth Casson Leighton
2022-08-24 14:45:29 BST
https://git.libre-soc.org/?p=libreriscv.git;a=commitdiff;h=8e385d96fa576825af8111a3057ab39cfd34dd31 commit 8e385d96fa576825af8111a3057ab39cfd34dd31 Author: Jacob Lifshay <programmerjake@gmail.com> Date: Thu Apr 20 17:45:05 2023 -0700 change integer min/max to use (RA|0) I still need to change the simulator this was added to the simulator in https://bugs.libre-soc.org/show_bug.cgi?id=1057#c24 https://git.libre-soc.org/?p=openpower-isa.git;a=commitdiff;h=e3b46c6ec7911d08b8b0c4cb3c286c3786dae2ef I assume this again needs binutils update, since they do different RA vs (RA|0). (In reply to Dmitry Selyutin from comment #3) > I assume this again needs binutils update, since they do different RA vs > (RA|0). this should have been done as part of adding minmax instead of mins/maxs/minu/maxu I think I know the reason We don't actually distinguish RA and RA0 in the codegen. There might be more places where we have this problem. So this is a common problem related to sv_binutils.py. I'll revisit all instructions we added and check for RA0 operand. It seems that minmax does not have its RA operand described as RA_OR_ZERO, therefore current binutils definition matches what we have at repo. I pushed a branch minmax_ra0 branch to openpower-isa with the relevant changes, and wait for CI to complete. That said, I rechecked all instructions we have in binutils, and it seems that setvl must be fixed: it should have RA0 operand in binutils instead of RA. For the record, the count of instructions we support is 295. I counted instructions marked as SFFS, but these are the only ones we have now. 1. openpower-isa was updated with RA_OR_ZERO for minmax instruction. 2. binutils were updated with RA0 for minmax and its aliases. 3. In scope of this task, I rechecked all instructions we added into binutils, and found that setvl must also have RA0 operand, so I updated it respectively. https://git.libre-soc.org/?p=openpower-isa.git;a=commitdiff;h=6626fc852a2a18c85cdf8b621f7307dc1d35a25b https://git.libre-soc.org/?p=binutils-gdb.git;a=commitdiff;h=60b205de34383d8e315b2b54b7723da084b4a59f |