Paychecks got bigger last year for many of the top lawyers and executives at some of the nation’s largest companies—though some groups have been receiving larger pay bumps than their colleagues, according to a new study.

General counsel received a larger percentage increase than their bosses, though CEOs were paid much more to start: The total median pay for CEOs who work for Equilar 500 companies, a revenue-based index of publicly traded companies in the U.S., increased 3.5 percent from 2016 to 2017, while general counsel at those same companies saw a 6.7 overall pay increase.