Open certik opened 1 year ago
Same error for:
associate ( &
q => x2((1-1)*n_embd+1:1*n_embd,:), &
k => x2((2-1)*n_embd+1:2*n_embd,:), &
v => x2((3-1)*n_embd+1:3*n_embd,:) &
)
if (use_kv_cache) then
kv_cache(:,n_seq,1) = k(:,1)
kv_cache(:,n_seq,2) = v(:,1)
else
kv_cache(:,:,1) = k
kv_cache(:,:,2) = v
end if
end associate
Minimal example:
program test
implicit none
integer :: x(2)
integer :: i, j
x = 123
associate(a=>x(:))
print *, a
end associate
end program test
I think we have to handle this: https://github.com/lcompilers/lpython/issues/1599#issuecomment-1621157646 to fix this issue.
gives: