Factor common code

* Refactor common code in Backend.elaborate.
* Log4j-compatible interface for ChiselError
* Generate .dot graphs with *Component* clusters