| Index: runtime/include/dart_api.h
|
| diff --git a/runtime/include/dart_api.h b/runtime/include/dart_api.h
|
| index 9b4447797d1e31e2ebef9990b93a45095562220c..d2fd16a1f1c47bfe62bff72a57dfbd2d84037df4 100644
|
| --- a/runtime/include/dart_api.h
|
| +++ b/runtime/include/dart_api.h
|
| @@ -575,6 +575,12 @@ Dart_SetGcCallbacks(Dart_GcPrologueCallback prologue_callback,
|
| */
|
| DART_EXPORT const char* Dart_VersionString();
|
|
|
| +typedef struct {
|
| + const char* library_uri;
|
| + const char* class_name;
|
| + const char* function_name;
|
| +} Dart_QualifiedFunctionName;
|
| +
|
| /**
|
| * Isolate specific flags are set when creating a new isolate using the
|
| * Dart_IsolateFlags structure.
|
| @@ -583,7 +589,7 @@ DART_EXPORT const char* Dart_VersionString();
|
| * for each part.
|
| */
|
|
|
| -#define DART_FLAGS_CURRENT_VERSION (0x00000003)
|
| +#define DART_FLAGS_CURRENT_VERSION (0x00000004)
|
|
|
| typedef struct {
|
| int32_t version;
|
| @@ -594,8 +600,15 @@ typedef struct {
|
| bool use_field_guards;
|
| bool use_osr;
|
| bool use_dart_frontend;
|
| + bool obfuscate;
|
| + Dart_QualifiedFunctionName* entry_points;
|
| } Dart_IsolateFlags;
|
|
|
| +/**
|
| + * Initialize Dart_IsolateFlags with correct version and default values.
|
| + */
|
| +DART_EXPORT void Dart_IsolateFlagsInitialize(Dart_IsolateFlags* flags);
|
| +
|
| /**
|
| * An isolate creation and initialization callback function.
|
| *
|
| @@ -3192,12 +3205,6 @@ DART_EXPORT Dart_Handle Dart_LoadCompilationTrace(uint8_t* buffer,
|
| DART_EXPORT Dart_Handle Dart_SaveJITFeedback(uint8_t** buffer,
|
| intptr_t* buffer_length);
|
|
|
| -typedef struct {
|
| - const char* library_uri;
|
| - const char* class_name;
|
| - const char* function_name;
|
| -} Dart_QualifiedFunctionName;
|
| -
|
| /**
|
| * Compiles all functions reachable from the provided entry points and marks
|
| * the isolate to disallow future compilation.
|
| @@ -3323,6 +3330,18 @@ DART_EXPORT Dart_Handle Dart_CreateCoreJITSnapshotAsBlobs(
|
| uint8_t** isolate_snapshot_instructions_buffer,
|
| intptr_t* isolate_snapshot_instructions_size);
|
|
|
| +/**
|
| + * Get obfuscation map for precompiled code.
|
| + *
|
| + * Obfuscation map is encoded as a JSON array of pairs (original name,
|
| + * obfuscated name).
|
| + *
|
| + * \return Returns an error handler if the VM was built in a mode that does not
|
| + * support obfuscation.
|
| + */
|
| +DART_EXPORT Dart_Handle Dart_GetObfuscationMap(uint8_t** buffer,
|
| + intptr_t* buffer_length);
|
| +
|
| /**
|
| * Returns whether the VM only supports running from precompiled snapshots and
|
| * not from any other kind of snapshot or from source (that is, the VM was
|
|
|