Changes in Gross Unrecognized Tax Benefits Related to Uncertain Tax Positions (Detail) - USD ($) $ in Millions |
12 Months Ended | ||
|---|---|---|---|
Jun. 30, 2020 |
Jun. 30, 2019 |
Jun. 30, 2018 |
|
| Income Tax Disclosure [Abstract] | |||
| Beginning unrecognized tax benefits | $ 13,146 | $ 11,961 | $ 11,737 |
| Decreases related to settlements | (31) | (316) | (193) |
| Increases for tax positions related to the current year | 647 | 2,106 | 1,445 |
| Increases for tax positions related to prior years | 366 | 508 | 151 |
| Decreases for tax positions related to prior years | (331) | (1,113) | (1,176) |
| Decreases due to lapsed statutes of limitations | (5) | 0 | (3) |
| Ending unrecognized tax benefits | $ 13,792 | $ 13,146 | $ 11,961 |