What does ‘jam’ mean?

( v ) To leave. The music’s getting too loud; I’m jamming.
( v ) To make music informally. After the gig last night, the group went over to Tooter’s and jammed the rest of the night.