title: Using C/inline assembly in C#
body: <p>Is there some method of using C source mixed with inline asm (this is <em>not</em> C++ code) in a C# app?  I'm not picky about how it gets done, if it requires compiling the C/asm into a DLL alongside the C# app, so be it.  I'm aware there's no provision for using assembly inside C#, hence this question.</p>
  
  <p>Sample code of what I'm trying to incorporate:</p>
  
  <pre><code>SomeFunc(unsigned char *outputData, unsigned char *inputData, unsigned long inputDataLength)
  {
      _asm
      {
          //Assembly code that processes inputData and stores result in outputData
      }
  }
  </code></pre>
  
  <p>There are some pointer/variable declarations in the C code before that function is declared, but beyond that it's all inline assembly, the declarations are used in the assembly code if that effects anything.</p>
  
  <p>Objective is to pass 'inputData' from C# and then have access to 'outputData' in the C# program in some fashion.  Normally we'd just rewrite the assembler code in native C# but we're on a tight schedule for getting a prototype together and don't see any reason to reinvent the wheel right away if we can temporarily use the existing C/assembly code in some fashion.</p>