You have to use AP to leave US, no matter you want to get a new H-1B visa or something else, other wise UCIS thinks you give up your GC application.
In case your I-485 is denied, you would have to leave US if you worked with EAD.
Suggestion: get a new H-1B job ASAP unless you have enough money to wait for your I-485 approval.