Up-to-date code

Should work for m1