rust icon indicating copy to clipboard operation
rust copied to clipboard

Support Windows/macOS

Open motabbara opened this issue 1 year ago • 5 comments

For this to work I also had to modify Enzyme CMakeLists.txt

Not sure whether these make sense so I guess this is more of a draft PR

CMakeLists.txt

motabbara avatar Feb 07 '24 06:02 motabbara

Thanks a lot! I looked through your CMakeList.txt changes and created this patch, can you make a PR for Enzyme core out of it? (I didn't had your gh email, so I couldn't commit in your name) patch.diff.txt Once that is merged I'll update the Enzyme submodule and merge this pr here.

Also, do you know what happened to your cargo.lock? It is ~7 times the original size, did you maybe run x or x.py from that folder? I am not sure why it would otherwise change so much.

Final question, on which systems could you test this? We hope to add CI soonish, but I didn't got to it yet, so only some Linux versions are really tested. Something like this should print it: rustc -Z unstable-options --print target-spec-json | grep llvm-target

ZuseZ4 avatar Feb 07 '24 06:02 ZuseZ4

Also @motabbara, if you are currently free, we are discussing that in our weekly open Enzyme call at https://mit.zoom.us/j/96000853439

ZuseZ4 avatar Feb 07 '24 21:02 ZuseZ4

Are the Cargo.lock changes important/significant?

@ZuseZ4 Do you want to merge this into macro2 instead?

I'll put it into macro2 and remove the lock file noise.

motabbara avatar Feb 08 '24 02:02 motabbara

Thanks a lot! I looked through your CMakeList.txt changes and created this patch, can you make a PR for Enzyme core out of it? (I didn't had your gh email, so I couldn't commit in your name) patch.diff.txt Once that is merged I'll update the Enzyme submodule and merge this pr here.

Also, do you know what happened to your cargo.lock? It is ~7 times the original size, did you maybe run x or x.py from that folder? I am not sure why it would otherwise change so much.

Final question, on which systems could you test this? We hope to add CI soonish, but I didn't got to it yet, so only some Linux versions are really tested. Something like this should print it: rustc -Z unstable-options --print target-spec-json | grep llvm-target

"llvm-target": "arm64-apple-macosx11.0.0",

motabbara avatar Feb 08 '24 03:02 motabbara

@motabbara, I went ahead and created a similar PR to Enzyme, since I just tried to rebuild rust-enzyme and ended up with similar errors. I additionally to your patch also had to update the BCLoader CMakeLists, and I didn't needed your Mac specific changes, so I left these for you.

ZuseZ4 avatar Feb 09 '24 04:02 ZuseZ4