You need to know the current.
The power dissipation is the voltage drop times the current. In your case the voltage drop is 15.5 - 3.3 so it's 12.2
The LM317M has a thermal resistance of 50 dec C / W with no heatsink, according to the STM data sheet, and a maximum temperature of 125 deg C. If you are running in air at 40 degrees C, then you can let it heat up by 85 deg C, so it can dissipate 85 / 50 = 1.7 W, so it can take 1.7 / 12.2 = 139 mA with no heat sink.
If you are taking more than that, the thermal resistance of the junction to the case is 3 deg C / W, so you should add that to the rating of any heatsink you use.
If you had a heatsink rated at 10 deg C / W, the total would be 13 deg C / W, and you could go to 85 / 13 = 6.5 W, so about half an amp.
You should always go for a larger heatsink if in doubt.