Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用 Xdebug 来分析我的 PHP 应用程序。
当我使用 WinCacheGrind 打开生成的配置文件时,{main} 的总累积时间为 3 毫秒(0.003 秒)。
但是,当我在代码末尾使用函数 xdebug_time_index() 时,它返回的时间为 0.03 秒。
任何人都知道可能导致这种差异的原因以及哪个更具代表性?
添加该功能的任何机会实际上会增加所需的时间吗?
此外,我可以想象当 PHP 运行时(时间索引 0),探查器实际上会开始运行,而 XDebug 的内部计数器可以更早地启动。