Filter genes in a subset of cells

Hi,
I subset a adata using:
adata_subset = adata[adata.obs[‘leiden’]=‘0’].copy()
Then I wanna filter genes because some genes will become all-zero becuase the reduced cell number.
I found that the results are the same:
adata_subset.X = adata_subset.raw.X
sc.pp.filter_genes(min_cells=1).
And:
use sc.pp.filter_genes(min_cells=1) only, without adata_subset.X = adata_subset.raw.X.
So I wanna know which data (scaled data in adata_subset.X or adata_subset.raw.X) that sc.pp.filter_genes() use.

Besides,
After I set adata_subset.X = adata_subset.raw.X,I ran sc.tl.rank_genes_groups(), will the results be the same when setting use_raw=True and use_raw=False ?