MCPcopy Create free account
hub / github.com/async-profiler/async-profiler / expand

Method expand

src/codeCache.cpp:67–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

65}
66
67void CodeCache::expand() {
68 CodeBlob* old_blobs = _blobs;
69 CodeBlob* new_blobs = new CodeBlob[_capacity * 2];
70
71 memcpy(new_blobs, old_blobs, _count * sizeof(CodeBlob));
72
73 _capacity *= 2;
74 _blobs = new_blobs;
75 delete[] old_blobs;
76}
77
78void CodeCache::add(const void* start, int length, const char* name, bool update_bounds) {
79 char* name_copy = NativeFunc::create(name, _lib_index);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected