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

BLAS.syr! incorrect when argument is SubArray #18908

Closed
joshday opened this issue Oct 13, 2016 · 1 comment
Closed

BLAS.syr! incorrect when argument is SubArray #18908

joshday opened this issue Oct 13, 2016 · 1 comment
Assignees
Labels
domain:linear algebra Linear algebra kind:bug Indicates an unexpected problem or unintended behavior

Comments

@joshday
Copy link

joshday commented Oct 13, 2016

BLAS.syr! is incorrect when the vector argument is a view. The first element is correct, but the others are off. Here is a minimal example:

a1 = zeros(2, 2); a2 = zeros(2, 2); x = randn(5, 2);

x[1, :] * x[1,:]'
#2×2 Array{Float64,2}:
#1.80996   0.192666
#0.192666  0.0205089

BLAS.syr!('U', 1.0, x[1, :], a1)
#2×2 Array{Float64,2}:
#1.80996  0.192666
#0.0      0.0205089

BLAS.syr!('U', 1.0, view(x,1,:), a2)
#2×2 Array{Float64,2}:
#1.80996  -0.0177593
#0.0       0.000174254

And my version info:

julia> versioninfo()
Julia Version 0.5.1-pre+2
Commit f0d40ec (2016-09-20 03:34 UTC)
Platform Info:
  System: Darwin (x86_64-apple-darwin15.6.0)
  CPU: Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.7.1 (ORCJIT, has well)
@andreasnoack andreasnoack added domain:linear algebra Linear algebra kind:bug Indicates an unexpected problem or unintended behavior labels Oct 13, 2016
@andreasnoack andreasnoack self-assigned this Oct 13, 2016
@timholy
Copy link
Sponsor Member

timholy commented Oct 13, 2016

See #15308

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:linear algebra Linear algebra kind:bug Indicates an unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

3 participants