Skip to content

Fix 5 arg mul! #253

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

Merged
merged 5 commits into from
Mar 19, 2020
Merged

Fix 5 arg mul! #253

merged 5 commits into from
Mar 19, 2020

Conversation

haampie
Copy link
Member

@haampie haampie commented Mar 18, 2020

Move from 3-arg mul to 5-arg mul to make sure GPUArrays's generic mul does not steal from CuArrays.

(Btw, I could not yet test because cyclops was unreachable :( )

@maleadt
Copy link
Member

maleadt commented Mar 19, 2020

Thanks!
bors try

bors bot added a commit that referenced this pull request Mar 19, 2020
@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

try

Build failed

@haampie
Copy link
Member Author

haampie commented Mar 19, 2020

There's still an issue in Julia base to work around...

julia> mul!(rand(Int32, 4), rand(Int32, 4, 4), rand(Int32, 4), Int32(4), Int32(5))
ERROR: InexactError: trunc(Int32, -138749043280184131)

I'll update the tests here s.t. that values don't get extremely high, but I would say ^ is a bug in LinearAlgebra, because it promotes to Int64.

@haampie
Copy link
Member Author

haampie commented Mar 19, 2020

Can you retry?

@maleadt
Copy link
Member

maleadt commented Mar 19, 2020

bors try

bors bot added a commit that referenced this pull request Mar 19, 2020
@maleadt
Copy link
Member

maleadt commented Mar 19, 2020

bors d+

@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

✌️ haampie can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

try

Build failed

@haampie haampie force-pushed the fix-5-arg-mul! branch 2 times, most recently from 7a8cc3b to 64f4a1d Compare March 19, 2020 09:48
@haampie
Copy link
Member Author

haampie commented Mar 19, 2020

Oh sorry :/ I've tried it locally

Test Summary: | Pass  Total
JLArray       | 1116   1116

Final request to retry? 😅

@maleadt
Copy link
Member

maleadt commented Mar 19, 2020

After the bors d+ you can do it yourself:
bors try

bors bot added a commit that referenced this pull request Mar 19, 2020
@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

try

Build failed

@haampie
Copy link
Member Author

haampie commented Mar 19, 2020

travis timed out

bors try

bors bot added a commit that referenced this pull request Mar 19, 2020
@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

try

Build succeeded

@haampie
Copy link
Member Author

haampie commented Mar 19, 2020

bors r+

@bors
Copy link
Contributor

bors bot commented Mar 19, 2020

@bors bors bot merged commit b1be744 into JuliaGPU:master Mar 19, 2020
@haampie haampie deleted the fix-5-arg-mul! branch March 19, 2020 11:46
bors bot added a commit to JuliaGPU/CuArrays.jl that referenced this pull request Mar 19, 2020
641: 5-arg mul! with 3-arg mul! support r=maleadt a=haampie

Turns out I was not right about that static if for julia 1.3.0 (the relevant commit in base was merged before the release of 1.3.1, but only made its way into julia from 1.4.0-rc1).

Otherwise this should work after JuliaGPU/GPUArrays.jl#253 is merged, because GPUArrays is stealing 3-arg mul! from CuArrays at the moment.

Co-authored-by: Harmen Stoppels <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants