Inline assembly and CTFE

David Nadlinger code at klickverbot.at
Thu Oct 3 15:30:22 PDT 2013


On Thursday, 3 October 2013 at 22:25:27 UTC, Joseph Cassman wrote:
> Are there plans to eventually support the use of asm blocks in 
> CTFE?

No.

> Any ideas on how to implement isAVXPossible() and its related 
> functionality without using a runtime test are appreciated.

What would you even want the function to return in the first 
place? The CPU features you can use obviously depend on the 
specific CPU the executable will run on, so the answer can't 
generally by known at compile time.

Do you want to base your decision on the CPU of the build host? 
Or are you looking for an efficient way to implement the runtime 
check?

David


More information about the Digitalmars-d mailing list