38kHz isn't really fast, though.
I suspect this has more to do with not enough difference between 6V and the total LED drop.
The suspicion that the transistor has C and E reversed is a good one, too. Generally, a BJT will work with them reversed, but at a much lower gain and seriously degraded saturation.