 Subsequently, when Emperor Xiaowu, seeking to evade the influence of the paramount general Gao Huan, fled west to Chang'an, then controlled by Yuwen Tai, in 534, the empire became divided into Western Wei (with Emperor Xiaowu as emperor) and Eastern Wei (with Emperor Xiaojing of Eastern Wei, whom Gao declared emperor, as emperor).It is unclear when or how, but Wei eventually joined the Western Wei regime in Chang'an, but it is not clear whether that happened before or after Emperor Xiaowu's death (probably by Yuwen's orders) in 535 and replacement by his cousin Emperor Wen of Western Wei.In 538, during a major campaign between Western Wei and Eastern Wei, Wei Xiaokuan accompanied Emperor Wen, and he was made the governor of Hongnong Commandery (弘農, roughly modern Sanmenxia, Henan).