In a pot, boil the mirin and sake for 3 minutes, stirring often.
Add in sugar and miso and continue to cook a couple more minutes without boiling. Let it cool.
In a dish, add the cod and pour the marinade all over your fish, coating it very well. Cover it VERY tightly and marinate in the fridge for a minimum of 24 hours, but 2-3 days are recommended.
Preheat your broiler to 550℉.
Cover a baking sheet with aluminum foil and add your marinated cod. Place it on the middle rack of the oven and broil it for about 7 minutes, every oven is different so keep an eye out. The cod should be opaque and flake easily. I highly recommend an instant-read thermometer. Place it at the thickest part of the fish and the internal temperature should be 135℉ for medium-rare (recommended) or 145℉ for well done.