{"id":123565,"date":"2026-11-07T17:56:43","date_gmt":"2026-11-07T09:56:43","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/123565.html"},"modified":"2026-11-07T17:56:43","modified_gmt":"2026-11-07T09:56:43","slug":"gpu-%e7%bc%96%e7%a8%8b-dsl-%e5%85%a8%e6%99%af%e5%af%b9%e6%af%94%ef%bc%9atilelang%e3%80%81triton%e3%80%81mojo%e3%80%81cutile%e3%80%81cute%e3%80%81thunderkittens-%e4%b8%8e-cute-dsl","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/123565.html","title":{"rendered":"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL"},"content":{"rendered":"<h3>1. \u5f15\u8a00&#xff1a;\u4e3a\u4ec0\u4e48 GPU \u7f16\u7a0b\u8bed\u8a00\u7a81\u7136&#034;\u767e\u82b1\u9f50\u653e&#034;<\/h3>\n<p>\u8fc7\u53bb\u5341\u5e74&#xff0c;\u5199 GPU \u9ad8\u6027\u80fd\u7b97\u5b50\u57fa\u672c\u53ea\u6709\u4e24\u6761\u8def&#xff1a;\u8981\u4e48\u7528 CUDA C&#043;&#043; \u624b\u5199&#xff0c;\u81ea\u5df1\u7ba1\u7ebf\u7a0b\u3001\u5171\u4eab\u5185\u5b58\u3001\u5bc4\u5b58\u5668\u3001\u6d41\u6c34\u7ebf&#xff1b;\u8981\u4e48\u7528 cuBLAS\/cuDNN \u8fd9\u7c7b\u5e93&#xff0c;\u727a\u7272\u7075\u6d3b\u6027\u6362\u6027\u80fd\u3002\u524d\u8005\u95e8\u69db\u6781\u9ad8&#xff0c;\u540e\u8005\u8986\u76d6\u4e0d\u5230\u65b0\u7b97\u5b50\u3002<\/p>\n<p>\u968f\u7740\u5927\u6a21\u578b\u628a\u6ce8\u610f\u529b\u673a\u5236\u3001MoE\u3001\u91cf\u5316\u3001\u957f\u4e0a\u4e0b\u6587\u7b49\u65b0\u7b97\u5b50\u63a8\u5230\u53f0\u524d&#xff0c;&#034;\u624b\u5199 CUDA \u592a\u6162\u3001\u8c03\u5e93\u4e0d\u591f\u7528&#034;\u7684\u77db\u76fe\u88ab\u653e\u5927\u3002\u4e8e\u662f\u51fa\u73b0\u4e86\u4e00\u6574\u6279\u9762\u5411 GPU \u7684\u9886\u57df\u7279\u5b9a\u8bed\u8a00&#xff08;DSL&#xff09;\u4e0e\u7f16\u7a0b\u6a21\u578b&#xff0c;\u5b83\u4eec\u5404\u81ea\u4ece\u4e0d\u540c\u89d2\u5ea6\u5207\u5165&#xff1a;\u6709\u7684\u60f3\u8ba9\u4f60\u7528 Python \u5199\u63a5\u8fd1\u624b\u5199 CUDA \u7684\u4ee3\u7801&#xff0c;\u6709\u7684\u60f3\u7528 tile \u62bd\u8c61\u5c4f\u853d\u786c\u4ef6\u7ec6\u8282&#xff0c;\u6709\u7684\u5e72\u8106\u91cd\u9020\u4e00\u95e8\u8bed\u8a00\u3002<\/p>\n<p>\u672c\u6587\u5bf9\u6bd4 TileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe&#xff08;C&#043;&#043; \u6a21\u677f&#xff09;\u3001ThunderKittens\u3001CuTe DSL \u8fd9\u4e03\u79cd\u65b9\u6848&#xff0c;\u5148\u9010\u4e2a\u8bb2\u8bde\u751f\u52a8\u673a\u4e0e\u6838\u5fc3\u7279\u6027&#xff0c;\u6700\u540e\u68b3\u7406\u4e00\u6761\u65f6\u95f4\u7ebf\u4e0e\u5b83\u4eec\u4e4b\u95f4\u7684\u4ea4\u4e92\u5173\u7cfb\u3002<\/p>\n<h3>2. \u9010\u4e2a\u62c6\u89e3&#xff1a;\u52a8\u673a\u4e0e\u6838\u5fc3\u7279\u6027<\/h3>\n<h4>2.1 Triton&#xff1a;\u7528 Python \u5199&#034;\u5757\u7ea7&#034;GPU \u7a0b\u5e8f<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;OpenAI \u5728 2021 \u5e74\u524d\u540e\u63a8\u51fa Triton&#xff0c;\u76ee\u6807\u662f\u8ba9\u4e0d\u719f\u6089 CUDA \u7684\u7814\u7a76\u8005\u4e5f\u80fd\u5199\u51fa\u63a5\u8fd1\u624b\u5199\u6027\u80fd\u7684\u7b97\u5b50\u3002\u4f20\u7edf CUDA \u8981\u6c42\u4f60\u4ee5&#034;\u7ebf\u7a0b&#034;\u4e3a\u5355\u4f4d\u601d\u8003&#xff0c;\u800c Triton \u8ba9\u4f60\u4ee5&#034;\u5757&#xff08;block\/tile&#xff09;&#034;\u4e3a\u5355\u4f4d\u601d\u8003\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u57fa\u4e8e Python \u7684 DSL&#xff0c;\u7528 &#064;triton.jit \u88c5\u9970\u51fd\u6570&#xff0c;\u7f16\u8bd1\u4e3a PTX\u3002<\/li>\n<li>\u4ee5 tile \u4e3a\u57fa\u672c\u64cd\u4f5c\u5355\u4f4d&#xff0c;tl.load \/ tl.store \/ tl.dot \u7b49\u539f\u8bed\u81ea\u52a8\u5904\u7406\u5411\u91cf\u5316\u4e0e\u5185\u5b58\u5408\u5e76\u3002<\/li>\n<li>\u7f16\u8bd1\u5668\u8d1f\u8d23\u5171\u4eab\u5185\u5b58\u5206\u914d\u3001\u7ebf\u7a0b\u6620\u5c04\u3001\u6d41\u6c34\u7ebf\u8c03\u5ea6&#xff0c;\u7528\u6237\u4e0d\u76f4\u63a5\u63a5\u89e6 __shared__\u3002<\/li>\n<li>\u751f\u6001\u6210\u719f&#xff1a;PyTorch \u7684 torch.compile \u540e\u7aef\u4e4b\u4e00\u3001vLLM\/FlashAttention \u7b49\u5927\u91cf\u9879\u76ee\u4f7f\u7528\u3002<\/li>\n<\/ul>\n<p><span class=\"token keyword\">import<\/span> triton<br \/>\n<span class=\"token keyword\">import<\/span> triton<span class=\"token punctuation\">.<\/span>language <span class=\"token keyword\">as<\/span> tl<\/p>\n<p><span class=\"token decorator annotation punctuation\">&#064;triton<span class=\"token punctuation\">.<\/span>jit<\/span><br \/>\n<span class=\"token keyword\">def<\/span> <span class=\"token function\">add_kernel<\/span><span class=\"token punctuation\">(<\/span>x_ptr<span class=\"token punctuation\">,<\/span> y_ptr<span class=\"token punctuation\">,<\/span> out_ptr<span class=\"token punctuation\">,<\/span> n<span class=\"token punctuation\">,<\/span> BLOCK<span class=\"token punctuation\">:<\/span> tl<span class=\"token punctuation\">.<\/span>constexpr<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    pid <span class=\"token operator\">&#061;<\/span> tl<span class=\"token punctuation\">.<\/span>program_id<span class=\"token punctuation\">(<\/span><span class=\"token number\">0<\/span><span class=\"token punctuation\">)<\/span><br \/>\n    offs <span class=\"token operator\">&#061;<\/span> pid <span class=\"token operator\">*<\/span> BLOCK <span class=\"token operator\">&#043;<\/span> tl<span class=\"token punctuation\">.<\/span>arange<span class=\"token punctuation\">(<\/span><span class=\"token number\">0<\/span><span class=\"token punctuation\">,<\/span> BLOCK<span class=\"token punctuation\">)<\/span><br \/>\n    mask <span class=\"token operator\">&#061;<\/span> offs <span class=\"token operator\">&lt;<\/span> n<br \/>\n    x <span class=\"token operator\">&#061;<\/span> tl<span class=\"token punctuation\">.<\/span>load<span class=\"token punctuation\">(<\/span>x_ptr <span class=\"token operator\">&#043;<\/span> offs<span class=\"token punctuation\">,<\/span> mask<span class=\"token operator\">&#061;<\/span>mask<span class=\"token punctuation\">)<\/span><br \/>\n    y <span class=\"token operator\">&#061;<\/span> tl<span class=\"token punctuation\">.<\/span>load<span class=\"token punctuation\">(<\/span>y_ptr <span class=\"token operator\">&#043;<\/span> offs<span class=\"token punctuation\">,<\/span> mask<span class=\"token operator\">&#061;<\/span>mask<span class=\"token punctuation\">)<\/span><br \/>\n    tl<span class=\"token punctuation\">.<\/span>store<span class=\"token punctuation\">(<\/span>out_ptr <span class=\"token operator\">&#043;<\/span> offs<span class=\"token punctuation\">,<\/span> x <span class=\"token operator\">&#043;<\/span> y<span class=\"token punctuation\">,<\/span> mask<span class=\"token operator\">&#061;<\/span>mask<span class=\"token punctuation\">)<\/span><\/p>\n<p>\u5b9a\u4f4d&#xff1a;\u76ee\u524d\u6700\u4e3b\u6d41\u7684&#034;Python \u5199 GPU kernel&#034;\u65b9\u6848&#xff0c;\u62bd\u8c61\u5c42\u6b21\u9002\u4e2d&#xff0c;\u6027\u80fd\u4e0e\u6613\u7528\u6027\u5e73\u8861\u6700\u597d\u3002<\/p>\n<h4>2.2 TileLang&#xff1a;\u628a tile \u62bd\u8c61\u505a\u5230\u6781\u81f4<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;Triton \u867d\u7136\u597d\u7528&#xff0c;\u4f46\u5728\u9700\u8981\u7cbe\u7ec6\u63a7\u5236\u6d41\u6c34\u7ebf\u3001warp \u7279\u5316\u3001\u5f02\u6b65\u62f7\u8d1d&#xff08;TMA&#xff09;\u7b49\u573a\u666f\u65f6&#xff0c;\u62bd\u8c61\u4ecd\u4e0d\u591f\u3002TileLang \u7531\u5fae\u8f6f\u7b49\u56e2\u961f\u63a8\u52a8&#xff0c;\u76ee\u6807\u662f\u63d0\u4f9b\u66f4\u8d34\u8fd1\u786c\u4ef6\u7684 tile \u7ea7 DSL&#xff0c;\u8ba9\u7528\u6237\u80fd\u663e\u5f0f\u8868\u8fbe\u6570\u636e\u642c\u8fd0\u4e0e\u8ba1\u7b97\u7684\u91cd\u53e0\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u4ee5 tile \u4e3a\u6838\u5fc3\u62bd\u8c61&#xff0c;\u663e\u5f0f\u533a\u5206\u5168\u5c40\u5185\u5b58\u3001\u5171\u4eab\u5185\u5b58\u3001\u5bc4\u5b58\u5668\u5c42\u7ea7\u3002<\/li>\n<li>\u652f\u6301\u663e\u5f0f\u6d41\u6c34\u7ebf&#xff08;pipeline&#xff09;\u3001\u5f02\u6b65\u62f7\u8d1d\u3001warp \u7279\u5316\u7b49\u9ad8\u7ea7\u8c03\u5ea6\u3002<\/li>\n<li>\u8bed\u6cd5\u63a5\u8fd1 Python&#xff0c;\u4f46\u63d0\u4f9b\u66f4\u7ec6\u7c92\u5ea6\u7684\u63a7\u5236\u539f\u8bed\u3002<\/li>\n<li>\u9762\u5411\u9ad8\u6027\u80fd\u7b97\u5b50&#xff08;GEMM\u3001Attention&#xff09;\u7684\u81ea\u52a8\u8c03\u4f18\u4e0e\u4ee3\u7801\u751f\u6210\u3002<\/li>\n<\/ul>\n<p>\u5b9a\u4f4d&#xff1a;\u4ecb\u4e8e Triton \u4e0e\u624b\u5199 CUDA \u4e4b\u95f4&#xff0c;\u8ffd\u6c42&#034;\u53ef\u63a7\u6027 &#043; \u751f\u4ea7\u529b&#034;\u7684\u5e73\u8861&#xff0c;\u9002\u5408\u9700\u8981\u69a8\u5e72\u786c\u4ef6\u6027\u80fd\u7684\u7b97\u5b50\u5f00\u53d1\u8005\u3002<\/p>\n<h4>2.3 Mojo&#xff1a;\u4e3a AI \u91cd\u9020\u4e00\u95e8\u8bed\u8a00<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;Chris Lattner&#xff08;LLVM\u3001Swift\u3001Clang \u4e4b\u7236&#xff09;\u521b\u7acb Modular&#xff0c;\u63a8\u51fa Mojo\u3002\u52a8\u673a\u662f Python \u751f\u6001\u597d\u7528\u4f46\u6027\u80fd\u4e0d\u8db3&#xff0c;C&#043;&#043; \u6027\u80fd\u597d\u4f46\u5f00\u53d1\u6548\u7387\u4f4e&#xff0c;\u4e8e\u662f\u60f3\u9020\u4e00\u95e8\u517c\u5177 Python \u8bed\u6cd5\u4e0e C \u7ea7\u6027\u80fd\u7684\u7cfb\u7edf\u7ea7\u8bed\u8a00\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u8bed\u6cd5\u9ad8\u5ea6\u517c\u5bb9 Python&#xff0c;\u4f46\u5f15\u5165\u5f3a\u7c7b\u578b\u3001\u6240\u6709\u6743&#xff08;ownership&#xff09;\u3001\u503c\u8bed\u4e49\u3002<\/li>\n<li>\u901a\u8fc7 MLIR \u7f16\u8bd1&#xff0c;\u53ef\u9488\u5bf9 CPU\u3001GPU&#xff08;NVIDIA\/AMD&#xff09;\u7b49\u591a\u79cd\u540e\u7aef\u3002<\/li>\n<li>\u652f\u6301 fn&#xff08;\u4e25\u683c\u7c7b\u578b\u3001\u9ad8\u6027\u80fd&#xff09;\u4e0e def&#xff08;\u52a8\u6001&#xff09;\u4e24\u79cd\u51fd\u6570\u3002<\/li>\n<li>\u53ef\u76f4\u63a5\u8c03\u7528 Python \u751f\u6001&#xff0c;\u9010\u6b65\u8fc1\u79fb\u3002<\/li>\n<\/ul>\n<p>fn vector_add(a: DTypePointer[DType.float32], b: DTypePointer[DType.float32], c: DTypePointer[DType.float32], n: Int):<br \/>\n    for i in range(n):<br \/>\n        c[i] &#061; a[i] &#043; b[i]<\/p>\n<p>\u5b9a\u4f4d&#xff1a;\u4e0d\u662f\u5355\u7eaf\u7684 GPU DSL&#xff0c;\u800c\u662f&#034;AI \u65f6\u4ee3\u7684\u7cfb\u7edf\u7f16\u7a0b\u8bed\u8a00&#034;&#xff0c;GPU \u7f16\u7a0b\u53ea\u662f\u5176\u80fd\u529b\u4e4b\u4e00\u3002<\/p>\n<h4>2.4 cuTile&#xff1a;NVIDIA \u5b98\u65b9\u7684 tile \u7ea7 Python DSL<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;\u9762\u5bf9 Triton \u5728 Python GPU \u7f16\u7a0b\u4e0a\u7684\u6210\u529f&#xff0c;NVIDIA \u9700\u8981\u81ea\u5df1\u7684\u5b98\u65b9\u65b9\u6848\u3002cuTile \u662f NVIDIA \u63a8\u51fa\u7684\u57fa\u4e8e tile \u62bd\u8c61\u7684 Python DSL&#xff0c;\u6df1\u5ea6\u96c6\u6210 CUDA \u751f\u6001&#xff0c;\u76ee\u6807\u662f\u8ba9 Python \u5f00\u53d1\u8005\u4ee5\u5b98\u65b9\u652f\u6301\u7684\u65b9\u5f0f\u5199\u9ad8\u6027\u80fd kernel\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u5b98\u65b9\u51fa\u54c1&#xff0c;\u4e0e CUDA \u5de5\u5177\u94fe\u3001Nsight \u7b49\u6df1\u5ea6\u96c6\u6210\u3002<\/li>\n<li>tile \u7ea7\u62bd\u8c61&#xff0c;\u7f16\u8bd1\u5668\u8d1f\u8d23\u5e95\u5c42\u6620\u5c04\u3002<\/li>\n<li>\u4e0e CuTe\/CUTLASS \u751f\u6001\u6709\u6f5c\u5728\u534f\u540c\u3002<\/li>\n<li>\u9762\u5411 NVIDIA \u786c\u4ef6\u505a\u9488\u5bf9\u6027\u4f18\u5316\u3002<\/li>\n<\/ul>\n<p>\u5b9a\u4f4d&#xff1a;NVIDIA \u5bf9 Triton \u7684&#034;\u5b98\u65b9\u56de\u5e94&#034;&#xff0c;\u5f3a\u8c03\u751f\u6001\u4e00\u81f4\u6027\u4e0e\u786c\u4ef6\u4eb2\u548c\u6027\u3002<\/p>\n<h4>2.5 CuTe&#xff08;C&#043;&#043; \u6a21\u677f\u5e93&#xff09;&#xff1a;CUTLASS \u7684\u5e03\u5c40\u4e0e\u7b97\u6cd5\u5185\u6838<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;CUTLASS \u662f NVIDIA \u7684\u9ad8\u6027\u80fd GEMM \u6a21\u677f\u5e93&#xff0c;\u4f46\u5176\u65e9\u671f\u4ee3\u7801\u5bf9\u5e03\u5c40&#xff08;layout&#xff09;\u3001\u7ebf\u7a0b\u6620\u5c04\u7684\u8868\u8fbe\u975e\u5e38\u7e41\u7410\u3002CuTe \u4f5c\u4e3a CUTLASS 3.x \u7684\u6838\u5fc3\u7ec4\u4ef6\u88ab\u63d0\u70bc\u51fa\u6765&#xff0c;\u7528\u7f16\u8bd1\u671f\u6a21\u677f\u5143\u7f16\u7a0b\u7edf\u4e00\u8868\u8fbe&#034;\u6570\u636e\u5e03\u5c40 &#043; \u7b97\u6cd5&#034;\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u6838\u5fc3\u6982\u5ff5&#xff1a;Layout&#xff08;\u5f62\u72b6\u4e0e\u6b65\u957f\u7684\u7ec4\u5408&#xff09;\u3001Tensor&#xff08;\u6570\u636e &#043; \u5e03\u5c40&#xff09;\u3001TiledCopy \/ TiledMMA&#xff08;\u5206\u5757\u62f7\u8d1d\u4e0e\u77e9\u9635\u4e58&#xff09;\u3002<\/li>\n<li>\u5168\u90e8\u5728\u7f16\u8bd1\u671f\u5b8c\u6210\u5e03\u5c40\u63a8\u5bfc&#xff0c;\u96f6\u8fd0\u884c\u65f6\u5f00\u9500\u3002<\/li>\n<li>\u7528\u7c7b\u578b\u7cfb\u7edf\u8868\u8fbe\u7ebf\u7a0b\u4e0e\u6570\u636e\u7684\u6620\u5c04\u5173\u7cfb\u3002<\/li>\n<li>\u662f CUTLASS 3.x \u7684\u5e95\u5c42\u57fa\u7840\u3002<\/li>\n<\/ul>\n<p><span class=\"token comment\">\/\/ CuTe \u98ce\u683c&#xff1a;\u7528 Layout \u63cf\u8ff0 (M, N) \u77e9\u9635\u7684\u5206\u5757\u5e03\u5c40<\/span><br \/>\n<span class=\"token keyword\">using<\/span> <span class=\"token keyword\">namespace<\/span> cute<span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token keyword\">auto<\/span> layout <span class=\"token operator\">&#061;<\/span> <span class=\"token function\">make_layout<\/span><span class=\"token punctuation\">(<\/span><span class=\"token function\">make_shape<\/span><span class=\"token punctuation\">(<\/span>Int<span class=\"token operator\">&lt;<\/span><span class=\"token number\">128<\/span><span class=\"token operator\">&gt;<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">,<\/span> Int<span class=\"token operator\">&lt;<\/span><span class=\"token number\">128<\/span><span class=\"token operator\">&gt;<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">,<\/span><br \/>\n                          <span class=\"token function\">make_stride<\/span><span class=\"token punctuation\">(<\/span>Int<span class=\"token operator\">&lt;<\/span><span class=\"token number\">128<\/span><span class=\"token operator\">&gt;<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">,<\/span> Int<span class=\"token operator\">&lt;<\/span><span class=\"token number\">1<\/span><span class=\"token operator\">&gt;<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><\/p>\n<p>\u5b9a\u4f4d&#xff1a;C&#043;&#043; \u6a21\u677f\u5143\u7f16\u7a0b\u8def\u7ebf\u7684\u5dc5\u5cf0\u4e4b\u4f5c&#xff0c;\u6027\u80fd\u6781\u81f4\u4f46\u5b66\u4e60\u66f2\u7ebf\u9661\u5ced\u3002<\/p>\n<h4>2.6 ThunderKittens&#xff1a;\u4e3a AI \u7b97\u5b50\u8bbe\u8ba1\u7684&#034;\u6781\u7b80 tile \u5e93&#034;<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;\u65af\u5766\u798f Hazy Research \u56e2\u961f\u63a8\u51fa ThunderKittens&#xff0c;\u52a8\u673a\u662f\u73b0\u6709\u65b9\u6848\u8981\u4e48\u62bd\u8c61\u592a\u9ad8&#xff08;\u4e22\u5931\u6027\u80fd&#xff09;&#xff0c;\u8981\u4e48\u592a\u5e95\u5c42&#xff08;\u5f00\u53d1\u6162&#xff09;\u3002\u4ed6\u4eec\u63d0\u51fa&#034;tile \u5c31\u662f\u4e00\u5207&#034;\u7684\u7406\u5ff5&#xff0c;\u7528\u6781\u7b80\u7684 C&#043;&#043;\/CUDA \u5934\u6587\u4ef6\u5e93\u8ba9\u5f00\u53d1\u8005\u5feb\u901f\u5199\u51fa\u63a5\u8fd1\u5cf0\u503c\u7684 AI \u7b97\u5b50\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u6781\u7b80 API&#xff1a;\u6838\u5fc3\u5c31\u662f tile \u7c7b\u578b\u4e0e\u5c11\u91cf\u64cd\u4f5c&#xff08;load\/store\/mma\/exp \u7b49&#xff09;\u3002<\/li>\n<li>\u5f3a\u8c03&#034;\u6bcf\u4e2a SM \u4e00\u4e2a tile&#034;\u7684\u7f16\u7a0b\u6a21\u578b&#xff0c;\u7b80\u5316\u7ebf\u7a0b\u7ba1\u7406\u3002<\/li>\n<li>\u9488\u5bf9\u73b0\u4ee3 GPU&#xff08;Hopper \u7b49&#xff09;\u7684 TMA\u3001WGMMA \u7b49\u7279\u6027\u4f18\u5316\u3002<\/li>\n<li>\u5934\u6587\u4ef6\u5e93\u5f62\u5f0f&#xff0c;\u6613\u4e8e\u96c6\u6210\u3002<\/li>\n<\/ul>\n<p>\u5b9a\u4f4d&#xff1a;\u7814\u7a76\u53cb\u597d\u3001\u4e0a\u624b\u5feb&#xff0c;\u9002\u5408\u5feb\u901f\u5b9e\u73b0\u548c\u5b9e\u9a8c\u65b0\u7b97\u5b50\u3002<\/p>\n<h4>2.7 CuTe DSL&#xff1a;\u628a CuTe \u5e26\u5230 Python<\/h4>\n<p>\u8bde\u751f\u52a8\u673a&#xff1a;CuTe \u7684 C&#043;&#043; \u6a21\u677f\u867d\u7136\u5f3a\u5927&#xff0c;\u4f46\u7f16\u8bd1\u6162\u3001\u8c03\u8bd5\u96be\u3001\u95e8\u69db\u9ad8\u3002CuTe DSL \u7684\u76ee\u6807\u662f\u4fdd\u7559 CuTe \u7684\u5e03\u5c40\u62bd\u8c61\u601d\u60f3&#xff0c;\u540c\u65f6\u63d0\u4f9b Python \u5c42\u7684\u6613\u7528\u6027&#xff0c;\u8ba9\u66f4\u591a\u4eba\u80fd\u7528\u4e0a CuTe \u7684\u8868\u8fbe\u80fd\u529b\u3002<\/p>\n<p>\u6838\u5fc3\u7279\u6027&#xff1a;<\/p>\n<ul>\n<li>\u7528 Python \u8868\u8fbe CuTe \u7684 Layout\/Tensor \u6982\u5ff5\u3002<\/li>\n<li>\u964d\u4f4e\u7f16\u8bd1\u671f\u6a21\u677f\u5e26\u6765\u7684\u5f00\u53d1\u8d1f\u62c5\u3002<\/li>\n<li>\u4e0e CUTLASS\/CuTe \u751f\u6001\u8854\u63a5\u3002<\/li>\n<li>\u9762\u5411\u9700\u8981\u7cbe\u7ec6\u5e03\u5c40\u63a7\u5236\u4f46\u4e0d\u60f3\u5199\u6a21\u677f\u5143\u7f16\u7a0b\u7684\u7528\u6237\u3002<\/li>\n<\/ul>\n<p>\u5b9a\u4f4d&#xff1a;CuTe \u601d\u60f3\u7684&#034;Python \u5316&#034;\u5ef6\u4f38&#xff0c;\u517c\u987e\u8868\u8fbe\u529b\u4e0e\u6613\u7528\u6027\u3002<\/p>\n<h3>3. \u6a2a\u5411\u5bf9\u6bd4<\/h3>\n<table>\n<tr>\u65b9\u6848\u8bed\u8a00\u62bd\u8c61\u5c42\u6b21\u4e3b\u8981\u52a8\u673a\u5b66\u4e60\u66f2\u7ebf\u5178\u578b\u7528\u6237<\/tr>\n<tbody>\n<tr>\n<td>Triton<\/td>\n<td>Python<\/td>\n<td>tile \u7ea7<\/td>\n<td>\u964d\u4f4e GPU \u7f16\u7a0b\u95e8\u69db<\/td>\n<td>\u4f4e-\u4e2d<\/td>\n<td>\u7814\u7a76\u8005\u3001\u6846\u67b6\u5f00\u53d1\u8005<\/td>\n<\/tr>\n<tr>\n<td>TileLang<\/td>\n<td>Python<\/td>\n<td>tile \u7ea7&#xff08;\u66f4\u7ec6&#xff09;<\/td>\n<td>\u7cbe\u7ec6\u63a7\u5236 &#043; \u751f\u4ea7\u529b<\/td>\n<td>\u4e2d<\/td>\n<td>\u9ad8\u6027\u80fd\u7b97\u5b50\u5f00\u53d1\u8005<\/td>\n<\/tr>\n<tr>\n<td>Mojo<\/td>\n<td>Mojo<\/td>\n<td>\u8bed\u8a00\u7ea7<\/td>\n<td>Python \u8bed\u6cd5 &#043; C \u6027\u80fd<\/td>\n<td>\u4e2d<\/td>\n<td>\u7cfb\u7edf\/AI \u57fa\u7840\u8bbe\u65bd\u5f00\u53d1\u8005<\/td>\n<\/tr>\n<tr>\n<td>cuTile<\/td>\n<td>Python<\/td>\n<td>tile \u7ea7<\/td>\n<td>NVIDIA \u5b98\u65b9 Python \u65b9\u6848<\/td>\n<td>\u4f4e-\u4e2d<\/td>\n<td>CUDA \u751f\u6001\u7528\u6237<\/td>\n<\/tr>\n<tr>\n<td>CuTe (C&#043;&#043;)<\/td>\n<td>C&#043;&#043; \u6a21\u677f<\/td>\n<td>\u5e03\u5c40\/\u7b97\u6cd5\u7ea7<\/td>\n<td>\u7f16\u8bd1\u671f\u5e03\u5c40\u8868\u8fbe<\/td>\n<td>\u9ad8<\/td>\n<td>CUTLASS \u7528\u6237\u3001\u4e13\u5bb6<\/td>\n<\/tr>\n<tr>\n<td>ThunderKittens<\/td>\n<td>C&#043;&#043;\/CUDA<\/td>\n<td>tile \u7ea7&#xff08;\u6781\u7b80&#xff09;<\/td>\n<td>\u5feb\u901f\u5199\u9ad8\u6027\u80fd AI \u7b97\u5b50<\/td>\n<td>\u4f4e-\u4e2d<\/td>\n<td>\u7814\u7a76\u56e2\u961f<\/td>\n<\/tr>\n<tr>\n<td>CuTe DSL<\/td>\n<td>Python<\/td>\n<td>\u5e03\u5c40\/\u7b97\u6cd5\u7ea7<\/td>\n<td>CuTe \u7684 Python \u5316<\/td>\n<td>\u4e2d<\/td>\n<td>\u9700\u7cbe\u7ec6\u5e03\u5c40\u7684 Python \u7528\u6237<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>4. \u65f6\u95f4\u7ebf\u4e0e\u6f14\u8fdb\u8109\u7edc<\/h3>\n<p>#mermaid-svg-SStYtldIslVq7Gol{font-family:\\&#8221;trebuchet ms\\&#8221;,verdana,arial,sans-serif;font-size:16px;fill:#333;}@keyframes edge-animation-frame{from{stroke-dashoffset:0;}}@keyframes dash{to{stroke-dashoffset:0;}}#mermaid-svg-SStYtldIslVq7Gol .edge-animation-slow{stroke-dasharray:9,5!important;stroke-dashoffset:900;animation:dash 50s linear infinite;stroke-linecap:round;}#mermaid-svg-SStYtldIslVq7Gol .edge-animation-fast{stroke-dasharray:9,5!important;stroke-dashoffset:900;animation:dash 20s linear infinite;stroke-linecap:round;}#mermaid-svg-SStYtldIslVq7Gol .error-icon{fill:#552222;}#mermaid-svg-SStYtldIslVq7Gol .error-text{fill:#552222;stroke:#552222;}#mermaid-svg-SStYtldIslVq7Gol .edge-thickness-normal{stroke-width:1px;}#mermaid-svg-SStYtldIslVq7Gol .edge-thickness-thick{stroke-width:3.5px;}#mermaid-svg-SStYtldIslVq7Gol .edge-pattern-solid{stroke-dasharray:0;}#mermaid-svg-SStYtldIslVq7Gol .edge-thickness-invisible{stroke-width:0;fill:none;}#mermaid-svg-SStYtldIslVq7Gol .edge-pattern-dashed{stroke-dasharray:3;}#mermaid-svg-SStYtldIslVq7Gol .edge-pattern-dotted{stroke-dasharray:2;}#mermaid-svg-SStYtldIslVq7Gol .marker{fill:#333333;stroke:#333333;}#mermaid-svg-SStYtldIslVq7Gol .marker.cross{stroke:#333333;}#mermaid-svg-SStYtldIslVq7Gol svg{font-family:\\&#8221;trebuchet ms\\&#8221;,verdana,arial,sans-serif;font-size:16px;}#mermaid-svg-SStYtldIslVq7Gol p{margin:0;}#mermaid-svg-SStYtldIslVq7Gol .label{font-family:\\&#8221;trebuchet ms\\&#8221;,verdana,arial,sans-serif;color:#333;}#mermaid-svg-SStYtldIslVq7Gol .cluster-label text{fill:#333;}#mermaid-svg-SStYtldIslVq7Gol .cluster-label span{color:#333;}#mermaid-svg-SStYtldIslVq7Gol .cluster-label span p{background-color:transparent;}#mermaid-svg-SStYtldIslVq7Gol .label text,#mermaid-svg-SStYtldIslVq7Gol span{fill:#333;color:#333;}#mermaid-svg-SStYtldIslVq7Gol .node rect,#mermaid-svg-SStYtldIslVq7Gol .node circle,#mermaid-svg-SStYtldIslVq7Gol .node ellipse,#mermaid-svg-SStYtldIslVq7Gol .node polygon,#mermaid-svg-SStYtldIslVq7Gol .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaid-svg-SStYtldIslVq7Gol .rough-node .label text,#mermaid-svg-SStYtldIslVq7Gol .node .label text,#mermaid-svg-SStYtldIslVq7Gol .image-shape .label,#mermaid-svg-SStYtldIslVq7Gol .icon-shape .label{text-anchor:middle;}#mermaid-svg-SStYtldIslVq7Gol .node .katex path{fill:#000;stroke:#000;stroke-width:1px;}#mermaid-svg-SStYtldIslVq7Gol .rough-node .label,#mermaid-svg-SStYtldIslVq7Gol .node .label,#mermaid-svg-SStYtldIslVq7Gol .image-shape .label,#mermaid-svg-SStYtldIslVq7Gol .icon-shape .label{text-align:center;}#mermaid-svg-SStYtldIslVq7Gol .node.clickable{cursor:pointer;}#mermaid-svg-SStYtldIslVq7Gol .root .anchor path{fill:#333333!important;stroke-width:0;stroke:#333333;}#mermaid-svg-SStYtldIslVq7Gol .arrowheadPath{fill:#333333;}#mermaid-svg-SStYtldIslVq7Gol .edgePath .path{stroke:#333333;stroke-width:2.0px;}#mermaid-svg-SStYtldIslVq7Gol .flowchart-link{stroke:#333333;fill:none;}#mermaid-svg-SStYtldIslVq7Gol .edgeLabel{background-color:rgba(232,232,232, 0.8);text-align:center;}#mermaid-svg-SStYtldIslVq7Gol .edgeLabel p{background-color:rgba(232,232,232, 0.8);}#mermaid-svg-SStYtldIslVq7Gol .edgeLabel rect{opacity:0.5;background-color:rgba(232,232,232, 0.8);fill:rgba(232,232,232, 0.8);}#mermaid-svg-SStYtldIslVq7Gol .labelBkg{background-color:rgba(232, 232, 232, 0.5);}#mermaid-svg-SStYtldIslVq7Gol .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaid-svg-SStYtldIslVq7Gol .cluster text{fill:#333;}#mermaid-svg-SStYtldIslVq7Gol .cluster span{color:#333;}#mermaid-svg-SStYtldIslVq7Gol div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:\\&#8221;trebuchet ms\\&#8221;,verdana,arial,sans-serif;font-size:12px;background:hsl(80, 100%, 96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaid-svg-SStYtldIslVq7Gol .flowchartTitleText{text-anchor:middle;font-size:18px;fill:#333;}#mermaid-svg-SStYtldIslVq7Gol rect.text{fill:none;stroke-width:0;}#mermaid-svg-SStYtldIslVq7Gol .icon-shape,#mermaid-svg-SStYtldIslVq7Gol .image-shape{background-color:rgba(232,232,232, 0.8);text-align:center;}#mermaid-svg-SStYtldIslVq7Gol .icon-shape p,#mermaid-svg-SStYtldIslVq7Gol .image-shape p{background-color:rgba(232,232,232, 0.8);padding:2px;}#mermaid-svg-SStYtldIslVq7Gol .icon-shape .label rect,#mermaid-svg-SStYtldIslVq7Gol .image-shape .label rect{opacity:0.5;background-color:rgba(232,232,232, 0.8);fill:rgba(232,232,232, 0.8);}#mermaid-svg-SStYtldIslVq7Gol .label-icon{display:inline-block;height:1em;overflow:visible;vertical-align:-0.125em;}#mermaid-svg-SStYtldIslVq7Gol .node .label-icon path{fill:currentColor;stroke:revert;stroke-width:revert;}#mermaid-svg-SStYtldIslVq7Gol :root{&#8211;mermaid-font-family:\\&#8221;trebuchet ms\\&#8221;,verdana,arial,sans-serif;}<span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"edgeLabel\"><\/span><span class=\"nodeLabel\"><\/p>\n<p>2017-2019CUTLASS \u8bde\u751f\u624b\u5199\u6a21\u677f GEMM<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2021Triton \u53d1\u5e03Python tile \u7ea7 DSL<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2022-2023CuTe \u63d0\u70bcCUTLASS 3.x \u5e03\u5c40\u62bd\u8c61<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2023Mojo \u53d1\u5e03AI \u7cfb\u7edf\u8bed\u8a00<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2024ThunderKittens\u6781\u7b80 tile \u5e93<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2024-2025TileLang\u7cbe\u7ec6 tile DSL<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2025cuTileNVIDIA \u5b98\u65b9 Python DSL<\/p>\n<p><\/span><span class=\"nodeLabel\"><\/p>\n<p>2025CuTe DSLCuTe \u7684 Python \u5316<\/p>\n<p><\/span><\/p>\n<p>\u6bcf\u4e2a\u65b9\u6848\u89e3\u51b3\u7684\u7279\u6b8a\u95ee\u9898&#xff1a;<\/p>\n<ul>\n<li>CUTLASS&#xff08;2017-2019&#xff09;&#xff1a;\u89e3\u51b3&#034;\u9ad8\u6027\u80fd GEMM \u9700\u8981\u53cd\u590d\u624b\u5199&#034;\u7684\u95ee\u9898&#xff0c;\u7528\u6a21\u677f\u5e93\u56fa\u5316\u6700\u4f73\u5b9e\u8df5\u3002<\/li>\n<li>Triton&#xff08;2021&#xff09;&#xff1a;\u89e3\u51b3&#034;Python \u7528\u6237\u5199\u4e0d\u4e86 GPU kernel&#034;\u7684\u95ee\u9898&#xff0c;\u7528 tile \u62bd\u8c61 &#043; \u7f16\u8bd1\u5668\u81ea\u52a8\u5316\u3002<\/li>\n<li>CuTe&#xff08;2022-2023&#xff09;&#xff1a;\u89e3\u51b3&#034;CUTLASS \u5e03\u5c40\u8868\u8fbe\u592a\u7e41\u7410&#034;\u7684\u95ee\u9898&#xff0c;\u7528\u7f16\u8bd1\u671f\u7c7b\u578b\u7cfb\u7edf\u7edf\u4e00\u5e03\u5c40\u4e0e\u7b97\u6cd5\u3002<\/li>\n<li>Mojo&#xff08;2023&#xff09;&#xff1a;\u89e3\u51b3&#034;Python \u6027\u80fd\u4e0d\u8db3\u3001C&#043;&#043; \u6548\u7387\u4f4e&#034;\u7684\u95ee\u9898&#xff0c;\u91cd\u9020\u4e00\u95e8 AI \u7cfb\u7edf\u8bed\u8a00\u3002<\/li>\n<li>ThunderKittens&#xff08;2024&#xff09;&#xff1a;\u89e3\u51b3&#034;\u73b0\u6709\u65b9\u6848\u8981\u4e48\u592a\u62bd\u8c61\u8981\u4e48\u592a\u5e95\u5c42&#034;\u7684\u95ee\u9898&#xff0c;\u7528\u6781\u7b80 tile \u5e93\u5feb\u901f\u5199\u7b97\u5b50\u3002<\/li>\n<li>TileLang&#xff08;2024-2025&#xff09;&#xff1a;\u89e3\u51b3&#034;Triton \u62bd\u8c61\u4e0d\u591f\u7cbe\u7ec6&#034;\u7684\u95ee\u9898&#xff0c;\u63d0\u4f9b\u663e\u5f0f\u6d41\u6c34\u7ebf\u4e0e\u786c\u4ef6\u63a7\u5236\u3002<\/li>\n<li>cuTile&#xff08;2025&#xff09;&#xff1a;\u89e3\u51b3&#034;NVIDIA \u7f3a\u5c11\u5b98\u65b9 Python tile DSL&#034;\u7684\u95ee\u9898&#xff0c;\u5b98\u65b9\u80cc\u4e66 &#043; \u751f\u6001\u96c6\u6210\u3002<\/li>\n<li>CuTe DSL&#xff08;2025&#xff09;&#xff1a;\u89e3\u51b3&#034;CuTe \u6a21\u677f\u7f16\u8bd1\u6162\u3001\u95e8\u69db\u9ad8&#034;\u7684\u95ee\u9898&#xff0c;Python \u5316\u5e03\u5c40\u62bd\u8c61\u3002<\/li>\n<\/ul>\n<h3>5. \u5b83\u4eec\u4e4b\u95f4\u5982\u4f55\u4ea4\u4e92\u4e0e\u5173\u8054<\/h3>\n<p>\u8fd9\u4e9b\u65b9\u6848\u5e76\u975e\u5b64\u7acb&#xff0c;\u800c\u662f\u5f62\u6210\u4e86\u4e00\u5f20\u76f8\u4e92\u501f\u9274\u3001\u5c42\u5c42\u9012\u8fdb\u7684\u7f51\u7edc&#xff1a;<\/p>\n<ul>\n<li>CuTe \u662f CUTLASS \u7684\u5185\u6838&#xff1a;CUTLASS 3.x \u7684 GEMM \u5b9e\u73b0\u5b8c\u5168\u5efa\u7acb\u5728 CuTe \u7684 Layout\/Tensor \u4e4b\u4e0a&#xff0c;CuTe \u662f&#034;\u5e93\u7684\u5e93&#034;\u3002<\/li>\n<li>CuTe DSL \u662f CuTe \u7684 Python \u95e8\u9762&#xff1a;\u5b83\u590d\u7528 CuTe \u7684\u5e03\u5c40\u601d\u60f3&#xff0c;\u4f46\u628a\u7f16\u8bd1\u671f\u6a21\u677f\u6362\u6210 Python \u8868\u8fbe&#xff0c;\u964d\u4f4e\u95e8\u69db\u3002<\/li>\n<li>cuTile \u4e0e CuTe\/CUTLASS \u540c\u5c5e NVIDIA \u751f\u6001&#xff1a;cuTile \u4f5c\u4e3a\u5b98\u65b9 Python DSL&#xff0c;\u5f88\u53ef\u80fd\u5728\u5e95\u5c42\u590d\u7528 CuTe \u7684\u5e03\u5c40\u4e0e CUTLASS \u7684 kernel \u751f\u6210\u80fd\u529b\u3002<\/li>\n<li>Triton \u4e0e TileLang \u662f\u7ade\u4e89\u4e0e\u501f\u9274\u5173\u7cfb&#xff1a;TileLang \u5728 tile \u62bd\u8c61\u4e0a\u6bd4 Triton \u66f4\u7ec6&#xff0c;\u4e8c\u8005\u90fd\u8d70&#034;Python &#043; \u7f16\u8bd1\u5668&#034;\u8def\u7ebf&#xff0c;TileLang \u53ef\u89c6\u4e3a Triton \u601d\u8def\u7684&#034;\u7cbe\u7ec6\u5316\u6f14\u8fdb&#034;\u3002<\/li>\n<li>ThunderKittens \u4e0e CuTe \u601d\u60f3\u76f8\u901a&#xff1a;\u90fd\u5f3a\u8c03 tile\/\u5e03\u5c40\u4e3a\u6838\u5fc3&#xff0c;\u4f46 ThunderKittens \u7528\u6781\u7b80\u5934\u6587\u4ef6\u5e93\u964d\u4f4e\u4f7f\u7528\u95e8\u69db&#xff0c;CuTe \u7528\u6a21\u677f\u5143\u7f16\u7a0b\u8ffd\u6c42\u6781\u81f4\u8868\u8fbe\u3002<\/li>\n<li>Mojo \u662f\u53e6\u4e00\u6761\u72ec\u7acb\u8d5b\u9053&#xff1a;\u5b83\u4e0d\u76f4\u63a5\u590d\u7528\u4e0a\u8ff0 DSL&#xff0c;\u800c\u662f\u4ece\u8bed\u8a00\u5c42\u9762\u91cd\u9020&#xff0c;\u4f46\u53ef\u901a\u8fc7 MLIR \u4e0e CUDA\/GPU \u540e\u7aef\u5bf9\u63a5&#xff0c;\u957f\u671f\u53ef\u80fd\u4e0e\u8fd9\u4e9b DSL \u5f62\u6210&#034;\u8bed\u8a00 vs \u5e93&#034;\u7684\u4e92\u8865\u3002<\/li>\n<li>Triton \u662f\u751f\u6001\u7c98\u5408\u5242&#xff1a;PyTorch torch.compile\u3001vLLM\u3001FlashAttention \u7b49\u5927\u91cf\u9879\u76ee\u57fa\u4e8e Triton&#xff0c;\u4f7f\u5b83\u6210\u4e3a\u4e8b\u5b9e\u4e0a\u7684&#034;Python GPU \u7f16\u7a0b\u6807\u51c6&#034;&#xff0c;\u5176\u4ed6\u65b9\u6848\u5f80\u5f80\u9700\u8981\u4e0e Triton \u751f\u6001\u4e92\u64cd\u4f5c\u3002<\/li>\n<\/ul>\n<p>\u4e00\u53e5\u8bdd\u603b\u7ed3&#xff1a;CuTe \u63d0\u4f9b\u5e03\u5c40\u7406\u8bba&#xff0c;CUTLASS \u63d0\u4f9b\u5de5\u7a0b\u5b9e\u8df5&#xff0c;Triton \u63d0\u4f9b Python \u751f\u4ea7\u529b&#xff0c;TileLang\/ThunderKittens \u63d0\u4f9b\u66f4\u7ec6\u6216\u66f4\u7b80\u7684 tile \u63a7\u5236&#xff0c;cuTile\/CuTe DSL \u662f NVIDIA \u628a CuTe \u601d\u60f3\u63a8\u5411 Python \u7684\u5b98\u65b9\u52a8\u4f5c&#xff0c;Mojo \u5219\u662f\u4ece\u8bed\u8a00\u5c42\u9762\u53e6\u8d77\u7089\u7076\u7684\u957f\u671f\u8d4c\u6ce8\u3002<\/p>\n<h3>6. \u9009\u578b\u5efa\u8bae<\/h3>\n<ul>\n<li>\u60f3\u5feb\u901f\u5199\u7b97\u5b50\u3001\u751f\u6001\u6210\u719f \u2192 Triton\u3002<\/li>\n<li>\u9700\u8981\u7cbe\u7ec6\u63a7\u5236\u6d41\u6c34\u7ebf\u3001\u69a8\u5e72\u6027\u80fd \u2192 TileLang \u6216 CuTe\u3002<\/li>\n<li>\u60f3\u7528 Python \u4f46\u8981\u597d\u5e03\u5c40\u63a7\u5236 \u2192 CuTe DSL \u6216 cuTile\u3002<\/li>\n<li>\u7814\u7a76\u65b0\u7b97\u5b50\u3001\u8ffd\u6c42\u4e0a\u624b\u901f\u5ea6 \u2192 ThunderKittens\u3002<\/li>\n<li>\u957f\u671f\u62bc\u6ce8 AI \u7cfb\u7edf\u8bed\u8a00 \u2192 Mojo\u3002<\/li>\n<li>\u6df1\u5ea6 CUTLASS \u7528\u6237 \u2192 CuTe&#xff08;C&#043;&#043;&#xff09;\u3002<\/li>\n<\/ul>\n<h3>7. \u7ed3\u8bed<\/h3>\n<p>GPU \u7f16\u7a0b DSL \u7684\u767e\u82b1\u9f50\u653e&#xff0c;\u672c\u8d28\u662f&#034;\u6027\u80fd&#034;\u4e0e&#034;\u751f\u4ea7\u529b&#034;\u8fd9\u5bf9\u77db\u76fe\u7684\u6301\u7eed\u535a\u5f08\u3002\u4ece CUTLASS \u7684\u6a21\u677f\u5de5\u7a0b&#xff0c;\u5230 Triton \u7684 Python \u62bd\u8c61&#xff0c;\u518d\u5230 CuTe \u7684\u5e03\u5c40\u7406\u8bba\u3001Mojo \u7684\u8bed\u8a00\u91cd\u9020&#xff0c;\u6bcf\u4e00\u4ee3\u65b9\u6848\u90fd\u5728\u8bd5\u56fe\u628a&#034;\u624b\u5199 CUDA \u7684\u75db\u82e6&#034;\u518d\u964d\u4f4e\u4e00\u70b9&#xff0c;\u540c\u65f6\u4e0d\u4e22\u6389\u786c\u4ef6\u6027\u80fd\u3002\u7406\u89e3\u5b83\u4eec\u7684\u65f6\u95f4\u7ebf\u4e0e\u76f8\u4e92\u5173\u7cfb&#xff0c;\u6bd4\u8bb0\u4f4f\u6bcf\u4e2a API \u66f4\u91cd\u8981\u2014\u2014\u56e0\u4e3a\u4e0b\u4e00\u4e2a\u65b9\u6848&#xff0c;\u5f88\u53ef\u80fd\u5c31\u662f\u8fd9\u4e9b\u601d\u60f3\u7684\u53c8\u4e00\u6b21\u91cd\u7ec4\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. \u5f15\u8a00&#xff1a;\u4e3a\u4ec0\u4e48 GPU \u7f16\u7a0b\u8bed\u8a00\u7a81\u7136\\&#8221;\u767e\u82b1\u9f50\u653e\\&#8221;<br \/>\n\u8fc7\u53bb\u5341\u5e74&#xff0c;\u5199 GPU \u9ad8\u6027\u80fd\u7b97\u5b50\u57fa\u672c\u53ea\u6709\u4e24\u6761\u8def&#xff1a;\u8981\u4e48\u7528 CUDA C \u624b\u5199&#xff0c;\u81ea\u5df1\u7ba1\u7ebf\u7a0b\u3001\u5171\u4eab\u5185\u5b58\u3001\u5bc4\u5b58\u5668\u3001\u6d41\u6c34\u7ebf&#xff1b;\u8981\u4e48\u7528 cuBLAS\/cuDNN \u8fd9\u7c7b\u5e93&#xff0c;\u727a\u7272\u7075\u6d3b\u6027\u6362\u6027\u80fd\u3002\u524d\u8005\u95e8\u69db\u6781\u9ad8&#xff0c;\u540e\u8005\u8986\u76d6\u4e0d\u5230\u65b0\u7b97\u5b50\u3002<br \/>\n\u968f\u7740\u5927\u6a21\u578b\u628a\u6ce8\u610f\u529b\u673a\u5236\u3001MoE\u3001\u91cf\u5316\u3001\u957f\u4e0a\u4e0b\u6587\u7b49\u65b0\u7b97\u5b50\u63a8\u5230\u53f0\u524d&#xff0c;\\&#8221;\u624b\u5199 CUDA \u592a\u6162\u3001\u8c03\u5e93\u4e0d\u591f\u7528\\&#8221;\u7684\u77db<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[11820,14163,14161,14162,5199,2112],"topic":[],"class_list":["post-123565","post","type-post","status-publish","format-standard","hentry","category-server","tag-atomgit","tag-cute","tag-gpu-dsl","tag-tilelang","tag-mojo","tag-triton"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/123565.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"1. \u5f15\u8a00&#xff1a;\u4e3a\u4ec0\u4e48 GPU \u7f16\u7a0b\u8bed\u8a00\u7a81\u7136&quot;\u767e\u82b1\u9f50\u653e&quot; \u8fc7\u53bb\u5341\u5e74&#xff0c;\u5199 GPU \u9ad8\u6027\u80fd\u7b97\u5b50\u57fa\u672c\u53ea\u6709\u4e24\u6761\u8def&#xff1a;\u8981\u4e48\u7528 CUDA C \u624b\u5199&#xff0c;\u81ea\u5df1\u7ba1\u7ebf\u7a0b\u3001\u5171\u4eab\u5185\u5b58\u3001\u5bc4\u5b58\u5668\u3001\u6d41\u6c34\u7ebf&#xff1b;\u8981\u4e48\u7528 cuBLAS\/cuDNN \u8fd9\u7c7b\u5e93&#xff0c;\u727a\u7272\u7075\u6d3b\u6027\u6362\u6027\u80fd\u3002\u524d\u8005\u95e8\u69db\u6781\u9ad8&#xff0c;\u540e\u8005\u8986\u76d6\u4e0d\u5230\u65b0\u7b97\u5b50\u3002 \u968f\u7740\u5927\u6a21\u578b\u628a\u6ce8\u610f\u529b\u673a\u5236\u3001MoE\u3001\u91cf\u5316\u3001\u957f\u4e0a\u4e0b\u6587\u7b49\u65b0\u7b97\u5b50\u63a8\u5230\u53f0\u524d&#xff0c;&quot;\u624b\u5199 CUDA \u592a\u6162\u3001\u8c03\u5e93\u4e0d\u591f\u7528&quot;\u7684\u77db\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/123565.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-11-07T09:56:43+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/123565.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/123565.html\",\"name\":\"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-11-07T09:56:43+00:00\",\"dateModified\":\"2026-11-07T09:56:43+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/123565.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/123565.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/123565.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/123565.html","og_locale":"zh_CN","og_type":"article","og_title":"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"1. \u5f15\u8a00&#xff1a;\u4e3a\u4ec0\u4e48 GPU \u7f16\u7a0b\u8bed\u8a00\u7a81\u7136\"\u767e\u82b1\u9f50\u653e\" \u8fc7\u53bb\u5341\u5e74&#xff0c;\u5199 GPU \u9ad8\u6027\u80fd\u7b97\u5b50\u57fa\u672c\u53ea\u6709\u4e24\u6761\u8def&#xff1a;\u8981\u4e48\u7528 CUDA C \u624b\u5199&#xff0c;\u81ea\u5df1\u7ba1\u7ebf\u7a0b\u3001\u5171\u4eab\u5185\u5b58\u3001\u5bc4\u5b58\u5668\u3001\u6d41\u6c34\u7ebf&#xff1b;\u8981\u4e48\u7528 cuBLAS\/cuDNN \u8fd9\u7c7b\u5e93&#xff0c;\u727a\u7272\u7075\u6d3b\u6027\u6362\u6027\u80fd\u3002\u524d\u8005\u95e8\u69db\u6781\u9ad8&#xff0c;\u540e\u8005\u8986\u76d6\u4e0d\u5230\u65b0\u7b97\u5b50\u3002 \u968f\u7740\u5927\u6a21\u578b\u628a\u6ce8\u610f\u529b\u673a\u5236\u3001MoE\u3001\u91cf\u5316\u3001\u957f\u4e0a\u4e0b\u6587\u7b49\u65b0\u7b97\u5b50\u63a8\u5230\u53f0\u524d&#xff0c;\"\u624b\u5199 CUDA \u592a\u6162\u3001\u8c03\u5e93\u4e0d\u591f\u7528\"\u7684\u77db","og_url":"https:\/\/www.wsisp.com\/helps\/123565.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-11-07T09:56:43+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"6 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/123565.html","url":"https:\/\/www.wsisp.com\/helps\/123565.html","name":"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-11-07T09:56:43+00:00","dateModified":"2026-11-07T09:56:43+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/123565.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/123565.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/123565.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"GPU \u7f16\u7a0b DSL \u5168\u666f\u5bf9\u6bd4\uff1aTileLang\u3001Triton\u3001Mojo\u3001cuTile\u3001CuTe\u3001ThunderKittens \u4e0e CuTe DSL"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/123565","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=123565"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/123565\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=123565"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=123565"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=123565"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=123565"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}