Reviewers: Rodolph Perfetta (ARM), ulan,

Description:
A64: Decoder should not inherit from DecoderVisitor

BUG=none
[email protected],[email protected]
LOG=n

Please review this at https://codereview.chromium.org/177073013/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+7, -10 lines):
  M src/a64/decoder-a64.h


Index: src/a64/decoder-a64.h
diff --git a/src/a64/decoder-a64.h b/src/a64/decoder-a64.h
index 0f53c34e88aa47d1b9be5231aad76c592671b1f3..1a7f6c40903e2e0c9bb6f128a8fec0c2f065f343 100644
--- a/src/a64/decoder-a64.h
+++ b/src/a64/decoder-a64.h
@@ -89,23 +89,17 @@ namespace internal {
 // must provide implementations for all of these functions.
 class DecoderVisitor {
  public:
+  virtual ~DecoderVisitor() {}
+
   #define DECLARE(A) virtual void Visit##A(Instruction* instr) = 0;
   VISITOR_LIST(DECLARE)
   #undef DECLARE
-
-  virtual ~DecoderVisitor() {}
-
- private:
-  // Visitors are registered in a list.
-  std::list<DecoderVisitor*> visitors_;
-
-  friend class Decoder;
 };


-class Decoder: public DecoderVisitor {
+class Decoder {
  public:
-  explicit Decoder() {}
+  Decoder() {}

// Top-level instruction decoder function. Decodes an instruction and calls
   // the visitor functions registered with the Decoder class.
@@ -194,6 +188,9 @@ class Decoder: public DecoderVisitor {
   // tree, and call the corresponding visitors.
   // On entry, instruction bits 27:25 = 0x7.
   void DecodeAdvSIMDDataProcessing(Instruction* instr);
+
+  // Visitors are registered in a list.
+  std::list<DecoderVisitor*> visitors_;
 };




--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to