The new paradigm edge computing demonstrates significant advantages in quality of service including low latency and bandwidth efficiency when deployed in autonomous vehicle applications. However, deploying edge computing in the context of a widely used vehicular ad hoc network (VANET) leads to potential security issues. Blockchain is a promising technology to solve security and trust issues with the identically distributed structure as edge computing and VANET, but its efficiency and scalability limitations constrain the usage in VANET. This paper proposes a hierarchical Directed Acyclic Graph (DAG)based blockchain architecture to overcome these integration challenges. The hierarchical architecture divides the whole system into multiple local chains according to geographical regions to improve scalability while also maintaining a global chain to facilitate security. The DAG-based blockchain structure can better support simultaneous operations to further improve scalability and efficiency. In addition, in recognition of VANET's unique requirements, we design a reputation-based consensus for tip selection algorithm (TSA) to replace the widely used Proof-of-Work TSA in DAG, which ensures security in VANET without heavy computational burden. Our experimental simulations reveal that our proposed scheme not only fortifies security but also elevates scalability and efficiency.