Gibraltar yes but don't drive across the border, park in La Linea if you must drive. There are multiple coaches from Malaga
Tangier seems like it would take a long time to get to, so unless the journey is the point of going I wouldn't.
Agree. I've been to both, though took the ferry to Tangier as a starting point for a driving trip thru Morrocco. I found Gibralter quite interesting. I would not do Tangier as a day trip.