为用户应用程序定义的探测打印DTrace脚本中的双精度
我正试图在DTrace脚本中从。探头的定义如下:为用户应用程序定义的探测打印DTrace脚本中的双精度,c,macos,dtrace,C,Macos,Dtrace,我正试图在DTrace脚本中从。探头的定义如下: /** * Fired when the garbage collection threshold is changed with a certain factor * @param factor the factor with which the GC threshold is changed */ probe gc__threshold(double factor); 在我的脚本中,我试图打印参数,如下所示: pony$target:
/**
* Fired when the garbage collection threshold is changed with a certain factor
* @param factor the factor with which the GC threshold is changed
*/
probe gc__threshold(double factor);
在我的脚本中,我试图打印参数,如下所示:
pony$target:::gc-threshold
{
print(args[0]);
}
但是,它给了我以下错误:
dtrace: failed to compile script ./test.d: line 7: translator for args[0] from double to double is not defined
我正在Mac上运行脚本。由于缺乏文档,在互联网上也没有类似的问题,我很难找到解决这个问题的线索
我也尝试过使用浮点和长双精度,但同样的错误也发生了