Rashi there says that the pasuk is telling us that Mount Carmel crossed over the sea when Hashem gave the Jews the Torah at Mount Sinai in order to be at such an incredible event. The Maharsha says that the mountains are inanimate objects and it does not make sense that they came to Mount Sinai to witness the Torah being given but rather the ministering angel of each of the mountains came to the giving of the Torah to the Jewish people. The Maharsha also explains how this fits back into the pesukim in Yirmiyahu. Just as the ministering angels uprooted and exiled themselves to a place of Torah so to the citizens of Egypt will be uprooted and exiled from their homeland; that is why they should prepare provisions for the exile.
There is an absolutely fascinating piece in the Maharsha right before this one which goes into more detail about what it means that our shuls and yeshivas will be uprooted from exile and permanently affixed in Israel in the future. The Maharsha based on a Medrish Yalkut Shimone Yeshayahu 503 says that when we will rebuild the Beis HaMikdash for the third and final time it will be the size of modern Jerusalem, and Jerusalem will be the size of the whole of modern Israel. The reason being for this is because today’s shuls and yeshivas will become part of the structure of the Beis HaMikdash; that is what this gemara means when it says that they will be uprooted and implanted into the land of Israel speedily in our days. The Maharsha points out awe inspiring ramifications to this fact, which is that whoever is standing and praying or learning in any yeshiva or shul outside of Israel is in fact standing in the Beis HaMikdash since the building will one day be a part of the Third Beis HaMikdash. (Click here and here for Hebrew text.)
Looking more closely in the gemara, the kal vachomer or fortiori does not make sense. A kal vachomer is a certain logic used by the Torah which compares something harder to something easier so if the harder one is true then certainly the easier one is true. In this case since the ministering angels of Mount Tabor and Mount Carmel exiled themselves in order to temporarily learn Torah when it was given on Mount Sinai and they were rewarded with their mountain permanently situated in Israel, all the more so the shuls and yeshivas in exile which are constant places of prayer and spreading of Torah shall one day have a permanent residence in Israel. However, the kal vachomer does not make sense because it follows that Mount Tabor and Mount Carmel should be rewarded for traveling to the giving of the Torah which was the greatest event in world history, the highest form of Kiddush Hashem ever. So why should it follow that our prayers and learning in our shuls and yeshivas are greater and easier to assume that it makes us deserving of our houses of worship and learning one day finding permanent residence in Israel? (What is more impressive lihavdil; buying front row tickets to the Super Bowl or buying upper deck season tickets to your home football team?)
It must be that the consistency of our Torah learning and davening in our shuls and yeshiva, no matter how low of a level it is compared to when the Torah was given on Mount Sinai, is still more impressive than matan Torah itself. We have to appreciate the quality of consistency. From the Torah’s perspective the consistent spread of Torah and prayer, no matter what level it is on, is clearly more impressive than going out of the way to participate at the greatest event of Torah learning in world history!
The fact that our shuls and/or yeshivas will one day be a part of the Third Beis HaMikdash, the holiest place on Earth where Hashem’s Divine Presence will rest, all this in reward for our constant use of these facilities in order to spread the word of Torah and to pray to Hashem should give us a much higher appreciation for these already holy places.