If these were acute effects, my advice would be: wait a week or so for the PCP to clear out of your system. Having lots of Vitamin C and acidic drinks like grapefruit juice, and getting lots of fluids in general will speed the process.
PCP is a strong dissociative drug that used to be used for anesthesia in humans in the 50's and animals up til the 80's (I think) until abuse and problems with the long half-life and strange psychiatrric effects forced it out of usage. In large doses it can cause very strange symptoms such as near death experiences, memory loss, hallucinations, not feeling your body, objects changing size, and loss of balance or motor skills, that last for some time. PCP is actually so fat solubl, some of it is re-absorbed form your bladder.
Some people think high dose usage of dissociative drugs (other dissociatives are ketamine, MXE/methoxetamine, and DXM/dextromethorphan) causes "holes in your brain" called Olney's lesions, but they have never been proven to exist in humans, just in rats (and monkeys when compounds are injected directly into the brain). They have, however, been proven to make changes in brain structure even with a few doses. Whether or not this is positive remains to be seen, but rumour has it that ketamine is an effective antidepressant in low doses. (It's not so effective in higher doses.)
We can't identify what it is that you smoked, but it's probably not formaldehyde. Formaldehyde is very toxic and is not psychoactive. It is used as actual embalming fluid and is usually mixed with methanol.
I suggest you see a doctor, counsellor, or psychiatrist if you are still having mental problems after the trip. It's likely it was a very taxing experience on your body and mind and it will take some time to feel 100% normal again. PCP and other dissociatives have been klnown to replicate schizophrenia, so maybe they have indced it in you (especially if you have a family history of such).
After DXM usage (a similar long-action dissociative drug that can be very p[otent when taken at high doses) it can take people up to a year to feel proper again. Try not to worry about permanent damage, focus on feeling better and dealing with your cognitive impairment as best you can.
I am going to close this thread because we can only speculate.