------- Comment #2 from burnus at gcc dot gnu dot org 2010-08-01 17:28 ------- (In reply to comment #1) > ! --- FOUR ---- (also occurs for Octopus) > c = matmul(b, c)
As pointed out by Dominique, one needs to be careful. I think one can optimize: c = matmul(b, transpose(c)) c = matmul(c,b) where c is a rank-2 matrix. I think one cannot optimize it if c is just a vector. (Add "conj" as you wish.) And check whether I have not confused columns and rows Side remark: sum(array*scalar) = sum(array)*scalar -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45159