Skip to content
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

[RISCV] Support scheduling VCIX instructions #83427

Closed
wants to merge 1 commit into from

Conversation

wangpc-pp
Copy link
Contributor

@wangpc-pp wangpc-pp commented Feb 29, 2024

If we don't do anything, the latencies of VCIX instructions will be
all 1.

Here I just set the latency to a very large number, so the scheduler
will treat them costly.

Though I still don't know why scheduler doesn't take register pressure
into consideration.

Fixes #83391

If we don't do anything, the latencies of VCIX instructions will be
all 1.

Here I just set the latency to a very large number, so the scheduler
will treat them costly.

Though I still don't know why scheduler doesn't take register presure
into consideration.
@topperc
Copy link
Collaborator

topperc commented Feb 29, 2024

I think the cycle simulation in the scheduler is keeping the loads in the pending queue instead of the available queue so they aren't in consideration for scheduling. So they aren't available as choices to reduce register pressure.

At the very least all of the VCIX instructions need to go through VCQ and occupy the arithmetic sequencer for VLEN*LMUL/DLEN cycles.

@michaelmaitland
Copy link
Contributor

Should we add a test case?

@wangpc-pp
Copy link
Contributor Author

At the very least all of the VCIX instructions need to go through VCQ and occupy the arithmetic sequencer for VLEN*LMUL/DLEN cycles.

Yeah you are right. And it depends on the implementation of co-processor, so it's really hard to model it staticly in schedule model.

Should we add a test case?

The test should be reduced, it's too large.


I just provided a thought/way to fix (temporarily?) the problem, please feel free to create thorough fix as I don't really know the details about x280's microarchitecture.

@wangpc-pp
Copy link
Contributor Author

Prefer to #86093.

@wangpc-pp wangpc-pp closed this Mar 21, 2024
@wangpc-pp wangpc-pp deleted the main-vcix-sched branch March 21, 2024 06:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RVV spilling when using VCIX instructions with -mtune=sifive-x280
3 participants