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

[REQUEST] Support executing Windows binaries #1879

Closed
phuclv90 opened this issue Mar 7, 2020 · 13 comments
Closed

[REQUEST] Support executing Windows binaries #1879

phuclv90 opened this issue Mar 7, 2020 · 13 comments
Labels
MS/Windows Microsoft or Windows specific issues request Request for something

Comments

@phuclv90
Copy link
Contributor

phuclv90 commented Mar 7, 2020

CE has wine to run cl.exe, so it should also be possible to run Windows executables after compiling

This will also help running C++/CLI binaries after installing .NET Core or mono. Currently there are very few places that you can try C++/CLI code online

@phuclv90 phuclv90 added the request Request for something label Mar 7, 2020
@apmorton
Copy link
Member

apmorton commented Mar 7, 2020

The wine compilers don't even currently support linking (I have never looked into this myself, but I am told there are some non-trivial issues there).

In addition, with our current sandboxing setup all wine compilers run in a single shared sandbox due to complexities of wine.

Enabling user code execution in that environment is a non-starter - there is simply no way we could make it secure enough to prevent malicious abuse.

For this to be a reality we would need to make some pretty dramatic changes in how we sandbox wine processes, and solve some difficult performance problems with cold-booting a wine complex for every user execution.

TL;DR; Never say never, but I don't think its feasible with the current reality of how wine works on CE.

@mattgodbolt mattgodbolt added the MS/Windows Microsoft or Windows specific issues label Mar 11, 2020
@mattgodbolt
Copy link
Member

Agreed with wine here. There would need to be a first-class Windows sandbox support from Microsoft for this. (CC @strega-nil in case she has any commentary)

@phuclv90
Copy link
Contributor Author

Does CE have any Windows instances? Windows have sandbox feature from build 1903 which may help

@strega-nil
Copy link

This is not currently a feature that has had enough ask from our community to allocate the necessary engineer time and political capital to get it working; continue upvoting https://developercommunity.visualstudio.com/idea/663829/allow-code-execution-on-godboltorg-for-msvc-compil.html :)

@mattgodbolt
Copy link
Member

Thanks @strega-nil :)

@partouf
Copy link
Contributor

partouf commented Jan 14, 2021

This was officially put on the Roadmap last November according to https://developercommunity.visualstudio.com/comments/1252353/view.html

@mattgodbolt
Copy link
Member

Hooray! Will also mention when I next speak with our MS friends.

@noita-player
Copy link

could you just fix the bug where msvc compilers, under output, have "execute the code" checked. it's not clear from the ux that godbolt can't execute windows bins (of course it's clear if you're an expert and understand how it works, but I'm usually linking godbolt to newbies).

leaving it unchecked and still grayed out will also just result in user confusion... "why is this grayed out?" but, I guess, better than the current false implication

@partouf
Copy link
Contributor

partouf commented Aug 13, 2021

could you just fix the bug where msvc compilers, under output, have "execute the code" checked. it's not clear from the ux that godbolt can't execute windows bins (of course it's clear if you're an expert and understand how it works, but I'm usually linking godbolt to newbies).

I'm confused, is it not grayed out?

@RubenRBS
Copy link
Member

I've checked the config for the MSVC compilers and they don't report as being able to execute code. Could you give us a link that shows this?

@timmy-ms
Copy link
Contributor

I am working on enabling this currently, but we have some outstanding questions about a open source tool we need to include.

@timmy-ms timmy-ms closed this as completed Jun 3, 2022
@davispuh
Copy link

This is so confusing, so is this supported or not?

In past it wasn't supported, but then this MS blog says it's supported https://devblogs.microsoft.com/cppblog/execution-and-static-analysis-support-for-msvc-on-compiler-explorer/

But this is what I see

attels

@mattgodbolt
Copy link
Member

This is not currently supported for Microsoft compilers. We do not have a license to run the Microsoft compilers and execution, and so we proxy requests to their infrastructure. For various reasons they had to disable execution support on their side. We are working to try and get a license to run the Microsoft compilers ourselves, at which time we could re-enable execution.

I can't speak for Microsoft's confusing messaging here, unfortunately.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MS/Windows Microsoft or Windows specific issues request Request for something
Projects
None yet
Development

No branches or pull requests

9 participants