Our Gemara on the top of Amud Aleph discusses how to relate to certain ambiguous phrases in the Torah. For example, if the Torah states “one shall not…”, depending on context, it might mean “he is not required” or it may mean “he is not allowed.” Regarding the Olah bird offering, it states: “‘But shall not separate it’ (Leviticus 5:8)? It means that the priest does not have to separate it, but not that it is prohibited to do so.”
In this text, “shall not separate” means “he is not required to separate,” but not that he is forbidden to separate it.
The Rambam (Laws of the Foundations of the Torah 5:4) rules that in the ordinary situations where one is not required to martyr himself for a commandment, it is also forbidden to do so. For example, if a person chose not to desecrate the Shabbos even under threat to his life, this is tantamount to the transgression of suicide. However, Kesef Mishne (ibid.) quotes other poskim who rule that a person may voluntarily choose to make a sacrifice and uphold the Torah even if it is life-threatening.
Sefer Daf al Daf applies our Gemara’s linguistic analysis to the Talmudic derivation from the verse (Vayikra 18:5) “And you shall live by them (the commandments).” The Gemara (Yoma 85b) rules this implies that one shall live by the Torah and not die by it. Therefore the commandments are not binding when in situations of mortal danger. Sefer Daf al Daf suggests that the dispute between the Rambam and the other poskim may depend on how you interpret “And you shall live by them.” The Rambam interprets this as “you are required to live by them,” while the other poskim interpret it as “you may live by them,” meaning to say: you may allow yourself to live by the commandments even if it means violating them to stay alive… but you are not required to and also can choose martyrdom.
Aside from the linguistic analysis of the verse, I will add that, derech derush, we can also support those who permit voluntary martyrdom. Even if we read the verse as obligating one to choose to live by the Torah, certain people whose standards of observance are so high, simply cannot consider themselves alive without Torah. The Torah is referred to as “eternal life” in the blessings of the Torah and rabbinic literature (see Berachos 21a). Quite literally, they cannot live without the Torah, and do not consider real life as anything other than eternal life. Therefore, for them it is not martyrdom at all but rather choosing life. (I was gratified to later see that Rav Kook [Mishpat Cohen 144] used a similar idea to explain how Rabbi Akiva martyred himself over washing for bread, as described in Eiruvin 21b: for Rabbi Akiva it was not life and death, but rather choosing eternal life over temporary life.)
Translations Courtesy of Sefaria, except when, sometimes, I disagree with the translation
Free resource for couples/families:
Over 80 lectures on heathy communication, marriage and sexuality from a Torah perspective Click here

If you liked this, you might enjoy my Relationship Communications Guide. Click on the link above.
Rabbi Simcha Feuerman, Rabbi Simcha Feuerman, LCSW-R, LMFT, DHL is a psychotherapist who works with high conflict couples and families. He can be reached via email at simchafeuerman@gmail.com