At that time, in order to compete for the throne, Li Shimin and his men launched the change of Xuanwu Gate. At that time, Li, the eldest brother, and Li Yuanji, the third brother, were far more powerful, and Li was a prince, so he was even more vulnerable, so he had to choose to strike first and kill his brother to survive.
It can be said that although this move is heartless, it is also excusable. Any normal person may make the same decision when facing the crisis of life and death. In order to make his throne more stable, he forced his father Li Yuan to abdicate and so on. Li Shimin can ignore this accusation.
Li Shimin doesn't need to bear these charges, except for what he did when he was helpless. His period was a very prosperous one, which was called "the rule of chastity" in history. In contrast, the rule of chastity can completely offset Li Shimin's crimes of "tampering with history" and "disloyalty and unfilial".
Because Li Shimin was a wise monarch, he advocated chaste rule and put his people in his heart. So Li Shimin is also loved by people. It is also for this reason that although Li Shimin has done some wrong things, those wrong things can be said to be insignificant by comparison.