You can have $3,000 in losses over and above and stock gains you recognized. So if you have $6,000 gains and $10,000 losses you write off $3,000 and carry forward the remaining $1,000.
I am answering just in case all the brilliant accountants are no longer here.