The computations of basic and diluted earnings (loss) per share were as follows: | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Three Months Ended June 30, | | Six Months Ended June 30, | | (In millions, except per share data) | | 2021 | | 2020 | | 2021 | | 2020 | | Basic earnings (loss) per common share | | | | | | | | | | Net income (loss) attributable to XPO | | $ | 156 | | | $ | (131) | | | $ | 271 | | | $ | (108) | | | Series A preferred stock dividends | | — | | | (1) | | | — | | | (2) | | |
| Net income (loss) attributable to common shares, basic | | $ | 156 | | | $ | (132) | | | $ | 271 | | | $ | (110) | | | | | | | | | | | | Basic weighted-average common shares | | 112 | | | 91 | | | 109 | | | 92 | | | Basic earnings (loss) per share | | $ | 1.39 | | | $ | (1.45) | | | $ | 2.48 | | | $ | (1.20) | | | | | | | | | | | | Diluted earnings (loss) per common share | | | | | | | | | | Net income (loss) attributable to common shares, diluted | | $ | 156 | | | $ | (132) | | | $ | 271 | | | $ | (110) | | | | | | | | | | | | Basic weighted-average common shares | | 112 | | | 91 | | | 109 | | | 92 | | | Dilutive effect of stock-based awards and warrants | | 1 | | | — | | | 4 | | | — | | | Diluted weighted-average common shares | | 113 | | | 91 | | | 113 | | | 92 | | | | | | | | | | | | Diluted earnings (loss) per share | | $ | 1.38 | | | $ | (1.45) | | | $ | 2.40 | | | $ | (1.20) | | | | | | | | | | | | Potential common shares excluded | | — | | | 20 | | | — | | | 21 | |
|