Is Hammer actually crashing or just "Not Responding"? There's a big difference. Hammer will normally enter a "Not Responding" state when compiling; even though Hammer will appear to be broken, it is, in fact, still working in the background. The "Not Responding" state is a side effect of the Source engine's lackluster UI design. Patience is your friend here; unless your map is absurdly big and/or poorly optimized, a fast compile shouldn't take more than a minute.