通过重写软件来避免硬件陷阱