| | | | | | | | | | | | | | | | | | | | | |
<?xml version="1.0" encoding="windows-1252"?> |
<!-- XBRL Document Created with the Workiva Platform --> |
<!-- Copyright 2024 Workiva --> |
<!-- r:8e93c311-05d2-428c-8176-211a3d3157c9,g:3a98e0f3-6661-4f31-86b9-445af0545836 --> |
<link:linkbase xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd"> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/ConsolidatedBalanceSheets" xlink:type="simple" xlink:href="xfor-20231231.xsd#ConsolidatedBalanceSheets"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/ConsolidatedBalanceSheets" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_Assets"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_a95387ad-efa4-4a73-8a2b-26c961573ca9" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AssetsCurrent"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:to="loc_us-gaap_AssetsCurrent_a95387ad-efa4-4a73-8a2b-26c961573ca9" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_176b90ba-7ebb-4454-82f8-d854e101cb0a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PropertyPlantAndEquipmentNet"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_176b90ba-7ebb-4454-82f8-d854e101cb0a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_2ec69ba3-94c4-4f9e-8bf7-603569c54399" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingLeaseRightOfUseAsset"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_2ec69ba3-94c4-4f9e-8bf7-603569c54399" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Goodwill_ea22d424-041f-463b-bc2b-bcbaa0bb650b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_Goodwill"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:to="loc_us-gaap_Goodwill_ea22d424-041f-463b-bc2b-bcbaa0bb650b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_e9dfd12f-adcc-460c-9292-d2e21d6d2517" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OtherAssetsNoncurrent"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_062765a4-e76b-4d70-ba5b-50a4e160ceee" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_e9dfd12f-adcc-460c-9292-d2e21d6d2517" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_9f3590cc-68a8-4f1f-b878-038fa4f141af" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_StockholdersEquity"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommonStockValue_a60b7704-ed23-4715-a6cc-59a0bf6eafa9" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CommonStockValue"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_9f3590cc-68a8-4f1f-b878-038fa4f141af" xlink:to="loc_us-gaap_CommonStockValue_a60b7704-ed23-4715-a6cc-59a0bf6eafa9" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_d2973e68-8b65-42bf-bdae-cb3cb1922191" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_9f3590cc-68a8-4f1f-b878-038fa4f141af" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_d2973e68-8b65-42bf-bdae-cb3cb1922191" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AdditionalPaidInCapitalCommonStock_2590c5d6-4359-4acb-b08b-d1eefb0ee3bb" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AdditionalPaidInCapitalCommonStock"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_9f3590cc-68a8-4f1f-b878-038fa4f141af" xlink:to="loc_us-gaap_AdditionalPaidInCapitalCommonStock_2590c5d6-4359-4acb-b08b-d1eefb0ee3bb" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_7f99eb66-25bf-48c8-a3c9-a1a7745ce589" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_RetainedEarningsAccumulatedDeficit"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_9f3590cc-68a8-4f1f-b878-038fa4f141af" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_7f99eb66-25bf-48c8-a3c9-a1a7745ce589" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_407190a8-01de-4f1e-b561-310866c3b03c" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LiabilitiesCurrent"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityCurrent_0b11c530-c11c-4d30-983e-8c1e57ac4e80" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingLeaseLiabilityCurrent"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_407190a8-01de-4f1e-b561-310866c3b03c" xlink:to="loc_us-gaap_OperatingLeaseLiabilityCurrent_0b11c530-c11c-4d30-983e-8c1e57ac4e80" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_e3fa9b7b-c0e7-4d54-b12e-925dd6a670a6" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccruedLiabilitiesCurrent"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_407190a8-01de-4f1e-b561-310866c3b03c" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_e3fa9b7b-c0e7-4d54-b12e-925dd6a670a6" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableCurrent_5cb3730d-61f7-44e6-ad73-fd0abef76620" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccountsPayableCurrent"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_407190a8-01de-4f1e-b561-310866c3b03c" xlink:to="loc_us-gaap_AccountsPayableCurrent_5cb3730d-61f7-44e6-ad73-fd0abef76620" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtCurrent_1af70b68-1b2a-40e3-b4ad-07e9659ad84b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LongTermDebtCurrent"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_407190a8-01de-4f1e-b561-310866c3b03c" xlink:to="loc_us-gaap_LongTermDebtCurrent_1af70b68-1b2a-40e3-b4ad-07e9659ad84b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_8e10ccc4-abe5-45fc-bf14-9b42875f9a99" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LiabilitiesAndStockholdersEquity"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_162e9edb-2607-4717-9e86-438130443f2d" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_Liabilities"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_8e10ccc4-abe5-45fc-bf14-9b42875f9a99" xlink:to="loc_us-gaap_Liabilities_162e9edb-2607-4717-9e86-438130443f2d" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_a159302b-931f-4588-9f15-23dda838ad63" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_StockholdersEquity"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_8e10ccc4-abe5-45fc-bf14-9b42875f9a99" xlink:to="loc_us-gaap_StockholdersEquity_a159302b-931f-4588-9f15-23dda838ad63" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommitmentsAndContingencies_5f06fecf-ddf7-42e2-89ca-d47e0a2c203b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CommitmentsAndContingencies"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_8e10ccc4-abe5-45fc-bf14-9b42875f9a99" xlink:to="loc_us-gaap_CommitmentsAndContingencies_5f06fecf-ddf7-42e2-89ca-d47e0a2c203b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_Liabilities"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_LongTermDebtNonCurrentIncludingAccrection_d17c8877-d2ca-4eca-9cff-ffd3f296dcec" xlink:href="xfor-20231231.xsd#xfor_LongTermDebtNonCurrentIncludingAccrection"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:to="loc_xfor_LongTermDebtNonCurrentIncludingAccrection_d17c8877-d2ca-4eca-9cff-ffd3f296dcec" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_167632b1-f4a2-4ba1-9307-f9813ae4c63f" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OtherLiabilitiesNoncurrent"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_167632b1-f4a2-4ba1-9307-f9813ae4c63f" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_55b1e145-1445-4157-a223-39a61f946d67" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LiabilitiesCurrent"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:to="loc_us-gaap_LiabilitiesCurrent_55b1e145-1445-4157-a223-39a61f946d67" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_cc6f53af-db94-48ef-895a-05ca3a14f4fd" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingLeaseLiabilityNoncurrent"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:to="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_cc6f53af-db94-48ef-895a-05ca3a14f4fd" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitiesNoncurrent_539723e7-f110-4b6e-9456-b2e24817e30b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DerivativeLiabilitiesNoncurrent"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_9852b007-9d07-4344-8dfb-0a0e30f1d695" xlink:to="loc_us-gaap_DerivativeLiabilitiesNoncurrent_539723e7-f110-4b6e-9456-b2e24817e30b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_1f1e2578-51c4-4775-8dba-a17594dad0f0" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AssetsCurrent"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_ResearchAndDevelopmentIncentiveReceivable_21fcf553-b269-4d1b-8d1e-0f4d377a779a" xlink:href="xfor-20231231.xsd#xfor_ResearchAndDevelopmentIncentiveReceivable"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_1f1e2578-51c4-4775-8dba-a17594dad0f0" xlink:to="loc_xfor_ResearchAndDevelopmentIncentiveReceivable_21fcf553-b269-4d1b-8d1e-0f4d377a779a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_33fb3dd1-d2d8-4ca2-9f5f-4448c86c6082" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_1f1e2578-51c4-4775-8dba-a17594dad0f0" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_33fb3dd1-d2d8-4ca2-9f5f-4448c86c6082" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_74eeb386-f9e4-4655-9f2d-e21789a71dd5" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_1f1e2578-51c4-4775-8dba-a17594dad0f0" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_74eeb386-f9e4-4655-9f2d-e21789a71dd5" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MarketableSecurities_5f7623a4-6959-4e9d-945b-64b6ab919018" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_MarketableSecurities"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_1f1e2578-51c4-4775-8dba-a17594dad0f0" xlink:to="loc_us-gaap_MarketableSecurities_5f7623a4-6959-4e9d-945b-64b6ab919018" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/ConsolidatedStatementsofOperationsandComprehensiveLoss" xlink:type="simple" xlink:href="xfor-20231231.xsd#ConsolidatedStatementsofOperationsandComprehensiveLoss"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/ConsolidatedStatementsofOperationsandComprehensiveLoss" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingExpenses_01950c52-0de2-4cc3-8c59-7714a57d0c8c" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingExpenses"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_ea4a97fd-daef-4a62-bfb4-eb22fc18ee3a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GeneralAndAdministrativeExpense"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingExpenses_01950c52-0de2-4cc3-8c59-7714a57d0c8c" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_ea4a97fd-daef-4a62-bfb4-eb22fc18ee3a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ResearchAndDevelopmentExpense_99efb0f9-811d-4b37-ad39-bc6a902ea5eb" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ResearchAndDevelopmentExpense"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingExpenses_01950c52-0de2-4cc3-8c59-7714a57d0c8c" xlink:to="loc_us-gaap_ResearchAndDevelopmentExpense_99efb0f9-811d-4b37-ad39-bc6a902ea5eb" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_65c0c7ec-054c-4a0c-8f2a-57fd76547dd6" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GainLossOnDispositionOfIntangibleAssets"/> |
| | <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingExpenses_01950c52-0de2-4cc3-8c59-7714a57d0c8c" xlink:to="loc_us-gaap_GainLossOnDispositionOfIntangibleAssets_65c0c7ec-054c-4a0c-8f2a-57fd76547dd6" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GoodwillImpairmentLoss_6df8eebd-8a03-49b2-8766-4797f043d11c" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GoodwillImpairmentLoss"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingExpenses_01950c52-0de2-4cc3-8c59-7714a57d0c8c" xlink:to="loc_us-gaap_GoodwillImpairmentLoss_6df8eebd-8a03-49b2-8766-4797f043d11c" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NonoperatingIncomeExpense_0bbeabac-ff2d-459b-97d1-d9857fc91efe" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NonoperatingIncomeExpense"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_fe731d64-8a0a-43b1-82cd-0f359369a5d8" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OtherNonoperatingIncomeExpense"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NonoperatingIncomeExpense_0bbeabac-ff2d-459b-97d1-d9857fc91efe" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_fe731d64-8a0a-43b1-82cd-0f359369a5d8" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpense_97b0d79e-b4f7-4fca-8f44-9a8cacc563d7" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_InterestExpense"/> |
| | <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NonoperatingIncomeExpense_0bbeabac-ff2d-459b-97d1-d9857fc91efe" xlink:to="loc_us-gaap_InterestExpense_97b0d79e-b4f7-4fca-8f44-9a8cacc563d7" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeGainLossOnDerivativeNet_790296ff-08f5-46df-a1f9-4d2c67c014b2" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DerivativeGainLossOnDerivativeNet"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NonoperatingIncomeExpense_0bbeabac-ff2d-459b-97d1-d9857fc91efe" xlink:to="loc_us-gaap_DerivativeGainLossOnDerivativeNet_790296ff-08f5-46df-a1f9-4d2c67c014b2" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InvestmentIncomeInterest_551e3607-d5b4-449d-9223-7334c814819d" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_InvestmentIncomeInterest"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NonoperatingIncomeExpense_0bbeabac-ff2d-459b-97d1-d9857fc91efe" xlink:to="loc_us-gaap_InvestmentIncomeInterest_551e3607-d5b4-449d-9223-7334c814819d" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_bfdee1f7-46a5-4858-b229-67a674b76aa7" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_26a4a324-b621-4986-ba0d-981b6a97c5d6" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetIncomeLoss"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_bfdee1f7-46a5-4858-b229-67a674b76aa7" xlink:to="loc_us-gaap_NetIncomeLoss_26a4a324-b621-4986-ba0d-981b6a97c5d6" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_TemporaryEquityRepurchaseOfConvertiblePreferredStock_2aa5cdc6-156e-4f27-b568-02f4b0ac2fe5" xlink:href="xfor-20231231.xsd#xfor_TemporaryEquityRepurchaseOfConvertiblePreferredStock"/> |
| | <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_bfdee1f7-46a5-4858-b229-67a674b76aa7" xlink:to="loc_xfor_TemporaryEquityRepurchaseOfConvertiblePreferredStock_2aa5cdc6-156e-4f27-b568-02f4b0ac2fe5" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_32a97d70-4490-49ad-9edb-316f91e19d51" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_39904c6f-9b79-4d10-949a-0427ebbb7de4" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingIncomeLoss"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_32a97d70-4490-49ad-9edb-316f91e19d51" xlink:to="loc_us-gaap_OperatingIncomeLoss_39904c6f-9b79-4d10-949a-0427ebbb7de4" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NonoperatingIncomeExpense_5e36976a-1a6c-4d6b-be51-827752d3482d" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NonoperatingIncomeExpense"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_32a97d70-4490-49ad-9edb-316f91e19d51" xlink:to="loc_us-gaap_NonoperatingIncomeExpense_5e36976a-1a6c-4d6b-be51-827752d3482d" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_8b5e34d9-697a-444a-9f41-ed0b293fc78b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingIncomeLoss"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingExpenses_3db7da03-1c68-4f33-9128-e7e0ad296cef" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingExpenses"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_8b5e34d9-697a-444a-9f41-ed0b293fc78b" xlink:to="loc_us-gaap_OperatingExpenses_3db7da03-1c68-4f33-9128-e7e0ad296cef" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_5c665b21-f6d4-420e-9e5d-8a624626294e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetIncomeLoss"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_bebba321-513e-4c25-a6eb-ddd2b2bbd111" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_5c665b21-f6d4-420e-9e5d-8a624626294e" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_bebba321-513e-4c25-a6eb-ddd2b2bbd111" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_0158e566-7a8c-4c25-8b6d-b9c6d2d81614" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeTaxExpenseBenefit"/> |
| | <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_5c665b21-f6d4-420e-9e5d-8a624626294e" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_0158e566-7a8c-4c25-8b6d-b9c6d2d81614" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/ConsolidatedStatementsofCashFlows" xlink:type="simple" xlink:href="xfor-20231231.xsd#ConsolidatedStatementsofCashFlows"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/ConsolidatedStatementsofCashFlows" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RepaymentsOfLongTermDebt_56563e95-b117-4302-8888-712b0294d828" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_RepaymentsOfLongTermDebt"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_us-gaap_RepaymentsOfLongTermDebt_56563e95-b117-4302-8888-712b0294d828" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_ProceedsFromIssuanceOrSaleOfEquityNetOfIssuanceCosts_49cbed9f-9df8-4f7b-8731-c1a7439d5795" xlink:href="xfor-20231231.xsd#xfor_ProceedsFromIssuanceOrSaleOfEquityNetOfIssuanceCosts"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_xfor_ProceedsFromIssuanceOrSaleOfEquityNetOfIssuanceCosts_49cbed9f-9df8-4f7b-8731-c1a7439d5795" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_ProceedsFromExerciseOfStockOptionsAndWarrants_c6bd8f30-69d0-4223-a992-51177492975e" xlink:href="xfor-20231231.xsd#xfor_ProceedsFromExerciseOfStockOptionsAndWarrants"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_xfor_ProceedsFromExerciseOfStockOptionsAndWarrants_c6bd8f30-69d0-4223-a992-51177492975e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_2d2f6592-cfd1-4d58-839b-7383f3fa1b6c" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfOtherLongTermDebt_2d2f6592-cfd1-4d58-839b-7383f3fa1b6c" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_df40641a-7390-45b7-9a7b-fddff7e8822e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation"/> |
| | <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_df40641a-7390-45b7-9a7b-fddff7e8822e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_0fb8e53b-8d67-407b-9928-652f262360fb" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PaymentsForRepurchaseOfCommonStock"/> |
| | <link:calculationArc order="6" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_0fb8e53b-8d67-407b-9928-652f262360fb" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_IssuanceCostsRelatedToSaleOfWarrantsAndFeesPaidForAmendmentsToLoanAndSecurityAgreement_3c7ad72b-a4ea-4760-9120-7d868ac5f8bb" xlink:href="xfor-20231231.xsd#xfor_IssuanceCostsRelatedToSaleOfWarrantsAndFeesPaidForAmendmentsToLoanAndSecurityAgreement"/> |
| | <link:calculationArc order="7" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_ef468144-b303-48f0-a5a0-d5419db963a5" xlink:to="loc_xfor_IssuanceCostsRelatedToSaleOfWarrantsAndFeesPaidForAmendmentsToLoanAndSecurityAgreement_3c7ad72b-a4ea-4760-9120-7d868ac5f8bb" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_42408024-655d-4643-b429-f0b177464dde" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_ba4c01d6-678d-46c6-852f-1f3c31520cc9" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_42408024-655d-4643-b429-f0b177464dde" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_ba4c01d6-678d-46c6-852f-1f3c31520cc9" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_68d81482-0172-40a3-a089-fcac981b8eaa" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_42408024-655d-4643-b429-f0b177464dde" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_68d81482-0172-40a3-a089-fcac981b8eaa" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_c87db4e0-fe03-48a3-ab3e-8779b957a24e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_42408024-655d-4643-b429-f0b177464dde" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_c87db4e0-fe03-48a3-ab3e-8779b957a24e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_19e78c36-21a7-4365-85a8-0c9115e238cb" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_42408024-655d-4643-b429-f0b177464dde" xlink:to="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_19e78c36-21a7-4365-85a8-0c9115e238cb" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_09f0bad0-f7d4-4062-85c6-af6960bde603" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_09f0bad0-f7d4-4062-85c6-af6960bde603" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProfitLoss_85f41d07-cf97-4512-9c0b-2bf79aaae45e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ProfitLoss"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_ProfitLoss_85f41d07-cf97-4512-9c0b-2bf79aaae45e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_IncreaseDecreaseInLeaseLiabilities_3282a19c-ac93-4f6d-ab90-0241dc7635d1" xlink:href="xfor-20231231.xsd#xfor_IncreaseDecreaseInLeaseLiabilities"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_xfor_IncreaseDecreaseInLeaseLiabilities_3282a19c-ac93-4f6d-ab90-0241dc7635d1" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_ChangeInFairValueOfConvertiblePreferredStockWarrantLiability_52b3c21e-ac77-4f60-b390-ec2a546f65a4" xlink:href="xfor-20231231.xsd#xfor_ChangeInFairValueOfConvertiblePreferredStockWarrantLiability"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_xfor_ChangeInFairValueOfConvertiblePreferredStockWarrantLiability_52b3c21e-ac77-4f60-b390-ec2a546f65a4" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_080a9668-888f-4acc-b94f-bad68ddd2a53" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DepreciationDepletionAndAmortization"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_080a9668-888f-4acc-b94f-bad68ddd2a53" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_NonCashLeaseExpense_ec8b68f5-755b-46cf-a803-ff4e85bd1045" xlink:href="xfor-20231231.xsd#xfor_NonCashLeaseExpense"/> |
| | <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_xfor_NonCashLeaseExpense_ec8b68f5-755b-46cf-a803-ff4e85bd1045" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_NonCashInterestExpense_9eed61c8-7a39-4eb1-945d-3580fccdf7aa" xlink:href="xfor-20231231.xsd#xfor_NonCashInterestExpense"/> |
| | <link:calculationArc order="7" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_xfor_NonCashInterestExpense_9eed61c8-7a39-4eb1-945d-3580fccdf7aa" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_237a8414-c5b8-45ca-ac89-3ff70ac7575e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncreaseDecreaseInAccruedLiabilities"/> |
| | <link:calculationArc order="8" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_237a8414-c5b8-45ca-ac89-3ff70ac7575e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShareBasedCompensation_79556b2b-34ed-4679-a7fb-d4e2811e53a0" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ShareBasedCompensation"/> |
| | <link:calculationArc order="9" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_ShareBasedCompensation_79556b2b-34ed-4679-a7fb-d4e2811e53a0" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsPayable_a6a26182-b212-43e2-897a-ad51adac43b4" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncreaseDecreaseInAccountsPayable"/> |
| | <link:calculationArc order="10" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsPayable_a6a26182-b212-43e2-897a-ad51adac43b4" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNoncashIncomeExpense_121d7ea0-aad7-497e-bc1a-fd45d28b050b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OtherNoncashIncomeExpense"/> |
| | <link:calculationArc order="11" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_OtherNoncashIncomeExpense_121d7ea0-aad7-497e-bc1a-fd45d28b050b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_IncreaseDecreaseInOperatingLeaseRightOfUseAssetNonCashPotion_3091991f-5b4d-4887-ae46-64dc43c00bb5" xlink:href="xfor-20231231.xsd#xfor_IncreaseDecreaseInOperatingLeaseRightOfUseAssetNonCashPotion"/> |
| | <link:calculationArc order="12" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_xfor_IncreaseDecreaseInOperatingLeaseRightOfUseAssetNonCashPotion_3091991f-5b4d-4887-ae46-64dc43c00bb5" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GoodwillImpairmentLoss_b5d9d9e1-241b-4edf-a92f-e62e6af2dcf7" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GoodwillImpairmentLoss"/> |
| | <link:calculationArc order="13" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_610497ea-0d21-4e7c-90ec-7ca37b93dd3a" xlink:to="loc_us-gaap_GoodwillImpairmentLoss_b5d9d9e1-241b-4edf-a92f-e62e6af2dcf7" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_681c7649-87a5-4dd6-8dd6-4d94569af823" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireMarketableSecurities_5f8bcea3-b830-4d69-9576-919fa47a18c1" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PaymentsToAcquireMarketableSecurities"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_681c7649-87a5-4dd6-8dd6-4d94569af823" xlink:to="loc_us-gaap_PaymentsToAcquireMarketableSecurities_5f8bcea3-b830-4d69-9576-919fa47a18c1" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleAndMaturityOfMarketableSecurities_9422642d-80a9-4727-aa25-c560adefa265" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ProceedsFromSaleAndMaturityOfMarketableSecurities"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_681c7649-87a5-4dd6-8dd6-4d94569af823" xlink:to="loc_us-gaap_ProceedsFromSaleAndMaturityOfMarketableSecurities_9422642d-80a9-4727-aa25-c560adefa265" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireProductiveAssets_a07c0307-a65c-4891-8166-524c1d4a9a99" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PaymentsToAcquireProductiveAssets"/> |
| | <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_681c7649-87a5-4dd6-8dd6-4d94569af823" xlink:to="loc_us-gaap_PaymentsToAcquireProductiveAssets_a07c0307-a65c-4891-8166-524c1d4a9a99" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/SummaryofSignificantAccountingPoliciesScheduleofCashCashEquivalentsandRestrictedCashDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#SummaryofSignificantAccountingPoliciesScheduleofCashCashEquivalentsandRestrictedCashDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/SummaryofSignificantAccountingPoliciesScheduleofCashCashEquivalentsandRestrictedCashDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1283918a-10f5-41d1-8d14-f43388b411f7" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RestrictedCashNoncurrent_5909b821-6fcf-487a-9652-df769e32d5c0" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_RestrictedCashNoncurrent"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1283918a-10f5-41d1-8d14-f43388b411f7" xlink:to="loc_us-gaap_RestrictedCashNoncurrent_5909b821-6fcf-487a-9652-df769e32d5c0" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_8f187831-528d-49e3-a3e8-e9e80b7ce7e8" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1283918a-10f5-41d1-8d14-f43388b411f7" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_8f187831-528d-49e3-a3e8-e9e80b7ce7e8" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RestrictedCashCurrent_ba0d56e9-43d3-429b-bad2-cc4d32a8d806" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_RestrictedCashCurrent"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_1283918a-10f5-41d1-8d14-f43388b411f7" xlink:to="loc_us-gaap_RestrictedCashCurrent_ba0d56e9-43d3-429b-bad2-cc4d32a8d806" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/FairValueofFinancialAssetsandLiabilitiesGoodwillRollforwardDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#FairValueofFinancialAssetsandLiabilitiesGoodwillRollforwardDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/FairValueofFinancialAssetsandLiabilitiesGoodwillRollforwardDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Goodwill_54632eee-0797-4231-8631-5a64ddec3592" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_Goodwill"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GoodwillGross_9470eb4f-2ff5-440d-8b2f-3522abe2637c" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GoodwillGross"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Goodwill_54632eee-0797-4231-8631-5a64ddec3592" xlink:to="loc_us-gaap_GoodwillGross_9470eb4f-2ff5-440d-8b2f-3522abe2637c" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_5b152533-a037-4c74-8554-928c850a0672" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_GoodwillImpairedAccumulatedImpairmentLoss"/> |
| | <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Goodwill_54632eee-0797-4231-8631-5a64ddec3592" xlink:to="loc_us-gaap_GoodwillImpairedAccumulatedImpairmentLoss_5b152533-a037-4c74-8554-928c850a0672" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/PropertyandEquipmentNetDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#PropertyandEquipmentNetDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/PropertyandEquipmentNetDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_74b17e41-dea1-4fc0-9fad-aab89ee1b6da" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PropertyPlantAndEquipmentNet"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_363b9370-a802-4f9d-89c9-fe3e077639ab" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentNet_74b17e41-dea1-4fc0-9fad-aab89ee1b6da" xlink:to="loc_us-gaap_AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment_363b9370-a802-4f9d-89c9-fe3e077639ab" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentGross_044d589b-0f07-4f30-989c-d2c09c5555b9" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_PropertyPlantAndEquipmentGross"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_PropertyPlantAndEquipmentNet_74b17e41-dea1-4fc0-9fad-aab89ee1b6da" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentGross_044d589b-0f07-4f30-989c-d2c09c5555b9" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/AccruedExpensesDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#AccruedExpensesDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/AccruedExpensesDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccruedLiabilitiesCurrent"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EmployeeRelatedLiabilitiesCurrent_c3266689-2b6d-423a-90f9-7305af0bb81b" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EmployeeRelatedLiabilitiesCurrent"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:to="loc_us-gaap_EmployeeRelatedLiabilitiesCurrent_c3266689-2b6d-423a-90f9-7305af0bb81b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_AccruedExternalResearchAndDevelopmentExpenses_fe80802d-5ecd-45f5-ad31-490c42921df2" xlink:href="xfor-20231231.xsd#xfor_AccruedExternalResearchAndDevelopmentExpenses"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:to="loc_xfor_AccruedExternalResearchAndDevelopmentExpenses_fe80802d-5ecd-45f5-ad31-490c42921df2" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedProfessionalFeesCurrent_bb0de5c4-898b-441c-9b44-6352c9d6b8bd" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_AccruedProfessionalFeesCurrent"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:to="loc_us-gaap_AccruedProfessionalFeesCurrent_bb0de5c4-898b-441c-9b44-6352c9d6b8bd" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_AccruedDeferredFinancingFeesCurrent_727a77bb-2605-4488-b98b-2ff64f9c505c" xlink:href="xfor-20231231.xsd#xfor_AccruedDeferredFinancingFeesCurrent"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:to="loc_xfor_AccruedDeferredFinancingFeesCurrent_727a77bb-2605-4488-b98b-2ff64f9c505c" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAccruedLiabilitiesCurrent_66038a33-5c6d-4b9e-9764-af450142063d" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OtherAccruedLiabilitiesCurrent"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AccruedLiabilitiesCurrent_eb02ca63-21a6-44f7-a761-7d1d26f43327" xlink:to="loc_us-gaap_OtherAccruedLiabilitiesCurrent_66038a33-5c6d-4b9e-9764-af450142063d" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/LongTermDebtScheduleofLongTermDebtDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#LongTermDebtScheduleofLongTermDebtDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/LongTermDebtScheduleofLongTermDebtDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_LongTermDebtIncludingAccretion_9801ab95-3626-4cec-8495-8f2d1fd06af0" xlink:href="xfor-20231231.xsd#xfor_LongTermDebtIncludingAccretion"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebt_ae0a631a-5478-4c8b-8f64-4fc325a1460e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LongTermDebt"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtIncludingAccretion_9801ab95-3626-4cec-8495-8f2d1fd06af0" xlink:to="loc_us-gaap_LongTermDebt_ae0a631a-5478-4c8b-8f64-4fc325a1460e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_AccretionOnLongTermDebt_052f0e67-e85d-4edc-a838-2e9de692c447" xlink:href="xfor-20231231.xsd#xfor_AccretionOnLongTermDebt"/> |
| | <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtIncludingAccretion_9801ab95-3626-4cec-8495-8f2d1fd06af0" xlink:to="loc_xfor_AccretionOnLongTermDebt_052f0e67-e85d-4edc-a838-2e9de692c447" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtInstrumentUnamortizedDiscountPremiumNet_f6cf06c5-ed41-4b15-b704-c6ab98c93c6a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DebtInstrumentUnamortizedDiscountPremiumNet"/> |
| | <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtIncludingAccretion_9801ab95-3626-4cec-8495-8f2d1fd06af0" xlink:to="loc_us-gaap_DebtInstrumentUnamortizedDiscountPremiumNet_f6cf06c5-ed41-4b15-b704-c6ab98c93c6a" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/LongTermDebtFuturePrincipalPaymentsDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#LongTermDebtFuturePrincipalPaymentsDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/LongTermDebtFuturePrincipalPaymentsDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_LongTermDebtAndEOTPayment_6e34035e-1c92-4156-98c5-bf59a639f8ae" xlink:href="xfor-20231231.xsd#xfor_LongTermDebtAndEOTPayment"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_7dadb9fd-3792-48af-9a76-b7b320c2a9cd" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtAndEOTPayment_6e34035e-1c92-4156-98c5-bf59a639f8ae" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_7dadb9fd-3792-48af-9a76-b7b320c2a9cd" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths_2c109224-a32c-4773-98a9-30f2604f7fe8" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtAndEOTPayment_6e34035e-1c92-4156-98c5-bf59a639f8ae" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths_2c109224-a32c-4773-98a9-30f2604f7fe8" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_5a5df631-fbdd-49b2-be92-63305d014a66" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_xfor_LongTermDebtAndEOTPayment_6e34035e-1c92-4156-98c5-bf59a639f8ae" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_5a5df631-fbdd-49b2-be92-63305d014a66" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/LeasesScheduleofComponentsofLeaseExpenseDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#LeasesScheduleofComponentsofLeaseExpenseDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/LeasesScheduleofComponentsofLeaseExpenseDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LeaseCost_4f7e80ba-b375-4cae-8933-97aaea4afa85" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LeaseCost"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseCost_e2e2c7ae-4b4a-492f-96e3-30fae049c72e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingLeaseCost"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LeaseCost_4f7e80ba-b375-4cae-8933-97aaea4afa85" xlink:to="loc_us-gaap_OperatingLeaseCost_e2e2c7ae-4b4a-492f-96e3-30fae049c72e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShortTermLeaseCost_1fdeb68e-6378-4ed9-951d-db7ca1cd002f" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_ShortTermLeaseCost"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LeaseCost_4f7e80ba-b375-4cae-8933-97aaea4afa85" xlink:to="loc_us-gaap_ShortTermLeaseCost_1fdeb68e-6378-4ed9-951d-db7ca1cd002f" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail" xlink:type="simple" xlink:href="xfor-20231231.xsd#LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_570b62ee-d046-48d7-b758-3c6730e58826" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_570b62ee-d046-48d7-b758-3c6730e58826" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_81c90e21-6883-4a35-8705-9ea81d0bb6b0" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_81c90e21-6883-4a35-8705-9ea81d0bb6b0" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_a7e3f8ff-dc56-49d8-9613-9a415d922eb8" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_a7e3f8ff-dc56-49d8-9613-9a415d922eb8" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_4e57747f-e60b-4702-ac49-48782cdeba6a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_4e57747f-e60b-4702-ac49-48782cdeba6a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive_a75f37e9-a39f-4984-a1c5-0c1620bc4e06" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_155920ed-9fc8-4ca5-8c0c-64cc9296685e" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive_a75f37e9-a39f-4984-a1c5-0c1620bc4e06" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail_1" xlink:type="simple" xlink:href="xfor-20231231.xsd#LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail_1"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/LeasesScheduleofMaturitiesofLeaseLiabilitiesDetail_1" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_6956d186-9da4-4704-9841-377ab2ca471a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiability_201bc0e9-3f44-422f-a813-95483aaad6d5" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_OperatingLeaseLiability"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_6956d186-9da4-4704-9841-377ab2ca471a" xlink:to="loc_us-gaap_OperatingLeaseLiability_201bc0e9-3f44-422f-a813-95483aaad6d5" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount_2a5e287d-a04c-42d5-93f1-abf5b59d40ee" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_6956d186-9da4-4704-9841-377ab2ca471a" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount_2a5e287d-a04c-42d5-93f1-abf5b59d40ee" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/IncomeTaxesScheduleofIncomeLossBeforeIncomeTaxesDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#IncomeTaxesScheduleofIncomeLossBeforeIncomeTaxesDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/IncomeTaxesScheduleofIncomeLossBeforeIncomeTaxesDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_c0b2a89c-1630-41f5-941f-a5c73eb2eb68" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesForeign_164244e0-5cac-4186-8cde-07e32b8cb95a" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesForeign"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_c0b2a89c-1630-41f5-941f-a5c73eb2eb68" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesForeign_164244e0-5cac-4186-8cde-07e32b8cb95a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesDomestic_c22f38b7-bc6f-40ee-a9e8-4810893c4b70" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesDomestic"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_c0b2a89c-1630-41f5-941f-a5c73eb2eb68" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesDomestic_c22f38b7-bc6f-40ee-a9e8-4810893c4b70" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/IncomeTaxesReconciliationofEffectiveIncomeTaxRateDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#IncomeTaxesReconciliationofEffectiveIncomeTaxRateDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/IncomeTaxesReconciliationofEffectiveIncomeTaxRateDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateContinuingOperations"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateReconciliationTaxCreditsResearch_ed10562a-5299-40d5-85af-775a2f69f967" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateReconciliationTaxCreditsResearch"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateReconciliationTaxCreditsResearch_ed10562a-5299-40d5-85af-775a2f69f967" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateReconciliationChangeInDeferredTaxAssetsValuationAllowance_39b01007-9646-44ce-a67e-06224fb1defa" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateReconciliationChangeInDeferredTaxAssetsValuationAllowance"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateReconciliationChangeInDeferredTaxAssetsValuationAllowance_39b01007-9646-44ce-a67e-06224fb1defa" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateReconciliationAtFederalStatutoryIncomeTaxRate_74c21d8d-e075-40e4-b8b8-30a138584b7e" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateReconciliationAtFederalStatutoryIncomeTaxRate"/> |
| | <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateReconciliationAtFederalStatutoryIncomeTaxRate_74c21d8d-e075-40e4-b8b8-30a138584b7e" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateReconciliationStateAndLocalIncomeTaxes_22848274-783d-45f1-bedc-4bfdefa4aba5" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateReconciliationStateAndLocalIncomeTaxes"/> |
| | <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateReconciliationStateAndLocalIncomeTaxes_22848274-783d-45f1-bedc-4bfdefa4aba5" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_EffectiveIncomeTaxRateReconciliationOtherPermanentDifferences_c1bb7d06-1d6e-432d-9e75-5ee54277013b" xlink:href="xfor-20231231.xsd#xfor_EffectiveIncomeTaxRateReconciliationOtherPermanentDifferences"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_xfor_EffectiveIncomeTaxRateReconciliationOtherPermanentDifferences_c1bb7d06-1d6e-432d-9e75-5ee54277013b" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectiveIncomeTaxRateReconciliationOtherAdjustments_a472e403-ec99-4419-87d8-27a7651e3dac" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_EffectiveIncomeTaxRateReconciliationOtherAdjustments"/> |
| | <link:calculationArc order="6" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_EffectiveIncomeTaxRateContinuingOperations_ac39f211-6c2f-4717-b0ca-5c335590ab42" xlink:to="loc_us-gaap_EffectiveIncomeTaxRateReconciliationOtherAdjustments_a472e403-ec99-4419-87d8-27a7651e3dac" xlink:type="arc"/> |
| | </link:calculationLink> |
| <link:roleRef roleURI="http://www.x4pharma.com/role/IncomeTaxesDeferredIncomeTaxAssetDetails" xlink:type="simple" xlink:href="xfor-20231231.xsd#IncomeTaxesDeferredIncomeTaxAssetDetails"/> |
| <link:calculationLink xlink:role="http://www.x4pharma.com/role/IncomeTaxesDeferredIncomeTaxAssetDetails" xlink:type="extended"> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilities_3074bc09-ae6c-4376-a035-e41672b997c1" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredIncomeTaxLiabilities"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_DeferredTaxLiabilityRightOfUseAsset_61335a6e-4229-4f0a-ab19-7fd4270fc49a" xlink:href="xfor-20231231.xsd#xfor_DeferredTaxLiabilityRightOfUseAsset"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredIncomeTaxLiabilities_3074bc09-ae6c-4376-a035-e41672b997c1" xlink:to="loc_xfor_DeferredTaxLiabilityRightOfUseAsset_61335a6e-4229-4f0a-ab19-7fd4270fc49a" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsLiabilitiesNet_e6f8468a-f0a2-4467-b152-57f767f6fca7" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsLiabilitiesNet"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilities_b6a611b4-4b38-43c0-9a4f-b4db4e6bba70" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredIncomeTaxLiabilities"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsLiabilitiesNet_e6f8468a-f0a2-4467-b152-57f767f6fca7" xlink:to="loc_us-gaap_DeferredIncomeTaxLiabilities_b6a611b4-4b38-43c0-9a4f-b4db4e6bba70" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsNet_68a47ef5-4fe4-41fb-b598-53d1a2b4ac46" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsNet"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsLiabilitiesNet_e6f8468a-f0a2-4467-b152-57f767f6fca7" xlink:to="loc_us-gaap_DeferredTaxAssetsNet_68a47ef5-4fe4-41fb-b598-53d1a2b4ac46" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsGross"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsOther_da133853-a50f-478b-8c86-3b347f6b5a03" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsOther"/> |
| | <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:to="loc_us-gaap_DeferredTaxAssetsOther_da133853-a50f-478b-8c86-3b347f6b5a03" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwards_d5a7d37c-d37d-40e8-ae94-97436b13f751" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsOperatingLossCarryforwards"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:to="loc_us-gaap_DeferredTaxAssetsOperatingLossCarryforwards_d5a7d37c-d37d-40e8-ae94-97436b13f751" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_DeferredTaxAssetLeaseLiability_6c254259-d988-4fdd-8ae5-44771d7d56ce" xlink:href="xfor-20231231.xsd#xfor_DeferredTaxAssetLeaseLiability"/> |
| | <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:to="loc_xfor_DeferredTaxAssetLeaseLiability_6c254259-d988-4fdd-8ae5-44771d7d56ce" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_xfor_DeferredTaxAssetsTaxDeferredExpenseCapitalizedResearchAndDevelopmentCosts_233836e6-8c6c-41ae-b8ba-66741e6348ed" xlink:href="xfor-20231231.xsd#xfor_DeferredTaxAssetsTaxDeferredExpenseCapitalizedResearchAndDevelopmentCosts"/> |
| | <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:to="loc_xfor_DeferredTaxAssetsTaxDeferredExpenseCapitalizedResearchAndDevelopmentCosts_233836e6-8c6c-41ae-b8ba-66741e6348ed" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsTaxCreditCarryforwardsResearch_d9a29e97-2c5d-497e-9bcc-b7e2f304379d" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsTaxCreditCarryforwardsResearch"/> |
| | <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsGross_1afc2595-b064-4b9f-a43a-58c88d8e1414" xlink:to="loc_us-gaap_DeferredTaxAssetsTaxCreditCarryforwardsResearch_d9a29e97-2c5d-497e-9bcc-b7e2f304379d" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsNet_6d3fe436-8b34-44e9-a05c-9f3e24c72e69" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsNet"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsValuationAllowance_77571f54-91be-4a71-9e4b-9611f9a09985" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsValuationAllowance"/> |
| | <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsNet_6d3fe436-8b34-44e9-a05c-9f3e24c72e69" xlink:to="loc_us-gaap_DeferredTaxAssetsValuationAllowance_77571f54-91be-4a71-9e4b-9611f9a09985" xlink:type="arc"/> |
| | <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredTaxAssetsGross_c992aeca-44e1-4dd6-951b-74d5dac43bd3" xlink:href="https://xbrl.fasb.org/us-gaap/2023/elts/us-gaap-2023.xsd#us-gaap_DeferredTaxAssetsGross"/> |
| | <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DeferredTaxAssetsNet_6d3fe436-8b34-44e9-a05c-9f3e24c72e69" xlink:to="loc_us-gaap_DeferredTaxAssetsGross_c992aeca-44e1-4dd6-951b-74d5dac43bd3" xlink:type="arc"/> |
| | </link:calculationLink> |
| </link:linkbase> |