Get a toolchain from ARM's developer site
Extract this toolchain somewhere convenient.
cd armgcc ARMGCC_DIR=/path/to/gcc-arm-none-eabi ./build_release.sh
Output files will be in the release folder. There will be an ELF file (if you want to debug), and a bin file to upload to your device.
mdt push armgcc/release/hello_world_tflite.bin
sudo cp hello_world_tflite.bin /boot cd /boot sudo ln -sf hello_world_tflite.bin m4_fw.bin
setenv m4enabled 1 saveenv boot
Output from the M4 core will be visible on the second UART that enumerated when you connected your serial port via USB.