Navigation Menu

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

clang-cl doesn't accept nested __asm statements #20578

Closed
ehsan opened this issue Jul 4, 2014 · 6 comments
Closed

clang-cl doesn't accept nested __asm statements #20578

ehsan opened this issue Jul 4, 2014 · 6 comments
Assignees
Labels
bugzilla Issues migrated from bugzilla clang Clang issues not falling into any other category

Comments

@ehsan
Copy link
Contributor

ehsan commented Jul 4, 2014

Bugzilla Link 20204
Resolution FIXED
Resolved on Jul 06, 2014 00:28
Version trunk
OS All
CC @majnemer,@zmodem,@jrmuizel,@rnk,@rinon

Extended Description

$ cat test.cpp
void f() {
__asm {
__asm {
mov eax, 1
}
}
}

$ clang-cl -c test.cpp
test.cpp(3,5) : error: unexpected token at start of statement
__asm {
^
1 error generated.

@ehsan
Copy link
Contributor Author

ehsan commented Jul 4, 2014

assigned to @ehsan

@jrmuizel
Copy link

jrmuizel commented Jul 4, 2014

@ehsan
Copy link
Contributor Author

ehsan commented Jul 4, 2014

FWIW, this idiom is used here:
http://dxr.mozilla.org/mozilla-central/source/media/libtheora/lib/x86_vc/
mmxidct.c#131

Among elsewhere in libtheora. This seems to be somewhat popular there.

@ehsan
Copy link
Contributor Author

ehsan commented Jul 4, 2014

And libyuv too.

@ehsan
Copy link
Contributor Author

ehsan commented Jul 5, 2014

Here is a fix: http://reviews.llvm.org/D4399

@ehsan
Copy link
Contributor Author

ehsan commented Jul 6, 2014

Fixed in r212389.

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 9, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla clang Clang issues not falling into any other category
Projects
None yet
Development

No branches or pull requests

2 participants