In Pathfinder, evil souls may end up in Hell, the Abyss or Abaddon, where various unpleasant fates await them, but how is it determined which plane an evil soul ends up in? I know Pharasma judges the souls, but how does she decide if they go to Hell, the Abyss or Abaddon?
The answer to that is somewhat complicated, and while a soul's postmortem destination is partially influenced by the soul's alignment, that decision process has some other inputs.
The Great Beyond says:
While the River of Souls arrives at Pharasma’s domain atop the Spire, not all souls undergo the same process. Some souls come having already made their choices via their actions and beliefs, while others with more conflicted natures — or pre-existing pacts to specific entities — make their decisions at the advice or temptation of infernal and divine suitors, who are eager to sway their spirits in one ideological direction or another, or with Pharasma’s direct arbitration if need be.
Each of the Eight Courts—one for each aligned plane of the Outer Sphere—sprawls across dozens of miles and draws the souls of those whose inner natures mirror those of their linked planes, or the souls of those pledged to specific deities dwelling on those planes.
As souls flow into Pharasma's Court, some are chosen by the gods they worshipped specifically, and those that are not (either because they didn't hold strongly to a god, or because their patron deity thinks they're a dink) directly gravitate towards one of the eight alignment-linked courts. If you worshipped Sarenrae then more than likely you go to her plane, unless your worship was non-true enough that your alignment outweighs it; souls not beholden to a specific god sort out by alignment if strongly aligned. (Neutral souls not beholden to a god are a special case, they pass through the Graveard of Souls into the Spirelands).
Atheists end up in the Graveyard of Souls, regardless of alignment.
Souls that are split in allegiance - like halfway between Axis and Hell from being LN/LE, or are an edge case (like were CE a lot of their life but converted to the faith of Sarenrae at death) go to the Inner Court where interested parties advocate their cases to the conflicted soul itself to come to a final judgement.
Souls pledged to a specific plane by contract (usually, by an infernal power) but that have tried to seek redemption are the trickiest cases and are judged by the goddess herself in her palace.
Some souls, regardless of alignment, choose to go into the Lake of Mortal Reflections to be reborn on Golarion.
So if there's not a specific deity in play, or other special case, then it's usually "by alignment." But people are more complicated than that, and thus so is Pharasma's judgement. (This process is also explained to some degree in Gods and Magic and Inner Sea Gods).
The judgement process and petitioners, and the life of the soul before and after all this, are examined even more in depth in the River of Souls article in Mummy's Mask AP Chapter 6, Secrets of the Sky Pharaoh.