An article at Medical News Today reviews recent research published in Sweeden, suggesting lower IQ is related to more suicide attempts, even when controlling for many other factors. However, the presence of psychosis increases the risk of suicide attempt, regardless of IQ. This looks to be a study I would want more time to review in detail before drawing any conclusions, though the authors offer several theories that seem plausible:
Speculating on the reasons behind the link, they suggested perhaps because people with lower IQ tend to have lower socioeconomic status and income, they could face more social and financial hardship, leading to their having more suicidal thoughts and behaviours.
They also mentioned that unhealthy lifestyle (eg binge drinking) has also been linked with lower IQ, and this could also affect frequency of suicidal thinking, plus other studies have also linked lower IQ with lower problem solving skills, and this could affect resilience to stress.
Sort of seems like a perpetual cycle: the individuals who may be somewhat less able to handle certain stressors end up facing more of them, leading to more problems, etc. In any event, this looks to be a good article to read.