cuda-oxide:hello-constant 拆解 11(完结)——GPU 执行 + 结果回传 拆 hello-constant 系列最终站。cuLaunchKernel 返回后 GPU 接管,256 个线程并行执行 SASS。本文讲清楚 SM 调度 + warp 锁步、printf buffer 的延迟 flush 机制、benign race(良性竞争)、cuStreamSynchronize + cuMemcpyDtoH 的回传链路,以及为什么 thread xxx: 42 在 Output: 42 之前出现。 zTgx 0 0 0 专题cuda-oxidecuda-driver
cuda-oxide:hello-constant 拆解 10——host binary 启动 + CUDA driver 加载 PTX 拆 hello-constant 系列第十站。device 编译完成,host 端 binary 启动——通过 CUDA driver API 一步步连 GPU、分配显存、加载 PTX(driver 现场 JIT 编译成 SASS)、launch kernel。本文讲清楚 cuda-core 怎么包装 driver API,以及 cuModuleLoad 触发的 JIT 是整条链路里最'魔法'的一步。 zTgx 1 0 0 专题cuda-oxidecuda-driver