Patent ID: 11934837
Assignee: HUAWEI TECHNOLOGIES CO., LTD.
Field: Computer technology (Electrical engineering)
Classification: CPC G | IPC G

Claim 4:
5. The method according to claim 1, wherein the generating, based on the length of each of the at least one loop dimension of the first tensor formula and the second SIMD instruction model, a first SIMD instruction obtained after the first tensor formula is converted comprises:
generating a plurality of first SIMD instructions based on the length of the at least one loop dimension of the first tensor formula and the second SIMD instruction model; and
selecting, based on a cost function of each of the plurality of first SIMD instructions, an SIMD instruction that satisfies an optimization objective in the plurality of first SIMD instructions, and using the selected SIMD instruction as the first SIMD instruction obtained after the first tensor formula is converted, wherein the cost function indicates an optimization objective related to the first SIMD instruction.