Updated the code for support of ARC.