If you are EWI, then marriage to a US Citizen will not necessarily resolve your immigration status. You would have to apply for a waiver (either an I-601 or I-601A), along with many other things.
If you are out of status, but originally entered the United States legally, you should be able to adjust using the I-130 and I-485.
Obviously, your situation is complex. Moreover, you should know that the government fees in immigration are surprisingly high. Don't waste that money; be sure that you are taking the right approach. Interview some attorneys familiar with your type of case. And do not leave the country without an experienced immigration attorney having handled the matter.