Using SSE in c# is it possible?

后端 未结 10 1959
借酒劲吻你
借酒劲吻你 2020-11-29 11:02

I was reading a question about c# code optimization and one solution was to use c++ with SSE. Is it possible to do SSE directly from a c# program?

10条回答
  •  暗喜
    暗喜 (楼主)
    2020-11-29 11:50

    Can C# explicitly make an SSE call?

    No. C# cannot produce inline IL much less inline x86/amd64 assembly.

    The CLR, and more specifically the JIT, will use SSE if it's available removing the need to force it in most circumstances. I say most because I'm not an SSE expert and I'm sure that there are cases where it could be beneficial and the JIT does not make the optimization.

提交回复
热议问题