Why not just join the data directly in Tableau Desktop and apply an extract filter to it there?
Depending on version, if you are on 2018.3 you could create a "multi table extract" instead which loads the tables separately and just joins them in Tableau at query time
Is it possible that the join is duplicating records or creating some kind of Cartesian product? If both datasets are millions of records, then you could potentially be getting millions times millions of resulting records that consume system resources to the point that it never finishes. And, it may not be obvious in design mode, even when viewing the results of the join, because you are likely seeing sampled data that can be completed.
Is it possible to verify that the key field(s) are unique for Data A? You may have to do this outside of Tableau Prep if the data is sampled.
Hope that helps!