Add BCC support for rs_object_slots metadata.

This is added to support proper cleanup of RS resources. We were leaking some
global resources because there was no way to tell which slots to clear.

Change-Id: I3e01ff4f7105444b7610d514f10dd56cb1b359b8
b: 3381615
diff --git a/lib/bcc/ScriptCompiled.h b/lib/bcc/ScriptCompiled.h
index 01af974..0e5c9fc 100644
--- a/lib/bcc/ScriptCompiled.h
+++ b/lib/bcc/ScriptCompiled.h
@@ -43,6 +43,7 @@
     typedef std::list<void*> ExportVarList;
     typedef std::list<void*> ExportFuncList;
     typedef std::map<std::string, FuncInfo *> FuncInfoMap;
+    typedef std::list<uint32_t> ObjectSlotList;
 
   private:
     Script *mpOwner;
@@ -52,6 +53,7 @@
     ExportVarList mExportVars;
     ExportFuncList mExportFuncs;
     PragmaList mPragmas;
+    ObjectSlotList mObjectSlots;
 
     FuncInfoMap mEmittedFunctions;
 
@@ -111,6 +113,9 @@
       return mEmittedFunctions.size();
     }
 
+    size_t getObjectSlotCount() const {
+      return mObjectSlots.size();
+    }
 
     void getExportVarList(size_t varListSize, void **varList);
 
@@ -123,6 +128,9 @@
     void getFuncInfoList(size_t funcInfoListSize,
                          FuncInfo *funcInfoList);
 
+    void getObjectSlotList(size_t objectSlotListSize,
+                           uint32_t *objectSlotList);
+
     char *getContext() {
       return mContext;
     }