Skip to content

'Invalid output constraint diagnistic' is duplicated for sycl devices code #1453

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

Closed
vladimirlaz opened this issue Apr 1, 2020 · 3 comments
Closed
Assignees

Comments

@vladimirlaz
Copy link
Contributor

vladimirlaz commented Apr 1, 2020

Diagnostic is duplicated after LLVM pulldown for kernel definition and kernel call.
See example below for clang/test/SemaSYCL/inline-asm.cpp LIT test.

Corresponding LIT test has been XFAILed (a28778c) to unblock pulldown

/build/bin/clang -cc1 -internal-isystem /build/lib/clang/11.0.0/include -nostdsysteminc -fsycl -fsycl-is-device -fsyntax-only /llvm_src/clang/test/SemaSYCL/inline-asm.cpp -DLINUX_ASM -DSPIR_CHECK -triple spir64-unknown-unknown-sycldevice
/llvm_src/clang/test/SemaSYCL/inline-asm.cpp:30:13: error: invalid output constraint '=a' in asm
          : "=a"(__result), "=b"(__d[0]), "=c"(__d[1]), "=d"(__d[2])
            ^
/llvm_src/clang/test/SemaSYCL/inline-asm.cpp:65:3: note: called by 'kernel_single_task'
  asm_func_2(i, d);
  ^
/llvm_src/clang/test/SemaSYCL/inline-asm.cpp:30:13: error: invalid output constraint '=a' in asm
          : "=a"(__result), "=b"(__d[0]), "=c"(__d[1]), "=d"(__d[2])
            ^
/llvm_src/clang/test/SemaSYCL/inline-asm.cpp:65:3: note: called by 'kernel_single_task<fake_kernel, (lambda at /llvm_src/clang/test/SemaSYCL/inline-asm.cpp:74:41)>'
  asm_func_2(i, d);
  ^
2 errors generated.
@vladimirlaz
Copy link
Contributor Author

@premanandrao, could you please have a look?

@premanandrao premanandrao self-assigned this Apr 1, 2020
@premanandrao
Copy link
Contributor

@AlexeySachkov
Copy link
Contributor

It looks like the test was re-enabled (with some changes) in #1460 and the implementation was further improved in #5195 to avoid emitting duplicated diagnostics at all, closing this one.

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

No branches or pull requests

3 participants