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

{ai}[foss/2023a] tinygrad v0.8.0 w/ CUDA 12.1.1 #20339

Draft
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

@VRehnberg VRehnberg marked this pull request as draft April 11, 2024 11:25
@VRehnberg
Copy link
Contributor Author

Test report by @VRehnberg
FAILED
Build succeeded for 0 out of 1 (1 easyconfigs in total)
alvis1-03 - Linux Rocky Linux 8.9, x86_64, Intel(R) Xeon(R) Gold 6244 CPU @ 3.60GHz, 1 x NVIDIA Tesla V100-SXM2-32GB, 550.54.14, Python 3.6.8
See https://gist.github.com/VRehnberg/f19c66d9244dc4fedc21af02b3694a56 for a full test report.

@VRehnberg
Copy link
Contributor Author

FAILED test/test_dtype.py::TestHalfDtype::test_casts_from - RuntimeError: compile failed: (14): error: more than one conversion function from "half" to "char" applies:
FAILED test/test_dtype.py::TestHalfDtype::test_casts_to - RuntimeError: compile failed: (14): error: more than one constructor applies to convert from "long" to "__half":
FAILED test/test_dtype.py::TestHalfDtype::test_upcast_ops - RuntimeError: compile failed: (15): error: more than one constructor applies to convert from "long" to "__half":
FAILED test/test_dtype.py::TestInt8Dtype::test_casts_to - RuntimeError: compile failed: (14): error: more than one conversion function from "half" to "char" applies:
FAILED test/test_dtype.py::TestInt8Dtype::test_upcast_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype.py::TestUint8Dtype::test_casts_to - RuntimeError: compile failed: (14): error: more than one conversion function from "half" to "unsigned char" applies:
FAILED test/test_dtype.py::TestInt16Dtype::test_upcast_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype.py::TestInt32Dtype::test_upcast_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype.py::TestInt64Dtype::test_casts_from - RuntimeError: compile failed: (14): error: more than one constructor applies to convert from "long" to "__half":
FAILED test/test_dtype.py::TestInt64Dtype::test_casts_to - RuntimeError: compile failed: (14): error: more than one conversion function from "half" to "long" applies:
FAILED test/test_dtype.py::TestInt64Dtype::test_same_size_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "long" to "__half":
FAILED test/test_dtype.py::TestInt64Dtype::test_upcast_to_ops - RuntimeError: compile failed: (15): error: more than one constructor applies to convert from "long" to "__half":
FAILED test/test_dtype.py::TestUint64Dtype::test_casts_from - RuntimeError: compile failed: (14): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype.py::TestUint64Dtype::test_casts_to - RuntimeError: compile failed: (14): error: more than one conversion function from "half" to "unsigned long" applies:
FAILED test/test_dtype.py::TestUint64Dtype::test_same_size_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype.py::TestUint64Dtype::test_upcast_to_ops - RuntimeError: compile failed: (18): error: more than one constructor applies to convert from "unsigned long" to "__half":
FAILED test/test_dtype_alu.py::TestDTypeALU::test_float_midcast_int32 - AssertionError:
FAILED test/test_linearizer_failures.py::TestLinearizerFailures::test_failure_8 - AssertionError: assert 'COMPILE_ERROR' == 'PASS'
FAILED test/extra/test_export_model.py::TextModelExport::test_multi_output_model_export - AttributeError: 'CUDAGraph' object has no attribute 'prg'
FAILED test/models/test_real_world.py::TestRealWorld::test_gpt2 - AssertionError: only 8 out of 468 were jitted
FAILED test/models/test_real_world.py::TestRealWorld::test_llama - AssertionError: only 12 out of 719 were jitted

I don't know what error: more than one constructor applies to convert from ... means. Before I patched the error was that cuda_fp16.h couldn't be found.

@VRehnberg
Copy link
Contributor Author

I believe a pip install in a virtualenv --system-site-packages didn't have this issue so I suppose I just have to diff the results until I find something I can patch.

@migueldiascosta migueldiascosta added this to the 4.x milestone Apr 16, 2024
@VRehnberg
Copy link
Contributor Author

I believe a pip install in a virtualenv --system-site-packages didn't have this issue so I suppose I just have to diff the results until I find something I can patch.

I've been able to replicate the issue with pip installed tinygrad. Not sure what was different before.

@VRehnberg
Copy link
Contributor Author

Forcing Clang CLANG=1 python test/test_dtype.py solves this issue (but I suspect it will have performance drawbacks). Micket helped me by pointing out that this the errors probably are due to long being underdetermined (and probably same issue for char then). I haven't found where long and char are specified.

@VRehnberg
Copy link
Contributor Author

So here is where the dtypes are defined https://github.com/tinygrad/tinygrad/blob/v0.8.0/tinygrad/dtype.py#L51-L64 now the remaining issue what to replace char with. There's no int8_t to replace it with. unsigned char -> uint8_t and long -> long long seems to have gone fine.

@VRehnberg
Copy link
Contributor Author

Test report by @VRehnberg
FAILED
Build succeeded for 0 out of 1 (1 easyconfigs in total)
alvis1-05 - Linux Rocky Linux 8.9, x86_64, Intel(R) Xeon(R) Gold 6244 CPU @ 3.60GHz, 1 x NVIDIA Tesla V100-SXM2-32GB, 550.54.14, Python 3.6.8
See https://gist.github.com/VRehnberg/59824f85ce3d224c10edde5196b19b7f for a full test report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants