[Dev] gen_loader.py and generate_ptable.sh