Refactored fastCheckConsistency to match some review comments:
    - renamed fastCheckConsistency to fastMallocSize, and changed ValueCheck
      to ASSERT that a pointer's fastMallocSize is not 0.
    - implemented a version of fastMallocSize for tcmalloc.
            
Reviewed by Alexey Proskuryakov, Darin Adler, and Sam Weinig.

Also moved some pre-existing code around to avoid a problem related to
mismatched #define/#undef of malloc/free in this source file.

* JavaScriptCore.exp:
* wtf/FastMalloc.cpp:
(WTF::fastMallocSize): Renamed. Fixed indentation.

(WTF::TCMalloc_PageHeap::scavenge): Removed an incorrect ASSERT that
got in the way of testing the tcmalloc implementation. (More information
on why this ASSERT is incorrect is in <rdar://problem/7165917>.)

(WTF::TCMallocStats::fastMallocSize): Implemented for tcmalloc.

* wtf/FastMalloc.h: Updated for rename.

* wtf/ValueCheck.h:
(WTF::): Moved the ASSERT that used to be in fastCheckConsistency here.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55811 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/JavaScriptCore/wtf/ValueCheck.h b/JavaScriptCore/wtf/ValueCheck.h
index 63ea2bd..2a86eb0 100644
--- a/JavaScriptCore/wtf/ValueCheck.h
+++ b/JavaScriptCore/wtf/ValueCheck.h
@@ -42,7 +42,7 @@
     {
         if (!p)
             return;
-        fastCheckConsistency(p);
+        ASSERT(fastMallocSize(p));
         ValueCheck<P>::checkConsistency(*p);
     }
 };