-
-
Notifications
You must be signed in to change notification settings - Fork 262
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
Generate GCC builtins for NVPTX target. #2556
base: master
Are you sure you want to change the base?
Conversation
Nice. |
The generated file will have to be marked |
Good hint! This requires an update to the gen_gccbuiltins tool, too. Currently, the intrinsics are only generated. There is no clustering. Maybe we could just public import the intrinsics in the right module? |
That works too. |
cf52ab8
to
49bb50c
Compare
Updated the gen_gccbuiltins with a small hack. |
utils/gen_gccbuiltins.cpp
Outdated
os << "; \n\nimport core.simd;\n\nnothrow @nogc:\n\n"; | ||
os << arch << "; \n\n"; | ||
if (isDcomputeOnly) | ||
os << "ldc.dcompute;\n"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're missing an import
that should precede that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a testcase for this @redstar ? It would catch bugs like this.
(you can use // REQUIRES: target_NVPTX
to filter)
DCompute targets NVPTX, so we should generate the GCC builtins. The gen_gccbuiltins utility must be extended for this special case, too.
49bb50c
to
8ab6b85
Compare
@JohanEngelen: tests/fuzz_basic.d finally failed again here; output:
|
@thewilsonator Can you add a testcase for this? ( |
See #3993 |
DCompute targets NVPTX, so we should generate the GCC builtins.