This works for me:
MALLOC_CONF="prof:true,prof_gdump:true,prof_prefix:/path/to/files/jez" \
libexec/mysqld ...
libexec/mysqld ...
This does not work for me:
MALLOC_CONF="prof:true,prof_gdump:true" \
libexec/mysqld ...
MALLOC_CONF="prof:true,prof_gdump:true" \
libexec/mysqld ...