cuDNN makefile changes
Small cleanup changes on the build for cudnn. Added Windows support for cudnn. Tested on Ubuntu 22.04 and Windows 11.
-
Command line and Windows changes - (top part of the Makefile) Change from := to ?= so we can override the CUDNN_FRONTEND_PATH from the command line. (Upcoming: Fixing the locations for the CUDNN_FRONTEND_PATH for Windows and Linux to search for both $(HOME) or inside of llm.c directory)
-
cuDNN Windows support (in the middle of the Makefile)
-
Makefile cleanup - (lower part of Makefile) change "$<" to "$^" to pull in ALL of the dependencies. This eliminates the need to put (NVCC_CUDNN) on the recipe line. Removed linker files from object file compilation recipe.
I'm not amazing at Makefiles maybe there is a bit of a reasoning around what the changes here are and why they make sense?
@karpathy - notes on the above changes:
-
Command line and Windows changes - (top part of the Makefile) Change from := to ?= so we can override the CUDNN_FRONTEND_PATH from the command line. Fixing the locations for the CUDNN_FRONTEND_PATH to (HOMEDRIVE+HOMEPATH - as mentioned above - and current directory) for Windows and Linux.
-
cuDNN Windows support (in the middle of the Makefile)
-
Makefile cleanup - (lower part of Makefile) change "$<" to "$^" to pull in ALL of the dependencies. This eliminates the need to put (NVCC_CUDNN) on the recipe line. Removed linker files from object file compilation recipe.