| Files | Last commit | Last update |
|---|---|---|
fix(machine): Fix missing unit issue. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5489 merge machine_format into master fix(machine): Fix missing unit issue. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 修复日志中单位的缺失,使日志信息更便于阅读 See merge request: cann/pypto!5489 | 3 months ago | |
feat(machine): Migrate aicore print to host-side management for capture Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5216 merge feat/aicore-print-host-mgr into master feat(machine): Migrate aicore print to host-side management for capture Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: feat(machine): Migrate aicore print to host-side management for capture The aicore print log mechanism was managed on the device side (AICPU) via AicoreLogManager, which reads logs synchronously inside AiCoreManager::RunTask. This breaks Stream recording semantics in capture (aclgraph) mode and couples print buffer management with scheduling logic. This PR moves aicore print buffer management to the host side. Changes: - Add AicorePrintHostManager: host allocates per-core HBM ring buffers, injects addresses into shakeBuffer[5] via H2D, and D2H-copies + decodes TLV records to host log after task sync - Integrate AicorePrintHostManager into DeviceRunner; skip sync and dump in capture mode to preserve recording - Skip debug sync and data-dump sync in DeviceLauncher when in capture mode - Remove device-side AicoreLogManager, InitLogger/DumpAicoreLog/logger_ from AiCoreManager, and shakeBuffer write from AiCoreHal - Add Newline record type and EncodeNewline for per-log separation; support BindHostBuffer/GetConsumedTail for host-side decoding in AicoreLogger Related Issues: #2846 See merge request: cann/pypto!5216 | 3 months ago | |
feat(machine): Add log level control and timestamp to aicore print Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5352 merge feat/aicore-log-level-control into master feat(machine): Add log level control and timestamp to aicore print Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: ## 关联 Issue Closes #2915 ## 改动说明 为 AICore Print 系统添加日志级别控制、时间戳记录和专用 host 输出宏。 ### 改动内容 1. **日志级别控制** - 新增 AicoreLogLevel 枚举(DEBUG/INFO/WARN/ERROR/NONE) - LogContext 新增 logLevel 字段,由 DevDfxArgs.logLevel(host 侧 dlog_getlevel)传递到 device - AicoreLogger::Init() 接收 level 参数并写入 ctx_.logLevel - 新增 AICORE_LOGD/LOGI/LOGW/LOGE 宏,参照 DEV_INFO/DEV_DEBUG 模式按级别过滤 2. **时间戳记录** - 新增 TimestampMarker TLV 记录类型 - AiCoreLogFWithLevel 中通过 get_sys_cnt() 编码 device 侧周期计数器值 - Host 侧 Read() 解码时间戳并通过 outTimestamp 参数返回 3. **Host 侧专用日志宏** - LogModule 枚举新增 AICORE - 新增 AICORE_HOST_LOGD/LOGI/LOGW/LOGE 宏,不带 host file:line 前缀,使用 device cycle 作为时间戳 - DumpAicoreLog 按级别 switch 调用对应宏 4. **MAX_DIMS 重定义修复** - core_func_data.h 的 MAX_DIMS=8 重命名为 MAX_TENSOR_INFO_DIMS,避免与 layout.h 的 MAX_DIMS=5 冲突 ### 输出格式示例 [core-0][cycle=1234567890][INFO] === After TLoad === [core-0][cycle=1234567895][DEBUG] gmTensor_1 addr=0x... [core-0][cycle=1234567900][INFO] === After TAdd === ### 文件变更 | 文件 | 改动 | |------|------| | aicore_print_base.h | AicoreLogLevel 枚举、LogContext.logLevel、LogLevelMarker/TimestampMarker DataType | | aicore_print_logger.h | Init() 接收 level、EncodeLogLevel/EncodeTimestamp、Read() 返回 level+timestamp | | aicore_print.h | AiCoreLogFWithLevel、AICORE_LOGD/LOGI/LOGW/LOGE 宏 | | aicore_print_host_decode.h | DecodeLogLevelMarker | | aicore_entry.h | KernelEntry 读取 DevDfxArgs.logLevel 传入 InitCtx | | tilefwk_log.h | LogModule 新增 AICORE | | pypto_fwk_log.h | AICORE_HOST_LOGD/LOGI/LOGW/LOGE 宏 | | aicore_print_host_manager.cpp | DumpAicoreLog 按级别+时间戳输出 | | core_func_data.h | MAX_DIMS → MAX_TENSOR_INFO_DIMS | ## 验证方式 1. 设置 ASCEND_GLOBAL_LOG_LEVEL=1(INFO),运行用例,grep "AICORE" ./wk 验证仅 INFO 及以上级别输出 2. 设置 ASCEND_GLOBAL_LOG_LEVEL=0(DEBUG),验证 DEBUG 日志出现 3. 验证每条日志带 [cycle=N] 时间戳 See merge request: cann/pypto!5352 | 3 months ago | |
feat(machine): Migrate aicore print to host-side management for capture Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5216 merge feat/aicore-print-host-mgr into master feat(machine): Migrate aicore print to host-side management for capture Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: feat(machine): Migrate aicore print to host-side management for capture The aicore print log mechanism was managed on the device side (AICPU) via AicoreLogManager, which reads logs synchronously inside AiCoreManager::RunTask. This breaks Stream recording semantics in capture (aclgraph) mode and couples print buffer management with scheduling logic. This PR moves aicore print buffer management to the host side. Changes: - Add AicorePrintHostManager: host allocates per-core HBM ring buffers, injects addresses into shakeBuffer[5] via H2D, and D2H-copies + decodes TLV records to host log after task sync - Integrate AicorePrintHostManager into DeviceRunner; skip sync and dump in capture mode to preserve recording - Skip debug sync and data-dump sync in DeviceLauncher when in capture mode - Remove device-side AicoreLogManager, InitLogger/DumpAicoreLog/logger_ from AiCoreManager, and shakeBuffer write from AiCoreHal - Add Newline record type and EncodeNewline for per-log separation; support BindHostBuffer/GetConsumedTail for host-side decoding in AicoreLogger Related Issues: #2846 See merge request: cann/pypto!5216 | 3 months ago | |
fix(machine): improve log quality in cellmatch code and remove Chinese from test strings. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5565 merge fix_logs into master fix(machine): improve log quality in cellmatch code and remove Chinese from test strings. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 修复cellmatch相关代码中,日志打印错误吗不规范的问题 修复machine 工具组件多处日志中中文字符的问题 See merge request: cann/pypto!5565 | 3 months ago | |
feat(dfx): Refine exception callback Co-authored-by: meiqing2<meiqing2@hisilicon.com> # message auto-generated for no-merge-commit merge: !3727 merge exception into master feat(dfx): Refine exception callback Created-by: meiqing2 Commit-by: meiqing2 Merged-by: cann-robot Description: 背景:device的返回值需要在rt_error_codes.h中定义的错误码范围内,exceptioncallback里才能区别出不同报错场景 1. 避免对cann的依赖,新增device_error_code.h(error_code.h头文件超大),重新集中定义 PYPTO_DEVICE_xx 错误码宏,和rt_error_codes.h保持一致,覆盖 107/207/507 三段。 2. device_utils.h 中 DEVICE_MACHINE_xx 改为引用 PYPTO_DEVICE_xx,消除硬编码值。 3. device_error_tracking 重构:报错打屏格式和PTA/cann error保持一致,GetRetcodeMessage 查表输出错误描述;PyPTOExceptionInfoCallBack 按 expandInfo.type 判断 union 分支,仅 AICore 异常时安全读取 kernelName,其余类型输出 (Null),避免越界脏数据。 4. 超时检测手动trap 5. 后续device新增代码请直接使用 errco_code.h 中的 PYPTO_DEVICE_xx 返回值 6. 进一步优化依赖后续device machine void整改 See merge request: cann/pypto!3727 | 5 months ago | |
feat(dfx): AICERR supports offline loading of binary Co-authored-by: meiqing2<meiqing2@hisilicon.com> # message auto-generated for no-merge-commit merge: !5274 merge aic2 into master feat(dfx): AICERR supports offline loading of binary Created-by: meiqing2 Commit-by: meiqing2 Merged-by: cann-robot Description: 1. CompileAICoreKernel增加 enableSubFunc入参,控制编译NoSubFuncKernel 2. exception dump增加BundledKernel、NoSubFuncBundledKernel 3. debug_aicore_error.py 支持离线加载二进制做单算子复现 4. 增加资料说明 See merge request: cann/pypto!5274 | 3 months ago | |
style(all): Apply additional clang-format corrections across codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4883 merge style-cpp into master style(all): Apply additional clang-format corrections across codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Apply additional clang-format corrections across codebase See merge request: cann/pypto!4883 | 4 months ago | |
refactor(machine): Remove DeviceRunner and redistribute init flow Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5426 merge refactor/remove-device-runner into master refactor(machine): Remove DeviceRunner and redistribute init flow Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: refactor(machine): Remove DeviceRunner and redistribute init flow DeviceRunner was a god-class singleton that mixed device init, HostProf management, DevicePerf management, stream synchronization, and AiCpu .so loading. This PR dissolves it entirely, redistributing each responsibility to its natural module. Changes: - Move init flow (InitDeviceArgs / InitDeviceArgsCore / GetAicoreRegs / InitAiCpuSoBin / SetAiCpuSoOverride) into KernelBinary with static g_deviceArgs + std::call_once guard (EnsureInitialized / InitMetaData / GetEnableDumpDevPref) - Move HostProf methods (SetHostProfFunction / GetHostProfType / ReportHostProfInfo) into HostProf::GetInstance() singleton - Move DevicePerf methods (ResetPerData / SyncProfData / SetDebugEnable) into DevicePerf::GetInstance() singleton - Move DynamicLaunchSynchronize into DeviceLauncher - Move KernelLaunchInfo struct into device_launcher_types.h - Delete device_runner.h and device_runner.cpp - Update all call sites: device_launcher.cpp, kernel_bundle_launch.cpp, pypto_bundle_api.cpp, test_dev_func_runner.h, UT files - Remove device_runner.h from CMakeLists.txt install list Related Issues: #2967 See merge request: cann/pypto!5426 | 3 months ago | |
refactor(machine): Remove DeviceRunner and redistribute init flow Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5426 merge refactor/remove-device-runner into master refactor(machine): Remove DeviceRunner and redistribute init flow Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: refactor(machine): Remove DeviceRunner and redistribute init flow DeviceRunner was a god-class singleton that mixed device init, HostProf management, DevicePerf management, stream synchronization, and AiCpu .so loading. This PR dissolves it entirely, redistributing each responsibility to its natural module. Changes: - Move init flow (InitDeviceArgs / InitDeviceArgsCore / GetAicoreRegs / InitAiCpuSoBin / SetAiCpuSoOverride) into KernelBinary with static g_deviceArgs + std::call_once guard (EnsureInitialized / InitMetaData / GetEnableDumpDevPref) - Move HostProf methods (SetHostProfFunction / GetHostProfType / ReportHostProfInfo) into HostProf::GetInstance() singleton - Move DevicePerf methods (ResetPerData / SyncProfData / SetDebugEnable) into DevicePerf::GetInstance() singleton - Move DynamicLaunchSynchronize into DeviceLauncher - Move KernelLaunchInfo struct into device_launcher_types.h - Delete device_runner.h and device_runner.cpp - Update all call sites: device_launcher.cpp, kernel_bundle_launch.cpp, pypto_bundle_api.cpp, test_dev_func_runner.h, UT files - Remove device_runner.h from CMakeLists.txt install list Related Issues: #2967 See merge request: cann/pypto!5426 | 3 months ago | |
style(all): Apply additional clang-format corrections across codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4883 merge style-cpp into master style(all): Apply additional clang-format corrections across codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Apply additional clang-format corrections across codebase See merge request: cann/pypto!4883 | 4 months ago | |
refactor(machine): Using KernelLaunchInfo and decouple device pref from device runner Co-authored-by: arthur_morgan_hw<lipeijie@huawei.com> # message auto-generated for no-merge-commit merge: !3542 merge br_runtime into master refactor(machine): Using KernelLaunchInfo and decouple device pref from device runner Created-by: arthur_morgan_hw Commit-by: arthur_morgan_hw Merged-by: cann-robot Description: 1、Kernel launch的所需要的可变的入参统一由新增的KernelLaunchInfo承载 2、把device perf相关的逻辑解耦出去 See merge request: cann/pypto!3542 | 5 months ago | |
fix(machine): Fix missing unit issue. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5489 merge machine_format into master fix(machine): Fix missing unit issue. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 修复日志中单位的缺失,使日志信息更便于阅读 See merge request: cann/pypto!5489 | 3 months ago | |
refactor(machine): Remove DeviceRunner and redistribute init flow Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5426 merge refactor/remove-device-runner into master refactor(machine): Remove DeviceRunner and redistribute init flow Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: refactor(machine): Remove DeviceRunner and redistribute init flow DeviceRunner was a god-class singleton that mixed device init, HostProf management, DevicePerf management, stream synchronization, and AiCpu .so loading. This PR dissolves it entirely, redistributing each responsibility to its natural module. Changes: - Move init flow (InitDeviceArgs / InitDeviceArgsCore / GetAicoreRegs / InitAiCpuSoBin / SetAiCpuSoOverride) into KernelBinary with static g_deviceArgs + std::call_once guard (EnsureInitialized / InitMetaData / GetEnableDumpDevPref) - Move HostProf methods (SetHostProfFunction / GetHostProfType / ReportHostProfInfo) into HostProf::GetInstance() singleton - Move DevicePerf methods (ResetPerData / SyncProfData / SetDebugEnable) into DevicePerf::GetInstance() singleton - Move DynamicLaunchSynchronize into DeviceLauncher - Move KernelLaunchInfo struct into device_launcher_types.h - Delete device_runner.h and device_runner.cpp - Update all call sites: device_launcher.cpp, kernel_bundle_launch.cpp, pypto_bundle_api.cpp, test_dev_func_runner.h, UT files - Remove device_runner.h from CMakeLists.txt install list Related Issues: #2967 See merge request: cann/pypto!5426 | 3 months ago | |
fix(machine): Fix error_code in cellmatch. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5582 merge cellmatch_error_code into master fix(machine): Fix error_code in cellmatch. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 修复cellmatch中没有报错误码的问题 See merge request: cann/pypto!5582 | 3 months ago | |
refactor(machine): Remove DeviceRunner and redistribute init flow Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5426 merge refactor/remove-device-runner into master refactor(machine): Remove DeviceRunner and redistribute init flow Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: refactor(machine): Remove DeviceRunner and redistribute init flow DeviceRunner was a god-class singleton that mixed device init, HostProf management, DevicePerf management, stream synchronization, and AiCpu .so loading. This PR dissolves it entirely, redistributing each responsibility to its natural module. Changes: - Move init flow (InitDeviceArgs / InitDeviceArgsCore / GetAicoreRegs / InitAiCpuSoBin / SetAiCpuSoOverride) into KernelBinary with static g_deviceArgs + std::call_once guard (EnsureInitialized / InitMetaData / GetEnableDumpDevPref) - Move HostProf methods (SetHostProfFunction / GetHostProfType / ReportHostProfInfo) into HostProf::GetInstance() singleton - Move DevicePerf methods (ResetPerData / SyncProfData / SetDebugEnable) into DevicePerf::GetInstance() singleton - Move DynamicLaunchSynchronize into DeviceLauncher - Move KernelLaunchInfo struct into device_launcher_types.h - Delete device_runner.h and device_runner.cpp - Update all call sites: device_launcher.cpp, kernel_bundle_launch.cpp, pypto_bundle_api.cpp, test_dev_func_runner.h, UT files - Remove device_runner.h from CMakeLists.txt install list Related Issues: #2967 See merge request: cann/pypto!5426 | 3 months ago | |
feat(machine): Change aicpu kernel launch method Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5045 merge br_aicpuKernelLaunch into master feat(machine): Change aicpu kernel launch method Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: 改变kernel_launch 接口,更换成acl 接口 See merge request: cann/pypto!5045 | 3 months ago | |
feat(machine): Change aicpu kernel launch method Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5045 merge br_aicpuKernelLaunch into master feat(machine): Change aicpu kernel launch method Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: 改变kernel_launch 接口,更换成acl 接口 See merge request: cann/pypto!5045 | 3 months ago | |
style(all): Apply additional clang-format corrections across codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4883 merge style-cpp into master style(all): Apply additional clang-format corrections across codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Apply additional clang-format corrections across codebase See merge request: cann/pypto!4883 | 4 months ago | |
refactor(machine): Reduce private variable of DeviceRunner and decouple runtime agent Co-authored-by: arthur_morgan_hw<lipeijie@huawei.com> # message auto-generated for no-merge-commit merge: !3342 merge br_machine into master refactor(machine): Reduce private variable of DeviceRunner and decouple runtime agent Created-by: arthur_morgan_hw Commit-by: arthur_morgan_hw Merged-by: cann-robot Description: 1、内存相关的操作从runtime agent中抽离出去,只保留对寄存器信息的获取 2、梳理device runner的代码,减少非必要的成员变量 See merge request: cann/pypto!3342 | 6 months ago | |
feat(machine): Change aicpu kernel launch method Co-authored-by: wan_jianfen<wanjianfen@hisilicon.com> # message auto-generated for no-merge-commit merge: !5045 merge br_aicpuKernelLaunch into master feat(machine): Change aicpu kernel launch method Created-by: wan_jianfen Commit-by: wan_jianfen Merged-by: cann-robot Description: 改变kernel_launch 接口,更换成acl 接口 See merge request: cann/pypto!5045 | 3 months ago | |
style(all): Apply additional clang-format corrections across codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4883 merge style-cpp into master style(all): Apply additional clang-format corrections across codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Apply additional clang-format corrections across codebase See merge request: cann/pypto!4883 | 4 months ago | |
fix(machine): Fix dump perf data under multi-round by another way Co-authored-by: arthur_morgan_hw<lipeijie@huawei.com> # message auto-generated for no-merge-commit merge: !3917 merge br_runtime into master fix(machine): Fix dump perf data under multi-round by another way Created-by: arthur_morgan_hw Commit-by: arthur_morgan_hw Merged-by: cann-robot Description: 1. 原本这个问题,在跑多轮情况下,只有第一轮dump的原因是只有第一轮从C侧获取的runtime_debug_mode是1,后续多轮获取的都是0,导致只有第一轮会同步数据,后续不会同步数据。 2. 之前修复方式是还原之前的代码逻辑,即从py侧触发的kernel launch每次都强制去同步数据。 3. 现在进一步定位发现,py侧的options同步给C侧只有在触发编译的时候才会做,多轮的情况下,只有第一轮才会触发编译,后续多轮复用第一次的编译结果。因此修复方案即为同步options给C侧的调用,每次都会调用,而不是只在编译的时候才调用。 See merge request: cann/pypto!3917 | 5 months ago | |
style(all): Apply additional clang-format corrections across codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4883 merge style-cpp into master style(all): Apply additional clang-format corrections across codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Apply additional clang-format corrections across codebase See merge request: cann/pypto!4883 | 4 months ago | |
fix(machine): Fix missing unit issue. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5489 merge machine_format into master fix(machine): Fix missing unit issue. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 修复日志中单位的缺失,使日志信息更便于阅读 See merge request: cann/pypto!5489 | 3 months ago |
| Files | Last commit | Last update |
|---|---|---|
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 5 months ago | ||
| 3 months ago | ||
| 4 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 4 months ago | ||
| 5 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 4 months ago | ||
| 6 months ago | ||
| 3 months ago | ||
| 4 months ago | ||
| 5 months ago | ||
| 4 months ago | ||
| 3 months ago |