In our case, assuming that the level of danger for a particular individual is within the parameter recognized by halakha as dangerous, then it would be not only permissible, but obligatory to perform any non-cardinal sin to escape these circumstances. All the more so, it would be permissible to enter a situation where the sin itself is not guaranteed.
There is a general principle in halakha, stated in the Tosefta Shabbat (9:22), that nothing supersedes the protection of life:
ואם היה דבר של סכנה אין כל דבר עומד בפני פקוח נפש
The only exception to this is in the case of cardinal sins (ibid 15:17):
דין הוא שידחו את השבת להחיות נפש בספק הא לא נתנו מצות לישראל אלא לחיות בהן שנ' אשר יעשה אותם האדם וחי בהם וחי בהן ולא שימות בהן אין כל דבר עומד בפני פקוח נפש חוץ מע"ז וגלוי עריות ושפיכות דמים
This is quoted by the Talmud as well (Yoma 82a), and the resultant law is codified by Rambam (Hilkhot Ma'akhalot Assurot (14:4) and Hilkhot Sh'vitat Assor 2:9) and the Shulhan Arukh (OH 617:2).
As is implied by the language above, even mere danger to life; not just certain death, allows one to violate any non-cardinal sin. This is also the implication of the Mishna Yoma (8:6) that one violates the Sabbath, even when this will not guarantee a life being saved, such as in a case where the victim may already be dead.
Edit: This has been getting a lot of commentless downvotes, so it could be it wasn't clear enough. To further clarify: it is pretty much impossible to prove the negative. If someone asks whether he may eat non-kosher food to save a life... On Tuesday, then if answer is 'yes', because the day of the week is not significant, then by definition there will be no sources that answer the question, and the best one will be able to do, is find general sources that omit the distinction. Similarly, here the OP introduces the possibility of a new legal category in the realm of yehareg v'al ya'avor; "irreligious". AFAIK this category does not exist as a relevant variable in the realm of yehareg v'al ya'avor.
Given that there is no evidence that "irreligious" is a discrete halakhic category in the realm of cardinal sins, halakhically, it is just the composite of multiple sins. Thus, the best possible answer quotes the classical sources and notes the universal ruling of ya'avor v'al yehareg for all non-cardinal sins, with no exceptions made for sins on Tuesdays, or the "sin" of being irreligious.
As mentioned in the comments,there is a category of sh'mad, which has specific parameters, in the realm of yehareg v'al ya'avor, but being "irreligious" is not sh'mad.