US 12,292,821 B2
Video memory management method, apparatus, device and system
Wengcong Xiao, Hangzhou (CN); Shiru Ren, Beijing (CN); and Yong Li, Beijing (CN)
Assigned to Alibaba Group Holding Limited, Grand Cayman (KY)
Filed by ALIBABA GROUP HOLDING LIMITED, Grand Cayman (KY)
Filed on Apr. 25, 2023, as Appl. No. 18/306,636.
Application 18/306,636 is a continuation of application No. PCT/CN2021/127856, filed on Nov. 1, 2021.
Claims priority of application No. 202011219652.6 (CN), filed on Nov. 3, 2020.
Prior Publication US 2023/0297498 A1, Sep. 21, 2023
Int. Cl. G06F 12/02 (2006.01); G06N 3/08 (2023.01)
CPC G06F 12/023 (2013.01) [G06N 3/08 (2013.01)] 17 Claims
OG exemplary drawing
 
1. A video memory management method, comprising:
determining priorities of a plurality of machine learning tasks executed by a graphics processing unit;
if video memory resources are to be allocated for a higher-priority task, and an amount of allocatable video memory resources is smaller than an amount of video memory resources required by the higher-priority task, releasing at least a part of video memory resources occupied by a lower-priority task; and
allocating video memory resources to the higher-priority task, wherein the higher-priority task is executed at least according to tensor data in a video memory space; wherein the lower-priority task comprises an iterative learning task and releasing at least a part of the video memory resources occupied by the lower-priority task comprises:
if an amount of idle video memory resources of the lower-priority task is smaller than the amount of video memory resources required by the higher-priority task,
allocating internal memory resources to the lower-priority task for the at least a part of tensor data;
after the lower-priority task completes current iterative learning, releasing at least a part of the video memory resources occupied by the lower-priority task, wherein the at least a part of tensor data is transferred to an internal memory space and the lower-priority task is executed at least according to the tensor data in the internal memory space.