Martin, who turns 25 in November, was a third-round pick in 2014. He started 24 of 26 games he played in San Francisco from 2014-2016. He was demoted to a backup role in 2016 before being released the next offseason.
The Browns claimed Marcus off waivers and he was with them all of last season, but was on the inactive list every week.
Martin now joins the Cowboys with a likely role as the primary backup at guard and center, both of which he's played in the NFL. He will fill the role last occupied by Joe Looney, who remains an unsigned free agent.
Coincidentally, Looney was also originally drafted by the 49ers and then spent one year with another team (Tennessee Titans) before coming to Dallas.