I have seen the teachings of the Ari Zal described and cited to both the "Etz Chaim" and the "Shmoneh Shearim." I have seen these for sale as separate books, (e.g., a set of Etz Chaim or volumes called Shaar Ruach HaKodesh, Shaar HaKavanot, etc.). I have also seen for sale something called "Etz Chaim Shmoneh Shearim" and have heard of the "Pri Etz Chaim." I gather that all of these are the teachings of the Ari transmitted by Rav Chaim Vital. But how do they relate to each other?
Wikipedia gives conflicting descriptions of whether they are the same or not. The edition of Etz Chaim I have access to is split into 50 "gates" (i.e., chapters) that do not match up with the names of the Smoneh Shearim. Is one of these works a reorganization of the other? Or a subset of the other? Or are they totally different?