Skip to content

Using LoopVectorization to compute the commutator of two Hermitian matrices #184

Answered by chriselrod
christian-hh asked this question in Q&A
Discussion options

You must be logged in to vote

one could imagine simply changing the indexing on j to start at i rather than 1, i.e., j ∈ i:size(B,2) in the second line. This clearly breaks the assumptions of @avx in that the order of indexing matters, of course.

I have been planning on adding support for this for a while. I think I've figured out a lot of the details. Hopefully fairly soon I'll start at least dedicating a few hours every night to making progress here.

and/or potentially calculates both of the products H * rho and rho * H in a single pass.

This would probably be difficult to make optimal, because in A * B, it is normally optimal to load vectors from A and scalars from B.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@christian-hh
Comment options

@chriselrod
Comment options

Answer selected by christian-hh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants