Retirement tax questions

See draft of 1040 Schedule 1-A page 2 part V
https://www.irs.gov/pub/irs-dft/f1040s1a--dft.pdf

 

Line 31 starts with your MAGI from line 3,  which is the AGI on 1040 line 11b plus any income from form 2555 lines 45 & 50 plus form 4563 line 11.