use less memory
use less memory

Summary:
This is a behavior-preserving change.

1) Don't store hashes for leaves, as those can be trivially recomputed.
2) Don't use virtual methods / vtable. Instead, encode "leaf" bit in highest bit reference-count.

This reduces the typical size of a leaf from 32 to 16 bytes.

Reviewed By: NicholasGorski

Differential Revision: D37126268

fbshipit-source-id: 736dd38dc3c1f2373749e1dbbca743c7ac94a598

facebook/redex,facebook/redex,facebook/redex,facebook/redex,facebook/redex,facebook/redex,facebook/redex,facebook/redex,facebook/redex