6fe15f6df9
This works around bugs in UndefinedBehaviorSanitizer and Clang. Bug: b/28638298 Change-Id: I6be595f9664516019d28017d24559583a1ae3a21 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/144354 Commit-Queue: Ryan Macnak <rmacnak@google.com> Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
48 lines
1.4 KiB
C++
48 lines
1.4 KiB
C++
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
#ifndef RUNTIME_VM_MEGAMORPHIC_CACHE_TABLE_H_
|
|
#define RUNTIME_VM_MEGAMORPHIC_CACHE_TABLE_H_
|
|
|
|
#include "vm/allocation.h"
|
|
#include "vm/tagged_pointer.h"
|
|
|
|
namespace dart {
|
|
|
|
namespace compiler {
|
|
class ObjectPoolBuilder;
|
|
}
|
|
|
|
class Array;
|
|
class Function;
|
|
class Isolate;
|
|
class ObjectPointerVisitor;
|
|
class String;
|
|
class Thread;
|
|
|
|
class MegamorphicCacheTable : public AllStatic {
|
|
public:
|
|
static FunctionPtr miss_handler(Isolate* isolate);
|
|
NOT_IN_PRECOMPILED(static void InitMissHandler(Isolate* isolate));
|
|
|
|
// Re-initializes the megamorphic miss handler function in the object store.
|
|
//
|
|
// Normally we initialize the megamorphic miss handler during isolate startup.
|
|
// Though if we AOT compile with bare instructions support, we need to
|
|
// re-generate the handler to ensure it uses the common object pool.
|
|
NOT_IN_PRECOMPILED(
|
|
static void ReInitMissHandlerCode(Isolate* isolate,
|
|
compiler::ObjectPoolBuilder* wrapper));
|
|
|
|
static MegamorphicCachePtr Lookup(Thread* thread,
|
|
const String& name,
|
|
const Array& descriptor);
|
|
|
|
static void PrintSizes(Isolate* isolate);
|
|
};
|
|
|
|
} // namespace dart
|
|
|
|
#endif // RUNTIME_VM_MEGAMORPHIC_CACHE_TABLE_H_
|