Adding support for Ifs in Device Type Analysis (#69050)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/69050
Test Plan: Imported from OSS
Reviewed By: anjali411
Differential Revision: D33555887
Pulled By: Gamrix
fbshipit-source-id: f7f057c5985f8b6e7a9fe5702a944b2b4cc4d5b5