{"action":"opened","issue":{"url":"https://api.github.com/repos/JuliaLang/julia/issues/22242","repository_url":"https://api.github.com/repos/JuliaLang/julia","labels_url":"https://api.github.com/repos/JuliaLang/julia/issues/22242/labels{/name}","comments_url":"https://api.github.com/repos/JuliaLang/julia/issues/22242/comments","events_url":"https://api.github.com/repos/JuliaLang/julia/issues/22242/events","html_url":"https://github.com/JuliaLang/julia/issues/22242","id":233873256,"number":22242,"title":"gelsd! and gelsy! don't do what their documentation says","user":{"login":"tkoolen","id":2585880,"avatar_url":"https://avatars3.githubusercontent.com/u/2585880?v=3","gravatar_id":"","url":"https://api.github.com/users/tkoolen","html_url":"https://github.com/tkoolen","followers_url":"https://api.github.com/users/tkoolen/followers","following_url":"https://api.github.com/users/tkoolen/following{/other_user}","gists_url":"https://api.github.com/users/tkoolen/gists{/gist_id}","starred_url":"https://api.github.com/users/tkoolen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tkoolen/subscriptions","organizations_url":"https://api.github.com/users/tkoolen/orgs","repos_url":"https://api.github.com/users/tkoolen/repos","events_url":"https://api.github.com/users/tkoolen/events{/privacy}","received_events_url":"https://api.github.com/users/tkoolen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-06-06T12:19:23Z","updated_at":"2017-06-06T12:19:23Z","closed_at":null,"body":"Consider the following code:\r\n```julia\r\nA = rand(3, 3)\r\nb = rand(3)\r\nx1 = A \\ b\r\nx2 = copy(b)\r\nx3, r = LinAlg.LAPACK.gelsd!(A, x2, 0.)\r\n```\r\nAccording to [the `gelsd!` documentation](https://docs.julialang.org/en/stable/stdlib/linalg/?highlight=ldlt#Base.LinAlg.LAPACK.gelsd!), `x2` should be overwritten by the solution, so I would expect that `x1`, `x2`, and `x3` are all the same. However, we only have `isapprox(x1, x3)`; `x2` is still equal to `b` after the call to `gelsd!`.\r\n\r\nThe same is true for `gelsy!`.\r\n\r\nImportantly, this implies that the result vector is being allocated inside of `gelsd!` and `gelsy!`, which is what I'm trying to prevent by calling these functions."}}
{"actor":{"display_login":"tkoolen"}}