xhp50 direct drive potentiometer dimmer

Hi! I had an idea of making a custom flashlight, with an xhp50 direct drive, single mode. I have made a small 8,4v batterypack, added charging port, and soon the xhp50, right know it has 2 xm-l2. Would it be possible to take a potentiometer and use it as a dimmer?
The light is an Airam 1000lumen big bulky maglite type thing, with a zoomy.

A potentiometer just dissipates power as heat.
Terribly inefficient for what you are trying to do.
Ramping driver is most preferable.

yeah, maybe, would be nice to just turn a knob you know.