Repository navigation
fix: add dtype include for domestic platforms - #55
Merged
Merged
Conversation
gongchensu
approved these changes
Nov 16, 2026
Contributor
Author
|
针对考虑在无直接依赖时回退此pr给出补充说明 对“ATen Argmax 完成推理”这个工作流来说,`generated.h` 包含 我做了严格 A/B 验证:
结果: 所以,ATen Argmax 不依赖这个 InfiniRT 修改。 但另一个公共 API 测试显示: 结果: 因此该修改修复的是更一般的问题:`rt.h` 暴露了 平台影响评估
平台 | 影响评估
-- | --
NVIDIA | rt.h 额外包含 cuda_fp16.h/cuda_bf16.h;原本 runtime_.h 已包含 CUDA runtime,下游本就需要 CUDA include。风险低。
Hygon | 与 NVIDIA 类似,额外暴露 DTK 的 fp16/bf16 头;原公共 runtime 头已依赖 DTK CUDA runtime。风险低。
MetaX | 额外包含 common/maca_fp16.h、`common/maca_bfloat16.h`;原本已包含 mcr/mc_runtime.h,CMake package 也导出 MACA SDK include。风险低。
Moore | 额外包含 musa_fp16.h、`musa_bf16.h`;原本已包含 musa_runtime.h。风险低。
Cambricon | data_type_.h 不引入新的 vendor 头,只补 Float16/BFloat16 TypeMap。基本无额外依赖风险。
Ascend | data_type_.h 使用 acl/acl.h,但 runtime_.h 原本也包含 acl/acl.h。无新增 SDK 依赖。
主要风险不是单平台编译,而是多 accelerator backend 同时启用时:NVIDIA/Iluvatar/Hygon/MetaX/Moore 都会定义 是否回退 不建议回退。理由:
更合适的后续是补一个
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
天数上没这个include好像缺类型