owned foreign corporation by a domestic corporation which is a United States shareholder with respect to such foreign corporation, there shall be allowed as a deduction an amount equal to the foreign-source portion of such dividend. (b) Specified 10-percent owned foreign corporation For purposes of this section, the term specified 10-percent owned foreign corporation means any foreign corporation with respect to which any domestic corporation is a United States shareholder. Such term shall not include any passive foreign investment company (within the meaning of subpart D of part VI of subchapter P) that is not a controlled foreign corporation. (c) Foreign-source portion For purposes of this section— (1) In general The foreign-source portion of any dividend is an amount which bears the same ratio to such dividend as— (A) the post-1986 undistributed foreign earnings of the specified 10-percent owned foreign corporation, bears to (B) the total post-1986 undistributed earnings of such foreign corporation. (2) Post-1986 undistributed earnings The term post-1986 undistributed earnings means the amount of the earnings and profits of the specified 10-percent owned foreign corporation (computed in accordance with sections 964(a) and 986) accumulated in taxable years beginning after December 31, 1986— (A) as of the close of the taxable year of the specified 10-percent owned foreign corporation in which the dividend is distributed, and (B) without diminution by reason of dividends distributed during such taxable year. (3) Post-1986 undistributed foreign earnings The term post-1986 undistributed foreign earnings means the portion of the post-1986 undistributed earnings which is attributable to neither— (A) income described in subparagraph (A) of section 245(a)(5), nor (B) dividends described in subparagraph (B) of such section (determined without regard to section 245(a)(12)). (4) Treatment of distributions from earnings before 1987 (A) In general In the case of any dividend paid out of earnings and profits of the