0

假设我有这个:

extern "C" {
void foo1();
void foo2();
};
void foo1() 
{
__asm
    {
       ; some stuff

       ; some other 
    }
}

  void foo2() 
  {
    __asm 
        {
              ;some other stuff
              call __foo1

        }
  }

我知道在常规的 .asm 程序中你会被要求说 extrn __fucntionName,但这是内联汇编,可以在内联汇编中这样调用用户定义的函数吗?如何?我用的是VS2008。

4

1 回答 1

0

可以从汇编程序调用 C 函数。此调用的语法取决于您使用的编译器。通常,函数名称在汇编中的外观会有所不同,反之亦然。

于 2012-08-10T11:01:41.223 回答