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

split up tests #1868

Closed
wants to merge 6 commits into from
Closed

split up tests #1868

wants to merge 6 commits into from

Conversation

ExpandingMan
Copy link
Contributor

@ExpandingMan ExpandingMan commented Sep 20, 2024

This is a re-do of #1824 for post 0.13.

To reiterate, the goal here is to roughly group the tests by the functionality they are testing and separate them into a large number of files which should be possible to run entirely independently. Again the way I have grouped these tests may not always make a lot of sense, it seems likely they'll get shuffled around more in the future (or before this gets merged) but this seems like a decent start.

There is still a major issue that I've so far been unable to resolve: a setfault in arrays.jl, which I've seen before when trying to split up the tests. It sure looks to me like the fact that it segfaults is an enzyme bug, as I don't see any reason it should do that, especially merely as a result of being in a different file.

As of writing, everything else in here passes as expected for me (x86 linux).

test/arrays.jl Outdated
sc = rand(Float32, 6)
bi = rand(Float32, 6)
#WARN: this is where there is a segfault that I can't figure out
#Enzyme.autodiff(Reverse, bc2_loss_function, Active, Duplicated(x, Enzyme.make_zero(x)),
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have explicitly confirmed that in isolation bc2_loss_fuction works fine on the provided arguments, but this autodiff segfaults. Becoming more confident this is an enzyme bug. Not sure what was preventing it from segfaulting before this PR.

@wsmoses
Copy link
Member

wsmoses commented Sep 20, 2024

open a mwe issue for each of these?

@ExpandingMan
Copy link
Contributor Author

#1869 and #1870

(the former is clearly a real bug, the latter is just confusing error messages and probably not a bug)

@wsmoses
Copy link
Member

wsmoses commented Sep 23, 2024

I think we need to fix the segfault before this goes in.

Unfortunately I can't reproduce locally. Can you setup a tmate instance with it on it or something, and send me via slack

@ExpandingMan
Copy link
Contributor Author

Ok. I don't think I've ever let the segfaulting test run in CI/CD, let's see what that does first, I've just uncommented it.

@wsmoses
Copy link
Member

wsmoses commented Sep 24, 2024

@ExpandingMan given tests constantly going in an out, I think this is probably too invasive/difficult to do in one go.

Can you do this as PR's with one file move at a time? [that way the conflicts are less likely and it'll be easier to review and confirm]

@wsmoses wsmoses closed this Sep 24, 2024
@ExpandingMan
Copy link
Contributor Author

Frankly that could take forever, there is quite a lot of stuff to get split up. I'd like to get it in, but if you think it's going to be that difficult, I'll leave it to you (if this is indeed something you feel is worth doing). Even if I did this piecemeal I wouldn't know when to do what.

@wsmoses
Copy link
Member

wsmoses commented Sep 24, 2024

maybe do like 3-4 in a first pass (and move out utils)?

@ExpandingMan
Copy link
Contributor Author

Could we maybe just try to keep track of which tests are added between the PR going up and it being merged? Would it really be that hard?

@wsmoses
Copy link
Member

wsmoses commented Sep 29, 2024

I mean sure if you want, but also bear in mind that moving everything together means it'll take longer to review.....which means another test PR might get in before then....necessitating another review...

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